Jump to content
  • Advertisement

Archived

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

baddrizz

having problems with back buffer....

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

i''m having a problem with my back buffer not cleaning it self out as in it keeps the old stuff in memory after i close down the prog example: i load a bmp at 800 600 fullscreen flip the surface close it down then change the bmp to different pic and load it back up at 640 480 with a screen res of 800, 600 and you can still see the old bmp around the edges can someone tell me what is causing this or any idea''s whats happening?? i can send you my source if you want it too big to put on here

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
I don''t really know what''s happening but you should make sure that you''re releasing your COM objects properly when you shut down your program. You should release the surfaces in the order they were created, and finally, release the main DirectDraw object.

lpddsbackbuffer->Release();
lpddsfrontbuffer->Release();
lpdd->Release();

This way, the resources return to Windows and will get cleaned out.

Share this post


Link to post
Share on other sites
Hmmm. I think you may need to elaborate a bit. Seams odd but
your post leaves some "?". Are you compleatly shuting down the
prog and the changing the code to load your smaller image? Or
are you doing it in the program? Are you blitting a 640x480 image
into 800x600 area or are you streaching the image to fit 800x600.
If you are doing it all in the program and only biliting to a
smaller area than earlier in the prog then you will need to clean
out the buffer because it won''t do it by itself. If you are gettin
images from an earlier program instance then you may have a strange
thing happening with your vid card driver that you may need to take
into acount. Update it or make real sure everything is cleared
before you start going.

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!