Handling Opengl error Out of memory

any plan to add Vulkan into VTK?:slight_smile:

When I recreated all objects for each rendering then after about 7500 renderings my display went dark for a second and the application crashed. It looked like a graphics driver crash. It would be hard to tell if this is the fault of VTK or the driver, maybe both. If you want to know the answer then you can rerun the test application thousands of times with different inputs, varying what is performed in each iteration and what is only done once, run everything in debug mode, try it on many different computers, etc.

I tried not recreating the render window, renderer, and volume actor for each iteration and I had no problem at all even after hundreds of thousands of renderings. Rendering time was also about 10x faster.

1 Like

thanks! what error do you get? OpenGL 1285 Out of memory?
OpenGL Error - OpenGL Wiki (khronos.org)
after add this callback, i got:
GL CALLBACK: ** GL ERROR ** type = 0x824c, severity = 0x9146, message = GL_OUT_OF_MEMORY error generated. Failed to allocate memory for texture.

is there allocated Res not free, then after many loops, OpenGL reach some Limit, eg. sth like maxMemoryAllocationCount in Vulkan which limit the allocations simultaneously exist. Or some Bindless Textures?

what platform did you test on? Windows?Linux? nvdia GPU?

why do you suspect ‘inputs’? i remember even recreate the MetaReader each Loop BUT with the same dataFileName the result is also crash…