Archived

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

AlienCharm

Surface Loss

Recommended Posts

This book I am reading for my gamming class (Intro to Computer Game Programming w/DirectX 8.0) talks about Surface Loss and has code so it fixes this problem when it does happen. For example when the user hits Alt+Tab to swap to a diff program. Over break I was reading LaMothe''s Guru''s book and I don''t believe I read one thing about surface loss in it. I know for sure his programs do not correct this problem because I tryed hitting Alt+Tab while running them and I cant even get them to come back up after doing this. I was just wondering if anyone has came across this or knows why he left this out of his book. Maybe even why you can''t bring any of his demo''s back up after you hit Alt+Tab? I''d hate to make a demo/game using his engine and then people have to close out of their games if they hit Alt+Tab to do something else.

Share this post


Link to post
Share on other sites
Is there any reason why you can''t use the code from "Intro to Computer Game Programming w/DirectX 8.0"?

----------------------------------
"There are 10 kinds of people in this world, those who know binary, and those who don''t"

Share this post


Link to post
Share on other sites
Chances are high if you don't code to accommodate for a lost surface, your textures and rendering surfaces will be suddenly inaccessible at unexpected times.

I can't think of any reason why someone would explicitly leave it out of their book, other than simply not including it.

The initial learning is just getting something to work. The rest of the time you are coding for reusability, recovering from what can go wrong and keeping things from becoming unstable.

[edited by - Waverider on January 15, 2004 9:54:32 PM]

Share this post


Link to post
Share on other sites
quote:
Original post by 4TheKing
Is there any reason why you can''t use the code from "Intro to Computer Game Programming w/DirectX 8.0"?

----------------------------------
"There are 10 kinds of people in this world, those who know binary, and those who don''t"



it works, i just thought it was odd it wasn''t mentioned in the other book. it seems as if it should have been. thought maybe i was over looking it in the guru book and someone else saw it.

Share this post


Link to post
Share on other sites