Data structures and constant
[VolumeViz Shader API]

VolumeViz VolumeViz GLSL shaders data structures and constants. More...

Classes

struct  VVizVoxelInfo
 Defines voxel state info used with the VolumeViz Shader Library API. More...

Defines

#define VVizDefaultData   VVIZ_DATATYPE(0.0)
#define VVizTileInfo   vec4

Functions

vec3 VVizGetVolumeDimensions (in VVizDataSetId dataset)
vec3 VVizGetTileDimensions (in VVizDataSetId dataset)
vec3 VVizGetVoxelDimensions (in VVizDataSetId dataset)
int VVizGetTileResolution (in VVizTileInfo tileInfo)
VVizTileInfo VVizGetTileInfo (in VVizDataSetId dataset, in vec3 dataCoord)
void VVizGetTileIJKBox (in VVizDataSetId dataset, in vec3 dataCoord, out vec3 tileIJKMin, out vec3 tileIJKMax)
VVizDataSetId VVizGetDefaultDataSet ()
vec4 VVizTextureToObject (in VVizDataSetId dataset, in vec4 texCoord)
vec3 VVizTextureToObjectVec (in VVizDataSetId dataset, in vec3 texCoord)
vec3 VVizTextureToObjectDir (in VVizDataSetId dataset, in vec3 texCoord)
vec4 VVizObjectToTexture (in VVizDataSetId dataset, in vec4 objectCoord)
vec3 VVizObjectToTextureVec (in VVizDataSetId dataset, in vec3 objectCoord)
vec3 VVizObjectToTextureDir (in VVizDataSetId dataset, in vec3 objectCoord)
vec4 VVizTextureToWorld (in VVizDataSetId dataset, in vec4 texCoord)
vec3 VVizTextureToWorldVec (in VVizDataSetId dataset, in vec3 texCoord)
vec3 VVizTextureToWorldDir (in VVizDataSetId dataset, in vec3 texCoord)
vec4 VVizWorldToTexture (in VVizDataSetId dataset, in vec4 worldCoord)
vec3 VVizWorldToTextureVec (in VVizDataSetId dataset, in vec3 worldCoord)
vec3 VVizWorldToTextureDir (in VVizDataSetId dataset, in vec3 worldCoord)
vec4 VVizTextureToTexture (in VVizDataSetId datasetSrc, in VVizDataSetId datasetDst, in vec4 texCoord)
vec3 VVizTextureToTextureVec (in VVizDataSetId datasetSrc, in VVizDataSetId datasetDst, in vec3 texCoord)
vec3 VVizTextureToTextureDir (in VVizDataSetId datasetSrc, in VVizDataSetId datasetDst, in vec3 texCoord)

Detailed Description

VolumeViz VolumeViz GLSL shaders data structures and constants.

The following pre-processing directives are dynamically added to the shader pipeline and can be used by application defined shader functions.

- VVIZ_DATARGBA : Is true if VVizData (VolumeViz input data) contains RGBA values.
In this case each value in VVizData is a vec4. Otherwise each value is a float.
(Before Open Inventor 8.5 only float values were supported.)

- VVIZ_DATATYPE : A string defining the GLSL data type in the volume (VVizData).
If VVIZ_DATARGBA is true, then VVIZ_DATATYPE is defined as "vec4", in all other cases it is defined as "float".
(Before Open Inventor 8.5 only type float was supported.)

- VVIZ_NUM_CLIPPING_PLANES : Defines the current numbers of GL clipping planes to take in account.

- VVIZ_SHAPE_TYPE : Define the shape that is currently rendered.
It can be usefull to specialize shader behavior depending on dhape type. It can be VVIZ_VRENDER, VVIZ_SLICE, VVIZ_OBLSLICE, VVIZ_VGEOM, VVIZ_VSKIN or VVIZ_HEIGHTFIELD.


Define Documentation

#define VVizDefaultData   VVIZ_DATATYPE(0.0)

Default voxel value returned by VolumeViz shaders when no data is available.

#define VVizTileInfo   vec4

Defines internal VolumeViz tile info data storage.

See VVizGetTileResolution, VVizGetTileInfo


Function Documentation

VVizDataSetId VVizGetDefaultDataSet (  ) 

Returns the default DataSet ID.

vec3 VVizGetTileDimensions ( in VVizDataSetId  dataset  ) 

Returns volume dataset tile dimensions in voxels.

