Jump to content
  • Advertisement
Sign in to follow this  
azjerei

Is this wise?

This topic is 4984 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

Would this be a wise layout for a 3D game using OpenGL? The game world is constructed from several objects. When the game starts, the bounding box extents for each of those objects is read from a file. Each frame, there is a distance check between the player position and each object's bounding box. Those objects within distance are then dynamically loaded and rendered, the rest remain unloaded and unrendered. I have no clue as to how effective or uneffective this would be. All I know is that it is a complex procedure. Would I be better off just keeping the entire level in memory instead of dynamically loading the parts I want to draw?

Share this post


Link to post
Share on other sites
Advertisement
If the level fits in memory, keep it in memory.

Sounds like manually paging bits in/out is premature optimisation. So unless you are likely to have 1 zillion objects, don't.

Even if your level is too large for memory, you can probably break it up into distinct zones of which only a few need to be loaded at a time (say the one the player's in and all adjacent ones).

If the level is small(ish) and doesn't fit in memory, your designers have made it much too detailed :) . If your level is huge and doesn't fit in memory, you can break it up.

Mark

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!