Jump to content
  • Advertisement
Sign in to follow this  
flery

[SOLVED] basic question - load every resource once?

This topic is 4394 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 a very simple question (at least i think so) but i couldnt figure it out with google. As i code a game i need to use the same objects (meshes) for different "instances" in the world. i only need to load every mesh texture once right ? add a reference counter (if i want to delete objects at runtime) and asign a wrapper class that saves the positioning matrix and other specifics ... is that assumption correct ? mfg flery [Edited by - flery on September 7, 2006 9:42:42 PM]

Share this post


Link to post
Share on other sites
Advertisement
Yes, it's called instancing. The "mesh" is just data that describes how to draw something. You can reference that data to draw that something as many times as you like. Just store a pointer to the mesh data with every object you want to draw, and draw it in the correct position and orientation.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • 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!