0
\$\begingroup\$

here is the code:

batcher.draw(birdMid, bird.getX(), bird.getY(), bird.getWidth() / 2.0f,
             bird.getHeight() / 2.0f, bird.getWidth(), bird.getHeight(),
             1, 1, bird.getRotation());

what each parameter in this method presents? Please explain in detail

\$\endgroup\$
  • 1
    \$\begingroup\$ Most libraries and software have documentation and support resources. You may want to look at those for guidance as the question as it currently stands does not really fit into the Q&A format of this site. \$\endgroup\$ – Lars Viklund Jul 20 '15 at 8:03
  • \$\begingroup\$ @LarsViklund But LibGDX is knows for having poor documentation, it gets a lot better though ;). \$\endgroup\$ – Madmenyo Jul 20 '15 at 20:25
  • \$\begingroup\$ I'm voting to close this question as off-topic because it is asking for the documentation of an API method. \$\endgroup\$ – user1430 Jul 20 '15 at 21:23
1
\$\begingroup\$

On my version (1.6.3) there is only one SpriteBatch method that takes 10 parameters.

/** Draws a rectangle with the bottom left corner at x,y and stretching the region to cover the given width and height. The
 * rectangle is offset by originX, originY relative to the origin. Scale specifies the scaling factor by which the rectangle
 * should be scaled around originX, originY. Rotation specifies the angle of counter clockwise rotation of the rectangle around
 * originX, originY. */
public void draw (TextureRegion region, float x, float y, float originX, float originY, float width, float height,
    float scaleX, float scaleY, float rotation);

Your IDE most probably supports some button like Go To Declaration. Next time you should use that. My guess is that you are supplying a texture instead of a TextureRegion but there is not enough code to proof this.

\$\endgroup\$

Not the answer you're looking for? Browse other questions tagged or ask your own question.