Click or drag to resize
SoWinViewerSetDrawStyle Method

Sets the current drawing style in the main view.

Namespace: OIV.Inventor.Win.Viewers
Assembly: OIV.Inventor.Win (in OIV.Inventor.Win.dll) Version: 2024.1.1.0 (2024.1.1)
Syntax
public void SetDrawStyle(
	SoWinViewerDrawTypes type,
	SoWinViewerDrawStyles style
)

Parameters

type
Type: OIV.Inventor.Win.ViewersSoWinViewerDrawTypes
style
Type: OIV.Inventor.Win.ViewersSoWinViewerDrawStyles
Remarks

The user can specify the INTERACTIVE draw style (draw style used when the scene changes) independently from the STILL style. Default is VIEW_AS_IS draw style for STILL and VIEW_SAME_AS_STILL for INTERACTIVE.

The default value can be set using the environment variables OIV_STILL_DRAW_STYLE and OIV_INTERACTIVE_DRAW_STYLE. Valid values are VIEW_AS_IS, VIEW_HIDDEN_LINE, VIEW_NO_TEXTURE, VIEW_LOW_COMPLEXITY, VIEW_LINE, VIEW_POINT, VIEW_BBOX, VIEW_LOW_RES_LINE, VIEW_LOW_RES_POINT for OIV_STILL_DRAW_STYLE and the same plus VIEW_SAME_AS_STILL for OIV_INTERACTIVE_DRAW_STYLE.

Possible draw styles are: VIEW_AS_IS - Leaves the objects unchanged.

VIEW_HIDDEN_LINE - Renders the object as wireframe, but only shows the object front faces. This is accomplished using a two-pass rendering. In the first pass, the objects are rendered as FILLED using the background BASE_COLOR (this sets up the wanted z-buffer values). The second pass then renders the objects as LINES, while adjusting the z-buffer range to limit overlapping polygons problems.

VIEW_NO_TEXTURE - Renders the objects without any textures. This is done by setting the override flag on an empty OIV.Inventor.Nodes.SoTexture2 node.

VIEW_LOW_COMPLEXITY - Renders the objects without any textures and with a low complexity. This is done by setting the override flag on an empty OIV.Inventor.Nodes.SoTexture2 node, and by setting a low complexity value on an OIV.Inventor.Nodes.SoComplexity node with override set to true.

VIEW_LINE - Renders the objects as LINES (no texture) with lighting model set to BASE_COLOR.

VIEW_LOW_RES_LINE - Renders the objects as LINES (no texture) using a low complexity, with lighting model set to BASE_COLOR and no depth comparison.

VIEW_POINT - Renders the objects as POINTS (no texture) with lighting model set to BASE_COLOR.

VIEW_LOW_RES_POINT - Renders the objects as POINTS (no texture) using a low complexity, with lighting model set to BASE_COLOR and no depth comparison.

VIEW_BBOX - Renders the objects with complexity BOUNDING_BOX, lighting model set to BASE_COLOR and drawing style LINES (no texture) with no depth comparison.

VIEW_SAME_AS_STILL - This only applies to INTERACTIVE draw type. It enables the interactive draw style mode to match the regular draw style mode without having to set it explicitly.

See Also