Class SoOverlayGroup
- 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.SoGroup
-
- com.openinventor.inventor.nodes.SoOverlayGroup
-
- All Implemented Interfaces:
SafeDisposable
public class SoOverlayGroup extends SoGroup
Group node dedicated to render multiple co-planar shapes. Derived from the classSoGroup
, theSoOverlayGroup
node renders multiple co-planar shapes without any Z-fighting artifacts.Overlapping co-planar shapes should be inserted as children of a
SoOverlayGroup
. The shapes are stacked for the rendering according to their places in the child list: the i th shape will be drawn above the i-1 th shape.For instance, in the following picture the red square is the first shape child, and the green triangle is the second shape child of a
SoOverlayGroup
.In the following picture, the green triangle is the first shape child. In this picture, the square and the triangle are inserted in a SoGroup
, which does not prevent the Z-fighting artifact where the 2 shapes overlap.The
SoOverlayGroup
is only designed to correctly render planar shapes. Inserting inSoOverlayGroup
spheres, cylinders, cubes or any shape whose vertices are not on a single euclidean plane may cause an unexpected rendering. However, this does not limit theSoOverlayGroup
to 2D rendering. You can create severalSoOverlayGroup
instances, but all the shapes under an overlay group must be a planar shape and must be located on the same 3D plane. One different 3D plane per instance ofSoOverlayGroup
is possible as in the following picture from the example "Inventor\Features\OverlayPanels" in which each panel corresponds to one instance of anSoOverlayGroup
.The
SoOverlayGroup
is not designed to solve any Z-fighting artifact on 3D shapes. For instance, a correct rendering of meridian circles onto a sphere requires using eitherSoPolygonOffset
orSoDepthOffset
.# Limitations of the overlay group:
- The
SoHaloHighlightRenderAction
can be used to highlight any shape in aSoOverlayGroup
, but the alwaysVisible option must be true. SeeSoHaloHighlightRenderAction.setHaloAlwaysVisible()
. - The behaviour of a
SoColorHighlightRenderAction
with anSoOverlayGroup
is the same as with anSoGroup
, thus some Z-fighting may occur.
File format/default:
OverlayGroup {
Action behavior:
Similar behavior as described in
SoGroup
.- Since:
- Open Inventor 2024.1
- See Also:
SoDepthOffset
,SoGroup
,SoPolygonOffset
,SoSeparator
,SoSwitch
-
-
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 inherited from class com.openinventor.inventor.nodes.SoGroup
boundingBoxIgnoring
-
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
-
Constructor Summary
Constructors Constructor Description SoOverlayGroup()
Creates an empty overlay group node.
-
Method Summary
-
Methods inherited from class com.openinventor.inventor.nodes.SoGroup
addChild, findChild, getChild, getNumChildren, insertChild, removeAllChildren, removeChild, removeChild, replaceChild, replaceChild
-
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
-
-