Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I recently read that any transformation changes will cause a new batch to be triggered.

So, if I have 10 Sprites and each has a different rotation or scale will there be 10 batches sent up?

Or is this somehow limited to SpriteBatch.Begin, where a Matrix is used?

I'm not clear on how the Begin/End relate to scale/rotation in draw calls or if they do at all in terms of how many batches are created.

I appreciate any info on this topic...

share|improve this question
    
I think the confusion here originates because you can transform the entire spritebatch. If you want to multiple transformation at the sprite batch level then you need to create a new batch. Transforming the individual instances does not result in a new batch. –  ClassicThunder Mar 5 '13 at 18:14
add comment

1 Answer 1

No, individual batches will only be triggered in case you are using SpriteSortMode.Immediate or change texture. Individual sprite info is stored in an internal array and some operations are performed in CPU (rotation, scaling) before sending the vertex buffer to the GPU. For more information about the internals of SpriteBatch, check this answer.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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