Archived

This topic is now archived and is closed to further replies.

aaroncox1234

Begginner DirectX Question

Recommended Posts

hi, im using textures for a little 2D game but im kinda confused about the vertex buffer thing. when i create the buffer, i have to specify the number of vertices, and when displaying a texture with DrawPrimitive, i have to specify how many primitives to draw. my problem is dealing with more than one texture. is there a better way to do it than having to change the vertex buffer and the call to DrawPrimitive every time i want to draw a new texture to the screen?

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
In general, no. However, one trick is to combine separate textures into one bigger texture (and adjust the UVs). This may cause visual problems if you are using filtering or mipmaps.

Share this post


Link to post
Share on other sites