VisualAnalysisMode
ReferencesRepresents a base class for visual analysis modes.
This class is abstract.
Properties
Gets the visual analysis mode GUID. The Guid is specified with the GuidAttribute applied to the class.
Gets the name of the analysis mode. It is used by the _What command and the object properties details window to describe the object.
Id for Rhino's built-in curvature color analysis mode. Surface curvature is shown using false color mapping.
Id for Rhino's built-in curvature graphs analysis mode. Curvature hair is shown on curves and surfaces.
Id for Rhino's built-in direction analysis mode.
Id for Rhino's built-in draft angle analysis mode. Draft angle is displayed using false colors.
Id for Rhino's built-in edge analysis mode. Brep and mesh edges are shown in a selected color.
Id for Rhino's built-in edge continuity analysis mode.
Id for Rhino's built-in emap analysis mode. An environment map is shown on surfaces and meshes.
Id for Rhino's built-in End analysis mode.
Id for Rhino's built-in thickness analysis mode.
Id for Rhino's built-in zebra stripe analysis mode. Zebra stripes are shown on surfaces and meshes.
Gets true if this visual analysis mode will show isocuves on shaded surface objects. Often a mode's user interface will provide a way to change this setting.
The default is false.
Gets the visual analysis mode style.
Methods
Interactively adjusts surface analysis meshes of objects using a Rhino built-in analysis mode.
Returns: true if successful, false otherwise.
Adjusts the auto range values for curvature analysis.
public static void CurvatureColorAutoRange()
Adjusts the max range values for curvature analysis.
public static void CurvatureColorMaxRange()
DrawBrepObject
#Draws one brep. Override this method to add your custom behavior.
The default implementation does nothing.
protected virtual void DrawBrepObject()
DrawCurveObject
#If Style==Wireframe, then the default decomposes the curve object into nurbs curve segments and calls the virtual DrawNurbsCurve for each segment.
protected virtual void DrawCurveObject()
DrawExtrusionObject
#Draws one extrusion. Override this method to add your custom behavior.
The default implementation does nothing.
protected virtual void DrawExtrusionObject()
Remarks: Extrusions are not breps, so DrawBrepObject(BrepObject, DisplayPipeline) is not called for them. A mode that should treat the two alike needs to override both.
DrawMesh
#Draws a mesh.
The default implementation does nothing.
protected virtual void DrawMesh()
obj,
A Rhino object corresponding to the surface.
Mesh
mesh,
The mesh geometry.
pipeline
The current display pipeline.
DrawMeshObject
#Draws one mesh. Override this method to add your custom behavior.
The default implementation does nothing.
protected virtual void DrawMeshObject()
DrawNurbsCurve
#Draws a NURBS curve. This is a good function to override for analysis modes like curvature hair display.
The default implementation does nothing.
protected virtual void DrawNurbsCurve()
obj,
A Rhino object corresponding to the curve.
curve,
The curve geometry.
pipeline
The current display pipeline.
DrawNurbsSurface
#Draws a NURBS surface. This is a good function to override to display object-related meshes.
The default implementation does nothing.
protected virtual void DrawNurbsSurface()
obj,
A Rhino object corresponding to the surface.
surface,
The surface geometry.
pipeline
The current display pipeline.
DrawPointCloudObject
#Draws one point cloud. Override this method to add your custom behavior.
The default implementation does nothing.
protected virtual void DrawPointCloudObject()
pointCloud,
A point cloud object.
pipeline
The current display pipeline.
DrawPointObject
#Draws one point. Override this method to add your custom behavior.
The default implementation does nothing.
protected virtual void DrawPointObject()
DrawSubDObject
#Draws one SubD. Override this method to add your custom behavior.
The default implementation does nothing.
protected virtual void DrawSubDObject()
Remarks: The default ObjectSupportsAnalysisMode(RhinoObject) does not accept SubD objects, so a mode that wants them must override that as well and return true for them.
Turns the analysis mode's user interface on and off. For Rhino's built in modes this opens or closes the modeless dialog that controls the analysis mode's display settings.
public virtual void EnableUserInterface()
Finds a visual analysis mode by guid.
Returns: The found visual analysis mode, or null if it was not found, or on error.
Finds a visual analysis mode by type.
Returns: A visual analysis mode on success, or null on error.
Gets a value indicating if this visual analysis mode can be used on a given Rhino object.
Returns: true if this mode can indeed be used on the object; otherwise false.
Registers a custom visual analysis mode for use in Rhino. It is OK to call register multiple times for a single custom analysis mode type, since subsequent register calls will notice that the type has already been registered.
Returns: An instance of registered analysis mode on success.
SetUpDisplayAttributes
#If an analysis mode needs to modify display attributes, this is the place to do it. In particular, Style==Texture, then this function must be overridden.
protected virtual void SetUpDisplayAttributes()
obj,
The object for which to set up attributes.
attributes
The linked attributes.
Remarks: Shaded analysis modes that use texture mapping, like zebra and emap, override this function set the texture, diffuse_color, and EnableLighting parameter.
UpdateVertexColors
#If Style==falseColor, then this virtual function must be overridden. Rhino calls this function when it is time for to set the false colors on the analysis mesh vertices. For breps, there is one mesh per face. For mesh objects there is a single mesh.
protected virtual void UpdateVertexColors()
obj,
The object for which to update vertex colors.
Mesh[]
meshes
An array of meshes that should be updated.