Parameters:
dataset The dataset to retrieve information from.
Returns:
dataset Tile dimension.
void VVizGetTileIJKBox ( in VVizDataSetId  dataset,
in vec3  dataCoord,
out vec3  tileIJKMin,
out vec3  tileIJKMax 
)

Returns VolumeViz tile IJK box info for a specified voxel.

Parameters:
dataset The dataset to which the tileinfo belongs.
dataCoord Uniform data coordinates in volume space.
tileIJKMin ijk min of the tile in voxels.
tileIJKMax ijk max of the tile in voxels.
VVizTileInfo VVizGetTileInfo ( in VVizDataSetId  dataset,
in vec3  dataCoord 
)

Returns VolumeViz tile info for a specified voxel.

Parameters:
dataset The dataset to retrieve information from.
dataCoord Uniform data coordinates in volume space.
Returns:
The tileInfo of the voxel at position dataCoord.
int VVizGetTileResolution ( in VVizTileInfo  tileInfo  ) 

Returns VolumeViz tile resolution info.

Parameters:
tileInfo The tileInfo to retrieve information from.
Returns:
The LDM resolution level of this tile (zero is full resolution).
vec3 VVizGetVolumeDimensions ( in VVizDataSetId  dataset  ) 

Returns volume dimensions of a dataset in voxels.

Parameters:
dataset The dataset to retrieve information from.
Returns:
dataset Dimension.
vec3 VVizGetVoxelDimensions ( in VVizDataSetId  dataset  ) 

Returns volume dataset uniform voxel dimensions.

Parameters:
dataset The dataset to retrieve information from.
Returns:
dataset Voxel uniform dimension.
vec4 VVizObjectToTexture ( in VVizDataSetId  dataset,
in vec4  objectCoord 
)

Converts the input vector from object space to the input dataset's texture space.

Object space corresponds to the space defined by the extent of the dataset.

Parameters:
dataset The dataset to which the texture space belongs.
objectCoord The object space vector, in homogeneous coordinates.
Returns:
The converted vector in texture space, in homogeneous coordinates.
vec3 VVizObjectToTextureDir ( in VVizDataSetId  dataset,
in vec3  objectCoord 
)

Converts the input vector from object space to the input dataset's texture space.

Object space corresponds to the space defined by the extent of the dataset.

Parameters:
dataset The dataset to which the texture space belongs.
objectCoord The 3D object space vector, assumed to be a direction vector.
Returns:
The converted 3D direction vector in the dataset's texture space. The intermediate homogeneous (vec4) value is converted to 3D by ignoring the W component.
vec3 VVizObjectToTextureVec ( in VVizDataSetId  dataset,
in vec3  objectCoord 
)

Converts the input vector from object space to the input dataset's texture space.

Object space corresponds to the space defined by the extent of the dataset.

Parameters:
dataset The dataset to which the texture space belongs.
objectCoord The 3D object space vector, assumed to be a position vector.
Returns:
The converted 3D position vector in the dataset's texture space. The intermediate homogeneous (vec4) value is converted to 3D by dividing the X, Y and Z components by W.
vec4 VVizTextureToObject ( in VVizDataSetId  dataset,
in vec4  texCoord 
)

Converts the input vector from the input dataset's texture space to object space.

Object space corresponds to the space defined by the extent of the dataset.

Parameters:
dataset The dataset to which the texture space belongs.
texCoord The texture coordinate vector in homogeneous coordinates.
Returns:
The converted vector in object space in homogeneous coordinates.
vec3 VVizTextureToObjectDir ( in VVizDataSetId  dataset,
in vec3  texCoord 
)

Converts the input vector from the input dataset's texture space to object space.

Object space corresponds to the space defined by the extent of the dataset.

Parameters:
dataset The dataset to which the texture space belongs.
texCoord The 3D texture coordinate vector, assumed to be a direction vector.
Returns:
The converted 3D direction vector in object space. The intermediate homogeneous (vec4) value is converted to 3D by ignoring the W component.
vec3 VVizTextureToObjectVec ( in VVizDataSetId  dataset,
in vec3  texCoord 
)

Converts the input vector from the input dataset's texture space to object space.

Object space corresponds to the space defined by the extent of the dataset.

