This brief guide discusses the types of meshes found in Rhino.
There is an
ON_Brep::GetMeshes() routine of the C/C++ SDK. You might find that very adequate meshes can be pulled from this routine when specifying
ON::render_mesh. You may have also noticed that you can also run this routine with an enumeration for an “analysis mesh,” a “default mesh,” a “preview mesh,” or “any mesh.”
What are the differences between all of these options?
Here is an overview of the mesh types:
ON::render_meshis a mesh for, obviously, rendering. This rendering can be for shaded or rendered display. It can also be used by rendering plugins. The quality of these meshes is controlled by the Meshes page in the Document Properties dialog, but can also be overridden on a per-object basis.
ON::analysis_meshis used by analysis modes, such as curvature, draft angle, environment map, and zebra.
ON::preview_meshis used when you use the Mesh command and poke the preview button - the pipeline needs a way to display preview meshes and this is it.
ON::render_meshif it exists. Otherwise it returns
ON::analysis_meshif it exists.
ON::any_meshis only used when we want delete all meshes at one time.
NOTE: render and analysis meshes do not appear automatically. Some command must trigger their creation, whether its just setting viewport for rendered display or running an analysis command. The can also be generated from plugins that call SDK functions.