public class Ruler extends SoNode
Preview Feature means this class is fully supported and can be used in Open Inventor applications. Being tagged as a Preview Feature just means that the implementation is still subject to API changes and adjustments based on feedback from early adopters. Please be also aware that source compatibility might be broken regardless of the Open Inventor compatibility changes policy due to our commitment to bring needed changes to be sure the specifications of this Preview Feature match the expectations of our customers.
This node displays an interactive distance measuring tool on top of an SoOrthoSlice. The user can click and drag to display a line and the physical distance between the clicked point and the current cursor position.
This node is only intended to be used in a "2D" viewing environment using an SoOrthographicCamera, for example viewing a single slice of a medical volume.
This node requires that the application handle mouse press, release and move events. Mouse move events must be forwarded to the node using the manageMouseMove method.
File format/default:
Ruler {
globalFactor | 1 |
label | mm |
Inventor.ConstructorCommand
Modifier and Type | Field and Description |
---|---|
SoSFFloat |
globalFactor
Specifies a scale factor applied to the size of the arrowheads on the line.
|
SoSFString |
label
Specifies a label string appended to the measurement value.
|
VERBOSE_LEVEL, ZeroHandle
Constructor and Description |
---|
Ruler()
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
doAction(SoAction action)
Override doAction function
|
void |
getBoundingBox(SoGetBoundingBoxAction action)
Override getBoundingBox function
|
SoFont |
getFont()
Access the font property
|
void |
GLRender(SoGLRenderAction action)
Override GLRender function
|
void |
manageMouseMove(boolean firstClick,
SoOrthoSliceDetail detail)
The application should call this method with 'true' on the mouse down event
that begins a measure operation, then call this method with 'false' on each
mouse move event during the measure operation.
|
affectsState, callback, copy, copy, distribute, getAlternateRep, getByName, getMatrix, getPrimitiveCount, getRenderUnitID, GLRenderBelowPath, GLRenderInPath, GLRenderOffPath, grabEventsCleanup, grabEventsSetup, handleEvent, isBoundingBoxIgnoring, isOverride, pick, rayPick, search, setOverride, touch, write
copyFieldValues, copyFieldValues, enableNotify, fieldsAreEqual, get, getAllFields, getEventIn, getEventOut, getField, getFieldName, hasDefaultValues, isNotifyEnabled, set, setToDefaults
dispose, getEXTERNPROTO, getName, getPROTO, isDisposable, isSynchronizable, setName, setSynchronizable
getAddress, getNativeResourceHandle, startInternalThreads, stopInternalThreads
public SoSFFloat globalFactor
public SoSFString label
public void doAction(SoAction action)
public void GLRender(SoGLRenderAction action)
public void getBoundingBox(SoGetBoundingBoxAction action)
getBoundingBox
in class SoNode
action
- GetBoundingBox actionpublic void manageMouseMove(boolean firstClick, SoOrthoSliceDetail detail)
public SoFont getFont()
Generated on January 23, 2025, Copyright © Thermo Fisher Scientific. All rights reserved. http://www.openinventor.com