   Black screen after 4 seconds?    
  Hello, here I go again...Ok, what I do is that I have an infinite loop that loads a bmp into the back buffer, then blits it to the primary surface. After that the loop goes round and round doing nothing, which should leave the bmps that I loaded the first time on screen, since nothing is happening with the screen?The blit is using the graphic card memory for this. And I am using DirectDraw7 But what happens is that after four seconds the screen goes black, just like that! The program does not crash or anything... since I can press ESC to get pass the screen to the next one...And what is worse is that nothing is happening during that loop, which looks like this:static bool done = FALSE;loop {if(key.. esc...) break;if(!done) //load picturesdone = TRUE;}Does anyone know why the screen goes black suddenly?[edited by - FxMazter on December 31, 2002 10:22:05 AM]
  YES! thank you my LORD!Guess what my problem was ?!Well, I had a construction like this for application:    if(Initialize()){ LoadIntro();while(TRUE){if(PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)){if(msg.message == WM_QUIT)break;TranslateMessage(&msg);DispatchMessage(&msg);}if (KEYSTATE(VK_ESCAPE))SendMessage(main_window_handle,WM_DESTROY,0,0);GameMain();}}else{// handle errors}   Well, the problem was with the LoadIntro() call, I don't know why it is like this but it seems like it was no good idee to have that call before the big main loop... that made my screen go black after 4 seconds...So I just put that call inside the main loop and added a static variable to check if that was already done before... and it solved all my problems! Phu! that was about 2 days going freaking crazy! but hey, happy ending as they say BTW. coudl someone explain to me why I couldn't have a construction like that? with an Intro before entering the main loop?[edited by - FxMazter on December 31, 2002 1:30:25 PM][edited by - FxMazter on December 31, 2002 1:31:48 PM][edited by - FxMazter on December 31, 2002 1:33:25 PM]