Large meshes in VTK

I have a tool that generates screenshots of a combination of STLs. Currently I am trying to create screenshots of a scene that includes a very large STL (650.000 vertices, 1.700.000 faces). However, if I run the tool a couple of times in a row, the large mesh is sometimes shown in the screenshots and sometimes it is not. This seems very random. Using a slightly smaller mesh (350.000 vertices, 700.000 faces), this problem does not occur.

So my question is: is VTK known to have problems with visualizing such large meshes? Is there a setting in a basic rendering pipeline (renderwindow & renderer) that might make the pipeline able to handle larger meshes?

Answers


I have found that calculating the normals on such a huge mesh, in order to use Phong shading, was causing the problem.

Disabling the normal calculation for large meshes (e.g. more than 500000 faces) and using flat shading just for these meshes, seems to have solved the problem. The large meshes now consistently show up in every screenshot.


Need Your Help

refreshing a page in jquery mobile after a pageshow

javascript jquery jquery-mobile

Am trying to refresh a page on pageshow in jquery mobile

Negative Regexp - Exclude all php scripts but not some of them

regex apache

As the title says, I would like to exclude from apache execution all php files but not some of them that I know to be "legal".