Re: Detecting memory leaks
Posted by
gouessej on
Mar 05, 2014; 8:58am
URL: https://forum.jogamp.org/Detecting-memory-leaks-tp4031771p4031773.html
Hi
Have you set jogl.debug.GLBufferObjectTracker to true?
https://github.com/sgothel/jogl/blob/master/src/jogl/classes/jogamp/opengl/GLBufferObjectTracker.javaI have already solved a similar problem in my game, I can give you some very detailed advises to do the same in your application. My aim was to avoid problems of high memory footprint and memory leaks, especially when my game runs for a long time. I had to take care of 2 "aspects", the OpenGL resources and the resources on the native heap, both had to be manually monitored, you can't just expect Java from doing it smartly. GPU-Z only shows you one part of the problem. In my humble opinion, you should use an high level mechanism allowing you to "mark" a VBO as good candidate for the trash bin, your responsibility would consist in using this mechanism when you can know that you no loner need a model. In JFPSM, I know that I no longer need a model when the end user closes a tab and there is no remaining viewer showing it.