Skip to main content
gamedev.net
🔒 Locked

Odd Memory Leak

Started by Maddius 3 replies 800+ views
Original Post
Maddius
Maddius
Hi all, I have discovered a strange memory leak problem in my program. There are two cubes in a scene ontop of each other, now if you minimise the window while these cubes are in view the program suddenly eats up memory and basically screws everything up. However if you minimise the window while looking away from the boxes the program doesnt occour, I have no idea, was wondering if anyone knew about this? Thanks.
Maddius
Maddius
I fixed this but haven't solved it. I just stop updating and drawing the program when the window looses focus. I can only presume some sort of pointer becomes invalid when the program gets windowed causing a leak. Still would like to know what it is though.
dys129
dys129
What DX you are using ? Have you read DX debug output ? With so little informations provided it's really hard to help you :)
Maddius
Maddius
Well I can tell you its DX10, but the leak makes the program jump from 10MB to 150 MB in about 2 seconds and it keeps growing after that and there is no real output from debugger. Like I said I have managed to stop it by pausing when the window looses focus. But yeah, sorry man.
marius1930
marius1930
What's important is not fixing it, it's finding out why.

Otherwise, the chances are you only remove the symptoms and not the disease. (bug)
As well as knowing how to prevent it in the future.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.