Jump to content
  • Advertisement


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

The Lion King

Vertex Buffer & Texture

This topic is 5283 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I have to place different objects of same size (quad) on the screen with different textures. The quantity of textures will be more than 100 (I presume) ... what I want to ask is should I use one Vertex Buffer to display all objects (textures) by loading textures in seperate class or seperate vertex buffer & textures for each object? Hope I asked my question right? Thanks!

Share this post

Link to post
Share on other sites
If all of the quads vertex structure type is the same, there is no reason that you cannot keep them in the same vertex buffer, just be sure to specify proper values/ranges for all your DP calls (likewise you can store all your indices in one index buffer). You will need a separate DP call for each texture grouping.
A handy trick is to dump many textures into one larger texture, called a texture atlas or something. This will enable you to group large groups of quads together since they will share the same large texture. Note that a quad tiling/wrapping etc will not work with a texture atlas.

[edit]: typos.

[edited by - SoulSpectre on June 1, 2004 12:06:16 AM]

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!