I have observed some strange behavior with “VTK debug leaks” in VS 2013.
In a sample project made with VTK 8.1, I’m able to get the debug leaks in console when I close the application. But in Main project, unable to get the debug leaks on application close.
for clear reasons, couldn’t post the details of classes or code snippets used in main project.
Please let me know if there exist any settings in Visual studio or vtk classes which can block debug info.
Memory leak reporting works well in VTK master with recent VS versions, so most likely the problem is that your code uses VTK in an unusual way (or there is a small chance that the different behavior is due to your extremely old compiler version). Can you provide a minimum reproducible example with VS2017 or later?
I’ve just realized that there is a duplicate topic for this - see some more discussions there: VTK debug leaks with Visual studio 2013. My recommendation still holds - create a minimal reproducible example, without that people can just guess what is wrong in your code.
Thank you for the suggestions. According l have moved to Visual studio 2017 with VTK 8.2.0.
Working on “minimum reproducible example”
I have one query regarding “subsystem settings for vtkdebugleaks” in VTK - Visual studio project.
In the subsystem settings → VS2017 : if we select “Console (/SUBSYSTEM:CONSOLE)”, I’m able to see Debug leaks on the console when application is closed.
2.If I choose “Windows (/SUBSYSTEM:WINDOWS)”, I couldn’t see any output in output window of Visual studio. Trying to redirect the output of vtk to a file using “VtkOutputWindow”.
My question is that Using Visual studio in windows, can we see vtkdebugleaks using SUBSYSTEM:WINDOWS in linker-> system settings?