Class SoClipPlaneManip
- java.lang.Object
-
- com.openinventor.inventor.Inventor
-
- com.openinventor.inventor.misc.SoBase
-
- com.openinventor.inventor.fields.SoFieldContainer
-
- com.openinventor.inventor.nodes.SoNode
-
- com.openinventor.inventor.nodes.SoClipPlane
-
- com.openinventor.inventor.manips.SoClipPlaneManip
-
- All Implemented Interfaces:
SafeDisposable
public class SoClipPlaneManip extends SoClipPlane
Manipulator to transform a clipping plane. This class defines a manipulator to transform a clipping plane. AnSoJackDragger
allows the user to rotate and translate the clipping plane.This node clips all subsequent shapes in the scene graph to the half-space defined by the plane field. The half-space that is rendered is on the side of the plane in the direction of the plane normal. The half-space that is clipped away is on the side of the plane opposite the direction of the plane normal. For example, if the plane normal is 0,0,1 (pointing in the positive Z direction), then everything in the negative Z direction will be clipped away.
File format/default:
ClipPlaneManip {
plane 1 0 0 0 on true draggerPosition 0 0 0 - See Also:
SoClipPlane
,SoDragger
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.openinventor.inventor.nodes.SoNode
SoNode.RenderModes
-
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand
-
-
Field Summary
Fields Modifier and Type Field Description SoSFVec3f
draggerPosition
Dragger position.-
Fields inherited from class com.openinventor.inventor.nodes.SoClipPlane
on, plane
-
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
-
Constructor Summary
Constructors Constructor Description SoClipPlaneManip()
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SoDragger
getDragger()
Returns the dragger node being employed by this manip.boolean
replaceManip(SoPath p, SoClipPlane newOne)
Replaces this manipulator with a regularSoClipPlane
node.boolean
replaceNode(SoPath p)
Replaces a regularSoClipPlane
node with this manipulator.void
setValue(SbBox3f box, SbVec3f planeNormal, float draggerScaleFactor)
Convenience method to set the clip plane and the dragger position, orientation and size.-
Methods inherited from class com.openinventor.inventor.nodes.SoNode
affectsState, callback, copy, copy, distribute, doAction, getAlternateRep, getBoundingBox, getByName, getMatrix, getPrimitiveCount, getRenderEngineMode, getRenderUnitID, GLRender, GLRenderBelowPath, GLRenderInPath, GLRenderOffPath, grabEventsCleanup, grabEventsSetup, handleEvent, isBoundingBoxIgnoring, isOverride, pick, rayPick, search, setOverride, touch, write
-
Methods inherited from class com.openinventor.inventor.fields.SoFieldContainer
copyFieldValues, copyFieldValues, enableNotify, fieldsAreEqual, get, getAllFields, getEventIn, getEventOut, getField, getFieldName, hasDefaultValues, isNotifyEnabled, set, setToDefaults
-
Methods inherited from class com.openinventor.inventor.misc.SoBase
dispose, getName, isDisposable, isSynchronizable, setName, setSynchronizable
-
Methods inherited from class com.openinventor.inventor.Inventor
getNativeResourceHandle
-
-
-
-
Field Detail
-
draggerPosition
public final SoSFVec3f draggerPosition
Dragger position.
-
-
Method Detail
-
replaceManip
public boolean replaceManip(SoPath p, SoClipPlane newOne)
Replaces this manipulator with a regularSoClipPlane
node.
-
setValue
public void setValue(SbBox3f box, SbVec3f planeNormal, float draggerScaleFactor)
Convenience method to set the clip plane and the dragger position, orientation and size. The clip plane will be the plane defined by planeNormal and the point at the center of box .The dragger will be positioned at the center of box . The size of the dragger geometry will be the default size multiplied by a scale factor. This scale factor is the largest dimension of box multiplied by draggerScaleFactor . The default extent of the main part of
SoJackDragger
is 2, because it extends from -1 to 1 (note that the "arms" of this dragger extend further). Therefore to make the dragger fit inside the specified box, the draggerScaleFactor parameter should be set to 0.5.
-
replaceNode
public boolean replaceNode(SoPath p)
Replaces a regularSoClipPlane
node with this manipulator.
-
getDragger
public SoDragger getDragger()
Returns the dragger node being employed by this manip.
-
-