public class SoLineHighlightRenderAction extends SoGLRenderAction
SoLineHighlightRenderAction
is a render action which renders the specified scene graph, then renders each selected object again in wireframe. Selected objects are specified by the first SoSelection
node in the scene to which this action is applied. If there is no renderable geometry in a selected object, no highlight is rendered for that object. A highlight render action can be passed to the setGLRenderAction() method of SoWinRenderArea to have an effect on scene graphs.
Here is an example of how a line highlight can be specified for a particular selection node and render area.
SoWinRenderArea *myRenderArea;
SoSelection
*mySelection;
// Set the highlight render action
myRenderArea->setGLRenderAction(
new SoLineHighlightRenderAction()
);
// Automatic redraw on selection changes
myRenderArea->redrawOnSelectionChange(mySelection);
See also:
SoBoxHighlightRenderAction
, SoGLRenderAction
, SoSelection
, SoWinRenderArea, SoDrawStyle
, SoInteraction
SoGLRenderAction.AbortCodes, SoGLRenderAction.AutoCacheModes, SoGLRenderAction.FastEditSavePolicies, SoGLRenderAction.InvalidateCacheModes, SoGLRenderAction.TransparencyTypes
SoAction.AppliedCodes, SoAction.DistribModes, SoAction.PathCodes, SoAction.PathIndices
Inventor.ConstructorCommand
ABORT, ADD, ALWAYS, BLEND, CONTINUE, DELAY, DELAYED_ADD, DELAYED_BLEND, DELAYED_SORTED_LAYERS_BLEND, DELAYED_SORTED_PIXELS_BLEND, DISABLE, DO_AUTO_CACHE, DONT_AUTO_CACHE, EACH_FRAME, NO_TRANSPARENCY, OFF, ONCE, PRUNE, SCREEN_DOOR, SORTED_LAYERS_BLEND, SORTED_OBJECT_ADD, SORTED_OBJECT_BLEND, SORTED_OBJECT_TRIANGLES_ADD, SORTED_OBJECT_TRIANGLES_BLEND, SORTED_PIXELS_BLEND, SORTED_TRIANGLES_ADD, SORTED_TRIANGLES_BLEND, WHEN_NEEDED
ALL, BELOW_PATH, CLUSTER_ONLY, IN_PATH, LOCAL_ONLY, NO_PATH, NODE, OFF_PATH, PATH, PATH_LIST
VERBOSE_LEVEL, ZeroHandle
Constructor and Description |
---|
SoLineHighlightRenderAction()
Constructor.
|
SoLineHighlightRenderAction(SbViewportRegion viewportRegion)
Constructor which takes the normal
SoGLRenderAction parameters. |
Modifier and Type | Method and Description |
---|---|
static void |
enableElement(java.lang.Class<? extends Inventor> t,
int stkIndex) |
SbColor |
getColor()
Gets the color of the highlight.
|
short |
getLinePattern()
Gets the line pattern of the highlight.
|
float |
getLineWidth()
Gets the line width of the highlight.
|
float |
getPointSize()
Gets the point size of the highlight.
|
boolean |
isVisible()
Returns whether highlights will be rendered or not.
|
void |
setColor(SbColor c)
Sets the color of the highlight.
|
void |
setLinePattern(short pattern)
Sets the line pattern of the highlight.
|
void |
setLineWidth(float width)
Sets the line width of the highlight.
|
void |
setPointSize(float size)
Sets the size of points (diameter in pixels) rendered by the highlight.
|
void |
setVisible(boolean b)
This provides a convenient mechanism for turning highlights off or back on.
|
abortNow, enableDepthPeeling3D, generateCacheContext, getCacheContext, getCurPass, getDecimationPercentage, getDecimationType, getDelayedObjDepthWrite, getDepthPeelingPass, getFastEditSavePolicy, getFrameCounter, getInvalidateCacheMode, getLogicalViewportRegion, getNumPasses, getRenderingIsRemote, getSortedLayersNumPasses, getSortedTrianglesNumCaches, getSortedTrianglesSortFrequency, getSynchronizer, getTransparencyType, getUpdateArea, getViewportRegion, handleTransparency, handleTransparency, handleTransparency, howToRenderScene, isAlphaTest, isDoingDepthPeeling, isPassUpdate, isSmoothing, isSortedLayersSupported, isSortedLayersSupported, isUsedCacheContext, postDelayedTraversal, preDelayedTraversal, resetFrameCounter, resetFrameCounter, setAlphaTest, setCacheContext, setDecimationValue, setDecimationValue, setDelayedObjDepthWrite, setFastEditSavePolicy, setFastEditSavePolicy, setInvalidateCacheMode, setLogicalViewportRegion, setNumPasses, setPassCallback, setPassCallback, setPassUpdate, setRenderingIsRemote, setSmoothing, setSortedLayersNumPasses, setSortedTrianglesNumCaches, setSortedTrianglesSortFrequency, setTransparencyType, setUpdateArea, setUpState, setViewportRegion, shouldAutoCache, updateTranspList
apply, apply, clearApplyResult, forwardTraversal, getContinueActionInBranchFlag, getCurPath, getNodeAppliedTo, getOriginalPathListAppliedTo, getPathAppliedTo, getPathCode, getPathListAppliedTo, getPipeId, getSceneManager, getState, getWhatAppliedTo, hasTerminated, invalidateState, isBeingApplied, isLastPathListAppliedTo, isUsingAlternateRep, nullAction, resetContinueActionInBranchFlag, setPipeId, setSceneManager, stopActionInBranch, traverse, useAlternateRep
dispose, getAddress, getNativeResourceHandle, startInternalThreads, stopInternalThreads
public SoLineHighlightRenderAction()
public SoLineHighlightRenderAction(SbViewportRegion viewportRegion)
SoGLRenderAction
parameters.public short getLinePattern()
public void setLineWidth(float width)
public void setVisible(boolean b)
public boolean isVisible()
public SbColor getColor()
public void setColor(SbColor c)
public void setLinePattern(short pattern)
SoDrawStyle
for more information. The application is responsible for forcing a redraw of the scene to see the effects of this change.public static void enableElement(java.lang.Class<? extends Inventor> t, int stkIndex)
public float getPointSize()
public float getLineWidth()
public void setPointSize(float size)
SoPointSet
.Generated on January 23, 2025, Copyright © Thermo Fisher Scientific. All rights reserved. http://www.openinventor.com