Jump to content
  • Advertisement

Archived

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

Stefaniii

2D Engine, non tiled scrolling.

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

Here is my plan for the 2D game Im building: Levels are stored in multiple ''layers''. The first layer is just a pictured background for static things that never move (sky, ground etc). The second layer is a bitmask that paints passable and impassable terrain. The third layer is logical game objects (enemies, player spawn, powerups, damage areas etc etc). Now levels are obviously very large, so I can''t load 20 screens of background into the video card memory all at once. My idea is to split up the level into a series of 1024x768 blocks and to only store 3 blocks in video memory at any one time. Ie I would store the block the player is currently in, the next block and the previous block. When a player leaves one block and enters another, the engine will have to load an entire new block into video memory. Will this cause a significant delay? Ie how long would it take to copy 1024x768 32bit pixels from system memory into a texture in video memory? Can anyone see any other flaws with my engine design? I should also add that it would be implemented using textured quads. Actually I have total newbie question as well. Will windows manage graphics memory for me anyway? Can I just go ahead and load up all the textures I want and have directx and windows automatically shuffle things between system and video memory?

Share this post


Link to post
Share on other sites
Advertisement

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