[SDL] + OpenGL gives me memory grow of 4kB per 2 seconds

Started by
1 comment, last by Decrius 16 years ago
Hi, I've been using SDL + OpenGL lately, and found out that my application's memory kept growing. I out-commented code to see where it leaks memory, and when I use the following code, the application's memory is growing 4kB per 2 seconds spproximatly:
bool running = true;
while (running)
{
    glClear(GL_COLOR_BUFFER_BIT);
    SDL_GL_SwapBuffers();
}
I also do some event processing, but I figured that worked fine...apparently one of the 2 functions is leaking... Anyone with the same problem? What could it be? Thanks in advance, Decrius
[size="2"]SignatureShuffle: [size="2"]Random signature images on fora
Advertisement
How did you check the memory ? Did you use Task Manager for that ?
In that case you don't have to worry it is normal behaviour for any windows application.

If you want to check if memory leaks are really occuring then you need to use
crtdbg.h

Quote:Original post by DMINATOR
How did you check the memory ? Did you use Task Manager for that ?
In that case you don't have to worry it is normal behaviour for any windows application.

If you want to check if memory leaks are really occuring then you need to use
crtdbg.h


Ah thanks, yes I was using the Task Manager.

Can I get crtdbg.h to work with MingW and Code::Blocks?

[size="2"]SignatureShuffle: [size="2"]Random signature images on fora

This topic is closed to new replies.

Advertisement