Android App Development for Beginners – 76 – LibGDX Camera

[ad_1]
Facebook –
GitHub –
Google+ –
LinkedIn –
reddit –
Support –
thenewboston –
Twitter –


Posted

in

by

Tags:

Comments

21 responses to “Android App Development for Beginners – 76 – LibGDX Camera”

  1. pinball ball Avatar

    Can we create rpg game ?

  2. pinball ball Avatar

    Can we make pokemon go app aur subway surfers with java programming language and andrioid studio ? What type of apps can we create from andrioid studio and java

  3. Mohit Pundir Avatar

    to clamp the camera try this:

    public void create () {
    batch = new SpriteBatch();
    texture = new Texture(Gdx.files.internal("clash.png"));
    sprite = new Sprite(texture);
    float w = sprite.getWidth();
    float h = sprite.getHeight();
    camera = new OrthographicCamera(Gdx.graphics.getWidth(),Gdx.graphics.getHeight());
    camera.position.set(w/2,h/2,0);
    camera.update();
    }

    public boolean pan(float x, float y, float deltaX, float deltaY) {
    camera.translate(-deltaX,deltaY);
    camera.position.x = MathUtils.clamp(camera.position.x, camera.viewportWidth/2, sprite.getWidth() –
    (camera.viewportWidth/2));
    camera.position.y = MathUtils.clamp(camera.position.y, camera.viewportHeight/2, sprite.getHeight() –
    (camera.viewportHeight/2));
    camera.update();
    return true;
    }

  4. Lakpa Sherpa Avatar

    1.25 >> Speed is best for learning with these videos 😀
    Anyway! loved the video 🙂

  5. weavehole Avatar

    It is now:

    implements GestureDetector.GestureListener

  6. Eternally Boundless Avatar

    That image is Boss! Can I have a copy of it with it's original size?

  7. ginourie7 Avatar

    This video doesnt seem to finish 🙁

  8. GoogleChrome Avatar

    no dislikes lol

  9. Kate - Avatar

    Thank You bucky!! Because of these tutorials i made a great android app. Everybody check it out: https://play.google.com/store/apps/details?id=com.svein.mooky

  10. Andrew Elmer Avatar

    Do you think you will ever a libgdx series on its own? Would be awesome if you would!

  11. DanielsLPecke Avatar

    My Picture is just BLACK ?!

  12. Tommy Wu Avatar

    Why any of my gesture listener is not triggered whatsoever??? Please help.

  13. SANDEEP CHIKHALE Avatar

    Hello Bucky ,
    Please make a video with full on Android Game Development with Android Studio

  14. Ayieh Picardal Avatar

    men ! you are amazing ! thank you so much !

  15. Zang - o estrategista Avatar

    Could you please explain the difference between the use of Game class and ApplicationAdapter? I'm following your videos but most of examples I see on web is based on Game and Screen classes. What is the limitations of those choices? Thanks, nice job btw

  16. carlo salvahan Avatar

    really helpful 🙂 . ive been developing and i experienced a problem with stage actors. when i resize the screen the skin of the actor resizes but it cant be click in the position of the actor skin it retains the old coordinates and the coordinates is not within the actor skin. if someone knows how to do it please help :3

Leave a Reply

Your email address will not be published. Required fields are marked *