SDL Problem

I cannot seem to get SDL_Flip() to work properly. Here is some skeleton code to try and explain the problem.
1
2
3
4
5
BlitSurface(newSurface); //First I blit the surface
SDL_Flip(display); // Then I flip the display
SDL_Delay(2000); // Now I want to pause but the screen has not updated
... //More Code
... //Later SDL_Flip() works 

I want to get the surface to show up and then pause the program for 2 seconds. The problem is very puzzling to me because
-> Later on the surface shows up so I think that it has blitted correctly
-> SDL_Flip() returns zero so there is no error

Any ideas what could be wrong?
Topic archived. No new replies allowed.