Sign in to follow this  

Translating batched vertices?

Recommended Posts

Alright, my display engine is slow as crap and I have a feeling that batching my vertices is part of the solution. This brings up an interesting question though: is there any way to translate these vertices without locking the vertex buffer, or is the idea of batched vertices that they're supposed to never move from their initial position? If that's the case, then how do you handle the vertices of moving objects in a game, do they simply not get batched so that they can have their own translation matrices? I am making a 2D game using Direct3D, so none of the objects have more than 4 vertices(the amount necessary for one simple, textured quad). I could batch together all of the objects that are going to be static in the game and that share the same texture, but what about if I want to have a lot of moving sprites in the game? Right now all of them just have their own vertex buffer and translation matrix, but is there a way to optimize this?

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this