Parameters:
dataset The dataset to which the texture space belongs.
texCoord The 3D texture coordinate vector, assumed to be a position vector.
Returns:
The converted 3D position vector in object space. The intermediate homogeneous (vec4) value is converted to 3D by dividing the X, Y and Z components by W.
vec4 VVizTextureToTexture ( in VVizDataSetId  datasetSrc,
in VVizDataSetId  datasetDst,
in vec4  texCoord 
)

Converts the input vector from the texture space of one dataset to the texture space of another dataset.

Parameters:
datasetSrc The dataset to which the initial texture space belongs.
datasetDst The dataset to which the final texture space belongs.
texCoord The texture coordinate vector in the initial texture space, in homogeneous coordinates.
Returns:
The converted vector in the destination texture space, in homogeneous coordinates.
vec3 VVizTextureToTextureDir ( in VVizDataSetId  datasetSrc,
in VVizDataSetId  datasetDst,
in vec3  texCoord 
)

Converts the input vector from the texture space of one dataset to the texture space of another dataset.

Parameters:
datasetSrc The dataset to which the initial texture space belongs.
datasetDst The dataset to which the final texture space belongs.
texCoord The 3D texture coordinate vector, assumed to be a direction vector.
Returns:
The converted 3D direction vector in the destination texture space. The intermediate homogeneous (vec4) value is converted to 3D by ignoring the W component.
vec3 VVizTextureToTextureVec ( in VVizDataSetId  datasetSrc,
in VVizDataSetId  datasetDst,
in vec3  texCoord 
)

Converts the input vector from the texture space of one dataset to the texture space of another dataset.

Parameters:
datasetSrc The dataset to which the initial texture space belongs.
datasetDst The dataset to which the final texture space belongs.
texCoord The 3D texture coordinate vector, assumed to be a position vector.
Returns:
The converted 3D position vector in the destination texture space. The intermediate homogeneous (vec4) value is converted to 3D by dividing the X, Y and Z components by W.
vec4 VVizTextureToWorld ( in VVizDataSetId  dataset,
in vec4  texCoord 
)

Converts the input vector from the input dataset's texture space to world space.

Parameters:
dataset The dataset to which the texture space belongs.
texCoord The texture coordinate vector in homogeneous coordinates.
Returns:
The converted vector in world space in homogeneous coordinates.
vec3 VVizTextureToWorldDir ( in VVizDataSetId  dataset,
in vec3  texCoord 
)

Converts the input vector from the input dataset's texture space to world space.

Parameters:
dataset The dataset to which the texture space belongs.
texCoord The 3D texture coordinate vector, assumed to be a direction vector.
Returns:
The converted 3D direction vector in world space. The intermediate homogeneous (vec4) value is converted to 3D by ignoring the W component.
vec3 VVizTextureToWorldVec ( in VVizDataSetId  dataset,
in vec3  texCoord 
)

Converts the input vector from the input dataset's texture space to world space.

Parameters:
dataset The dataset to which the texture space belongs.
texCoord The 3D texture coordinate vector, assumed to be a position vector.
Returns:
The converted 3D position vector in world space. The intermediate homogeneous (vec4) value is converted to 3D by dividing the X, Y and Z components by W.
vec4 VVizWorldToTexture ( in VVizDataSetId  dataset,
in vec4  worldCoord 
)

Converts the input vector from world space to the input dataset's texture space.

Parameters:
dataset The dataset to which the texture space belongs.
worldCoord The world space vector, in homogeneous coordinates.
Returns:
The converted vector in texture space, in homogeneous coordinates.
vec3 VVizWorldToTextureDir ( in VVizDataSetId  dataset,
in vec3  worldCoord 
)

Converts the input vector from world space to the input dataset's texture space.

Parameters:
dataset The dataset to which the texture space belongs.
worldCoord The 3D world space vector, assumed to be a direction vector.
Returns:
The converted 3D direction vector in the dataset's texture space. The intermediate homogeneous (vec4) value is converted to 3D by ignoring the W component.
vec3 VVizWorldToTextureVec ( in VVizDataSetId  dataset,
in vec3  worldCoord 
)

Converts the input vector from world space to the input dataset's texture space.

Parameters:
dataset The dataset to which the texture space belongs.
worldCoord The 3D world space vector, assumed to be a position vector.
Returns:
The converted 3D position vector in the dataset's texture space. The intermediate homogeneous (vec4) value is converted to 3D by dividing the X, Y and Z components by W.

Open Inventor Toolkit reference manual, generated on 4 Sep 2023
Copyright © Thermo Fisher Scientific All rights reserved.
https://www.openinventor.com/