SoHeightFieldGeometry Class |
Height field data node.
Namespace: OIV.VolumeViz.Nodes
The SoHeightFieldGeometry type exposes the following members.
Name | Description | |
---|---|---|
SoHeightFieldGeometry | Constructor. |
Name | Description | |
---|---|---|
AffectsState | Returns true if a node has an effect on the state during traversal. | |
Callback | (Inherited from SoDataSet.) | |
Copy | Calls Copy(false). (Inherited from SoNode.) | |
Copy(Boolean) | Creates and returns an exact copy of the node. | |
CopyFieldValues(SoFieldContainer) | Calls CopyFieldValues(fc, false). (Inherited from SoFieldContainer.) | |
CopyFieldValues(SoFieldContainer, Boolean) | Copies the contents of fc's fields into this object's fields. | |
Dispose |
Releases all resources used by SoDisposable.
(Inherited from SoDisposable.) | |
Distribute | (Inherited from SoNode.) | |
DoAction | (Inherited from SoVolumeData.) | |
EditBoxes | Replace all voxels in the region defined by a list of boxes with the specified value. | |
EditSolidShape | Replaces all voxels intersecting the given shape with the specified value. | |
EditSubVolume(SbBox3i32, SoBufferObject) | Replaces the contents of a subvolume with the given data. | |
EditSubVolume(SbBox3i32, Double) | Replaces the contents of a subvolume with the specified value. | |
EditSurfaceShape | Replaces all voxels intersecting the polygons or lines defined by the surfaceShape and given thickness with the specified value. | |
EditTile(SoLDMTileID, SoBufferObject) | Replaces the contents of a tile with the given data. | |
EditTile(SoLDMTileID, Double) | Replaces the contents of a tile with the specified value. | |
EnableNotify | Notification at this Field Container is enabled (if flag == true) or disabled (if flag == false). | |
Equals | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) | |
FieldsAreEqual | Returns true if this object's fields are exactly equal to fc's fields. | |
FinishEditing | Terminates an editing transaction. | |
Get | Returns the values of the fields of this object in the Open Inventor ASCII file format in the given string. | |
GetAllFields | Returns a list of fields, including the eventIn's and eventOut's. | |
GetAlternateRep | This method is called by actions to allow the node to provide an "alternate representation" when appropriate (typically depending on the action type). | |
GetBoundingBox | (Inherited from SoDataSet.) | |
GetCenterVolumeBox | (Inherited from SoVolumeData.) | |
GetCoordinateType | (Inherited from SoVolumeData.) | |
GetDataSize | Returns the number of bytes per voxel in VolumeViz. | |
GetDataType | Returns the data type. | |
GetDatumSize | Returns the number of bytes per voxel. | |
GetDimension | Returns the data set dimension. | |
GetEventIn | Returns a the eventIn with the given name. | |
GetEventOut | Returns the eventOut with the given name. | |
GetField | Returns a the field of this object whose name is fieldName. | |
GetFieldName | Returns the name of the given field in the fieldName argument. | |
GetFields | Appends references to all of this object's fields to resultList, and returns the number of fields appended. | |
GetHashCode |
Overrides GetHashCode().
(Inherited from SoNetBase.) | |
GetHistogram |
Returns the histogram of the volume data.
Returns null reference if the requested data is not available.
(Inherited from SoVolumeData.) | |
GetLdmDataAccess | Returns a reference to the OIV.LDM.SoLDMDataAccess object. | |
GetLDMReader | Returns a pointer to the current data set reader object. | |
GetLDMTopoOctree | Returns the LDMTopoOctree used by this OIV.LDM.Nodes.SoDataSet. | |
GetMatrix | (Inherited from SoNode.) | |
GetMinMax(Double, Double) | Returns min and max values of the data set. | |
GetMinMax(Int64, Int64) | Returns min and max values of the data set data. | |
GetName | Returns the name of an instance. | |
GetOverlapping | Obsolete. (Inherited from SoDataSet.) | |
GetPrimitiveCount | (Inherited from SoNode.) | |
GetReader | Obsolete. Returns the current data set reader object. | |
GetRectilinearCoordinates | Returns a vector describing mapping from uniform space to rectilinear space. | |
GetRenderEngineMode | Returns the supported Render engine mode. | |
GetRenderUnitID | (Inherited from SoVolumeData.) | |
GetSizeVolumeBox | (Inherited from SoVolumeData.) | |
GetStringName | (Inherited from SoBase.) | |
GetTexMemorySize | Obsolete. Returns the maximum texture memory size to use in mega texels. | |
GetTileDimension | Returns the tile dimension. | |
GetTileIDInMemory | Debug purpose only. | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
GetVolumeBox | (Inherited from SoVolumeData.) | |
GLRender | (Inherited from SoVolumeData.) | |
GLRenderBelowPath | (Inherited from SoNode.) | |
GLRenderInPath | (Inherited from SoNode.) | |
GLRenderOffPath | (Inherited from SoNode.) | |
GrabEventsCleanup | (Inherited from SoNode.) | |
GrabEventsSetup | (Inherited from SoNode.) | |
HandleEvent | (Inherited from SoDataSet.) | |
HasDefaultValues | Returns true if all of the object's fields have their default values. | |
HasEditedTile | Returns true if DataSet has edited tiles. | |
IsBoundingBoxIgnoring | This method is used by getBoundingBox action traversal to know if the current node must be traversed or not, ie the bounding should be ignored. | |
IsDataInMemory | Indicates whether the data attached to a tile is in main memory. | |
IsInMemory | Indicates whether a tile is in main memory. | |
IsNotifyEnabled | Notification is the process of telling interested objects that this object has changed. | |
IsOverride | Returns the state of the override flag. | |
IsSynchronizable | Gets the ScaleViz synchronizable state of this object. | |
NumSigBits | Returns the number of significant bits. | |
Pick | (Inherited from SoDataSet.) | |
RayPick | (Inherited from SoNode.) | |
ReadTile(SoBufferObject, SoLDMTileID, Boolean) | Copies the specified tile into the provided buffer. | |
ReadTile(SoLDMTileID, SoBufferObject, Boolean) | Copies the specified tile into the provided buffer. | |
ReadTile(SoLDMTileID, Byte, Boolean) | Obsolete. (Inherited from SoDataSet.) | |
RedoEditing | Redo all modifications associated with the specified transaction id. | |
ReSampling(SbVec3i32, SoVolumeDataSubMethods) | Obsolete. Calls ReSampling(dimension, subMethod, OIV.VolumeViz.Nodes.SoVolumeData.OverMethods( .SoVolumeData.NONE )). (Inherited from SoVolumeData.) | |
ReSampling(SbVec3i32, SoVolumeDataSubMethods, SoVolumeDataOverMethods) | Obsolete. Re-samples the volume down to or up to the given dimension using the sub-sampling method OIV.VolumeViz.Nodes.SoVolumeData.SubMethods and the over-sampling method OIV.VolumeViz.Nodes.SoVolumeData.OverMethods. | |
ResetReader | (Inherited from SoDataSet.) | |
SaveEditing |
Save modifications to a file.
(Inherited from SoDataSet.) | |
SaveEditing(Boolean) |
Save modifications to a file.
(Inherited from SoDataSet.) | |
SaveEditing(Boolean, IListString) |
Save modifications to a file.
(Inherited from SoDataSet.) | |
Search | (Inherited from SoNode.) | |
Set | Sets one or more fields in this object to the values specified in the given string, which should be a string in the Open Inventor file format. | |
SetLDMReader | Sets the LDM volume reader object to use. | |
SetName | (Inherited from SoBase.) | |
SetOverride | Turns the override flag on or off. | |
SetReader(SoVolumeReader) | Obsolete. Calls SetReader(reader, false). (Inherited from SoDataSet.) | |
SetReader(SoVolumeReader, Boolean) | Obsolete. This method allows the data to be read directly from the disk using the specified subclass of OIV.LDM.Readers.SoVolumeReader. | |
SetRGBAData | Force data to be considered as RGBA values. | |
SetSynchronizable | Sets this to be a ScaleViz synchronizable object. | |
SetTexMemorySize | Obsolete. Specifies the maximum texture memory size to use in mega texels. | |
SetToDefaults | Sets all fields in this object to their default values. | |
StartEditing | Initiate an editing transaction. | |
SubSetting | Obsolete. Extracts the data volume defined by region. | |
ToString |
Converts this SoBase structure to a human readable string.
(Inherited from SoBase.) | |
Touch | Marks an instance as modified, simulating a change to it. | |
UndoEditing | Undo all modifications associated with the specified transaction id. | |
UpdateRegions | Updates regions of the volume that have been modified. | |
UpdateTilesInTextureMemory | Reloads textures corresponding to the given tile IDs. | |
UseFakeData | Creates fake data in buffer. | |
VoxelToXYZ(SbBox3f) | Converts the specified box in voxel coordinates (I,J,K) to geometric coordinates (X,Y,Z). | |
VoxelToXYZ(SbVec3f) | Converts the specified point in voxel coordinates (I,J,K) to geometric coordinates (X,Y,Z). | |
Write | (Inherited from SoDataSet.) | |
WriteTile | Write the specified tile using the specified writer. | |
XYZToVoxel(SbBox3f) | Converts the specified box in geometric coordinates to voxel coordinates. | |
XYZToVoxel(SbVec3f) | Converts the specified point in geometric coordinates (X,Y,Z) to voxel coordinates (I,J,K). |
Name | Description | |
---|---|---|
allocateResourceOnRender | Indicates if resource allocation is done only on first render traversal or as soon as the node is created. | |
data | Specifies the volume data, including dimensions, data type and number of significant bits. | |
dataRGBA | Contains true if the volume contains RGBA values rather than scalar values. | |
dataSetId | When using multiple OIV.LDM.Nodes.SoDataSet nodes, the OIV.LDM.Nodes.SoDataSet.dataSetId field uniquely identifies each data set used in the compositing. | |
dataTransform | If set to an appropriate OIV.LDM.Nodes.SoLDMDataTransform object, the object's transformFunction method is called after each tile is loaded, but before it is stored in main memory. | |
extent | The real size (extent) of the volume in modeling coordinates. | |
fileName | Indicates the file location containing the data set. | |
IsDisposable | ISafeDisposable interface implementation.
(Inherited from SoDisposable.) | |
LDMDataTransformCallback | Obsolete. If set, the user-defined function is called after each tile is loaded, but before it is stored in main memory. | |
ldmResourceParameters | Contains an OIV.LDM.Nodes.SoLDMResourceParameters object which allows you to set LDM resource parameters. | |
Reader | Returns the current data set reader object. | |
texturePrecision | For scalar (non-RGBA) data, specifies the size of voxel values on the GPU in bits. | |
undefinedValue | Data with this value won't be rendered. | |
useCompressedTexture | Controls use of OpenGL lossy texture compression for RGBA data (if available). | |
useExtendedData | If true, VolumeViz stores an additional copy of each loaded tile. | |
usePalettedTexture | For a volume containing scalar data values, controls whether scalar values (true) or RGBA values (false) are loaded on the GPU (the name is historical). | |
UserData |
Gets or sets the user data to be contained by the field container.
(Inherited from SoFieldContainer.) | |
useSharedPalettedTexture | Note: On graphics boards that support programmable shaders, this field is ignored (virtually all graphics boards support programmable shaders). | |
valueInterpretation | Specifies if this dataset corresponds or does not correspond to a segmented image. |
OIV.VolumeViz.Nodes.SoHeightFieldGeometry defines a uniform grid in the XY plane whose vertices are height (Z) values stored in 2D LDM format (any LDM data set with the Z dimension equal to 1). Storing only height values is a very efficient way to represent a surface and LDM supports 8 and 16 bit integer data in addition to float (and other types). Adding the combination of LDM data management with advanced GPU features provides a way to handle extremely large surfaces. Just as with volume data, LDM uses tiles of data and multiple levels of resolution to enable interactive frame rates even for data sets that cannot fit in system memory.
OIV.VolumeViz.Nodes.SoHeightFieldGeometry is derived from OIV.VolumeViz.Nodes.SoVolumeData and serves a similar purpose in the scene graph, providing a reference to an LDM data set which will be loaded as needed by rendering nodes, specifically OIV.VolumeViz.Nodes.SoHeightFieldRender in this case. The geometry is given by the inherited field fileName. The given file must be an LDM file built by the LDM converter (see OIV.LDM.Converters.SoConverter). For use with OIV.VolumeViz.Nodes.SoHeightFieldRender the data set must have a depth (Z dimension) of exactly 1. The inherited field undefinedValue allows to specify an "undefined" value which will be rendered as holes in the grid. This value can also be specified with the -u option of the converter.
Data set values are converted to height values in 3D space in two ways depending on the data type:
Integer values are normalized between [0,1] ([-1,1] for signed types) based on the range of values for the specific data type. For example, for UNSIGNED BYTE values the range 0..255 is mapped to 0..1.
Floating point values are not normalized (are used "as is").
Extent in 3D space
A standard OIV.VolumeViz.Nodes.SoVolumeData node has no intrinsic "extent" in 3D. The extent of the volume is initially defined by the values returned from the volume reader (normally from the extent tag in the LDM file header). The extent field is initialized with these values from the reader and always contains the current extent values. The application can modify the extent of the volume by changing the values in the extent field. (Note that the actual bounding box of the volume in 3D is the volume extent modified by any transform nodes in the scene graph.)
OIV.VolumeViz.Nodes.SoHeightFieldGeometry only uses the X and Y parts of the extent field. The Z extent of the surface in 3D is completely defined by the values in the data set. So the X and Y values in the extent field are the actual extent, but the Z values are not meaningful and changing the Z values in the extent field has no effect. Note that you can always get the current bounding box (X, Y and Z) using an OIV.Inventor.Actions.SoGetBoundingBoxAction and you can still control the bounding box using an OIV.Inventor.Nodes.SoTransform (or similar) node. To scale or offset the height values, put a transform node in the scene graph before the OIV.VolumeViz.Nodes.SoHeightFieldGeometry node. For example, to scale the height values by a factor of 2, you could use an OIV.Inventor.Nodes.SoScale node with the scaleFactor field set to (0,0,2).
Caution |
---|
If you implement your own volume reader, we strongly recommend implementing the method OIV.LDM.Readers.SoVolumeReader.GetTileMinMax(System.Int32). The tile min/max is used to improve the tesselation (adjust the number of triangles depending on the difference between min and max). Because of the way the height field algorithm works, if tile min/max info is not available, VolumeViz must load all height field tiles before the first render. This can cause a long delay before the first rendering appears. |
HeightFieldGeometry {
allocateResourceOnRender | false |
data | NODATA 0 0 0 UBYTE 8 |
dataRGBA | false |
dataSetId | 1 |
dataTransform | NULL |
extent | -1 -1 -1 1 1 1 |
fileName | "" |
texturePrecision | 0 |
undefinedValue | NaN |
useCompressedTexture | true |
useExtendedData | false |
usePalettedTexture | true |
useSharedPalettedTexture | true |