I am currently making my first 3D OpenGL game (with SDL). You're supposed to find missing children in a forest, and you can place stones behind you, so you know where you've been.
Some times when I 'save' a kid, or when I place a stone, only a part of the screen gets updated/rendered (the part is a square ~1/4 of the screen).
Edit: For some reason, without doing anything to the code, the whole screen is freezing.
The only thing I can do to fix it is to make the program draw something new, or remove something from the 'drawing-list' (like saving a new kid or placing a new stone) when the bug is occurring.
The game itself is running, it's only the rendering part that freezes up.
I have tried to capture the bug on video with Fraps and Bandicam, but when the bug happens, the recording doesn't get that. It shows that it is running like normal.
I would like to add some source code, but I have no idea what portion of the code is bugged.
Maybe some of you have seen/heard of it before, and know what could be the cause?
This is how I set up the window:
Code :SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1); buffer = SDL_SetVideoMode(width, height, myBpp, SDL_OPENGL | SDL_RESIZABLE); // buffer = SDL_Surface




