Class SoHeightFieldDetail
- java.lang.Object
-
- com.openinventor.inventor.Inventor
-
- com.openinventor.inventor.details.SoDetail
-
- com.openinventor.volumeviz.details.SoHeightFieldDetail
-
public class SoHeightFieldDetail extends SoDetail
Stores detail information about a picked cell in a heightfield. A successful pick operation returns anSoPickedPointobject. If the picked geometry is anSoHeightFieldRendernode, use the getDetail method and cast the result to this class to get extra information about the the pick.SoHeightFieldDetailreturns- The i,j,k position of the picked cell (position in data space).
- The value of the picked cell retrieved from the current
SoHeightFieldProperty - or the values of the picked cell when multiple
SoHeightFieldPropertynodes are inherited. - The data set of the picked heightfield, i.e., the current
SoHeightFieldPropertynode. - or the data sets of the picked heightfield, when multiple
SoHeightFieldPropertynodes are inherited.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSoHeightFieldDetail.PropertyInfo-
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand
-
-
Field Summary
-
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
-
Constructor Summary
Constructors Constructor Description SoHeightFieldDetail()Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SoDetailcopy()Returns an instance that is a copy of this instance.SbVec4i32getColor()Returns the color of the picked cell.floatgetHeight()Get the height value of the nearest elevation point.SbVec3i32getIjkPos()Returns the position in data space (cell coordinates) of the picked cell.longgetNumProperties()Returns the number of active properties.SoHeightFieldDetail.PropertyInfogetProperty(long propertyNumber)Returns the specified property and its id.doublegetValue(long propertyNumber)Returns the value of the picked cell in the specified property (SoHeightFieldPropertynode).-
Methods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
-
-
-
Method Detail
-
getNumProperties
public long getNumProperties()
Returns the number of active properties.
-
getProperty
public SoHeightFieldDetail.PropertyInfo getProperty(long propertyNumber)
Returns the specified property and its id.- Parameters:
propertyNumber- is the number of the property to query. Use thegetNumPropertiesmethod to get the number of properties.property- is filled with a pointer to the queried property. NULL if propertyNumber is invalid.id- is filled with the id of the property. -1 if propertyNumber is invalid.
-
getValue
public double getValue(long propertyNumber)
Returns the value of the picked cell in the specified property (SoHeightFieldPropertynode).- Parameters:
propertyNumber- is the number of the property to query.- Returns:
- value. Returns NaN if propertyNumber is not valid. Use the
getNumPropertiesmethod to get the number of properties.
-
getIjkPos
public SbVec3i32 getIjkPos()
Returns the position in data space (cell coordinates) of the picked cell.
-
getColor
public SbVec4i32 getColor()
Returns the color of the picked cell.
-
copy
public SoDetail copy()
Returns an instance that is a copy of this instance. The caller is responsible for deleting the copy when it is no longer needed.
-
getHeight
public float getHeight()
Get the height value of the nearest elevation point.
-
-