class
AttributeTessellation
Management functions for geometry attribute tessellation
Properties
Property | Description |
Name | The name of the AttributeTessellation object. (Inherited from Object) |
Methods
Method | Description |
AddObserver | Adds a user-defined observer object to the interface, that will receive events from the interface. (Inherited from Object) |
FilterOpacityOnDisplacementEdges | Filter opacity based on displacement curvature, to separate out islands of different heights. Basically clears opacity values on all triangles where the absolute slope of displacement is above a set threshold. Note that the scene geometries must have both Opacity and Displacement as tessellated attributes. |
GetClass | Get the name of the AttributeTessellation class. (Inherited from Object) |
InjectDisplacementDataIntoScene | Fetch displacement data from the supplied material table and texture table, and inject into the displacement data tessellated attribute. Allowed attribute formats are U16 or F32vec3. |
InjectOpacityDataIntoScene | Fetch opacity data from the supplied material table and texture table, and inject into the opacity data tessellated attribute. Attribute format will always be U8. |
IsA | Returns true if AttributeTessellation is a or is a descendant of the class named as the type parameter. (Inherited from Object) |
IsNull | Returns true if the AttributeTessellation object is invalid. (Inherited from Object) |
IsSameObjectAs | Returns true if the AttributeTessellation object is valid. (Inherited from Object) |
NewTessellatedGeometry | Generates a new tessellated geometry with tessellated attributes applied. |
NewTessellatedScene | Generates a new copy of the scene with tessellated geometries which have tessellated attributes applied. |
NonNull | Returns true if the AttributeTessellation object is valid. (Inherited from Object) |
PrintInfo | Prints the content/info of the AttributeTessellation object to the log. (Inherited from Object) |
RemoveObserver | Removes a previously added observer object. (Inherited from Object) |
SetupAttributeTessellationOnGeometry | Sets up attribute tessellation setup and primitive tessellation on a single geometry. |
SetupAttributeTessellationOnScene | Sets up attribute tessellation and primitive tessellation on a scene. |
Static methods
Method | Description |
IsClassA | Returns true if the class is a or is a descendant of the class named as the type parameter. (Inherited from Object) |
SafeCast | SafeCast makes sure the input object is of a class that can be cast into spAttributeTessellation, and if this is the case, returns the object cast into spAttributeTessellation. (Inherited from Object) |
Properties details
Name
The name of the AttributeTessellation object. (Inherited from Object)
Syntax
SetName parameters
Type | Name | Min | Max | Description |
const char * | name | | | New name of the object. |
GetName return value
Type: spString
Syntax
SetName parameters
Type | Name | Min | Max | Description |
string | name | | | New name of the object. |
GetName return value
Type: string
Syntax
SetName parameters
Name | Type | Min | Max | Description |
name | str | | | New name of the object. |
GetName return value
Type: str
Methods details
AddObserver
Adds a user-defined observer object to the interface, that will receive events from the interface. (Inherited from Object)
Syntax
Parameters
Type | Name | Min | Max | Description |
Observer | observer | | | Observer is the object that will receive events. |
Return value
Type: rid
Syntax
Parameters
Type | Name | Min | Max | Description |
Observer | observer | | | Observer is the object that will receive events. |
Return value
Type: int
Syntax
Parameters
Name | Type | Min | Max | Description |
observer | Observer | | | Observer is the object that will receive events. |
Return value
Type: int
FilterOpacityOnDisplacementEdges
Filter opacity based on displacement curvature, to separate out islands of different heights. Basically clears opacity values on all triangles where the absolute slope of displacement is above a set threshold. Note that the scene geometries must have both Opacity and Displacement as tessellated attributes.
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene which is being processed and has tessellated attributes |
real | slopeThreshold | -1 | 1 | The slope threshold, defined as a dot product of the subtriangle vs the actual triangle. A value of 1 means that the subtriangle normal points exactly along the normal of the main triangle. |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene which is being processed and has tessellated attributes |
float | slopeThreshold | -1 | 1 | The slope threshold, defined as a dot product of the subtriangle vs the actual triangle. A value of 1 means that the subtriangle normal points exactly along the normal of the main triangle. |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
scene | Scene | | | The scene which is being processed and has tessellated attributes |
slopeThreshold | float | -1 | 1 | The slope threshold, defined as a dot product of the subtriangle vs the actual triangle. A value of 1 means that the subtriangle normal points exactly along the normal of the main triangle. |
Return value
Type: bool
GetClass
Get the name of the AttributeTessellation class. (Inherited from Object)
Syntax
Parameters
GetClass takes no parameters.
Return value
Type: spString
Syntax
Parameters
GetClass takes no parameters.
Return value
Type: string
Syntax
Parameters
GetClass takes no parameters.
Return value
Type: str
InjectDisplacementDataIntoScene
Fetch displacement data from the supplied material table and texture table, and inject into the displacement data tessellated attribute. Allowed attribute formats are U16 or F32vec3.
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene which is being processed and has data injected into |
AttributeTessellationSamplingSettings | settings | | | Settings for data injection sampling and format. |
MaterialTable | materials | | | Material table used for lookup of displacement channels. |
TextureTable | textures | | | Texture table used for lookup of displacement images. |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene which is being processed and has data injected into |
AttributeTessellationSamplingSettings | settings | | | Settings for data injection sampling and format. |
MaterialTable | materials | | | Material table used for lookup of displacement channels. |
TextureTable | textures | | | Texture table used for lookup of displacement images. |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
scene | Scene | | | The scene which is being processed and has data injected into |
settings | AttributeTessellationSamplingSettings | | | Settings for data injection sampling and format. |
materials | MaterialTable | | | Material table used for lookup of displacement channels. |
textures | TextureTable | | | Texture table used for lookup of displacement images. |
Return value
Type: bool
InjectOpacityDataIntoScene
Fetch opacity data from the supplied material table and texture table, and inject into the opacity data tessellated attribute. Attribute format will always be U8.
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene which is being processed and has data injected into |
AttributeTessellationSamplingSettings | settings | | | Settings for data injection sampling and format. |
MaterialTable | materials | | | Material table used for lookup of opacity channels. |
TextureTable | textures | | | Texture table used for lookup of opacity images. |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene which is being processed and has data injected into |
AttributeTessellationSamplingSettings | settings | | | Settings for data injection sampling and format. |
MaterialTable | materials | | | Material table used for lookup of opacity channels. |
TextureTable | textures | | | Texture table used for lookup of opacity images. |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
scene | Scene | | | The scene which is being processed and has data injected into |
settings | AttributeTessellationSamplingSettings | | | Settings for data injection sampling and format. |
materials | MaterialTable | | | Material table used for lookup of opacity channels. |
textures | TextureTable | | | Texture table used for lookup of opacity images. |
Return value
Type: bool
IsA
Returns true if AttributeTessellation is a or is a descendant of the class named as the type parameter. (Inherited from Object)
Syntax
Parameters
Type | Name | Min | Max | Description |
const char * | type | | | Name of the class to check if AttributeTessellation is, or is a descendant of. |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
string | type | | | Name of the class to check if AttributeTessellation is, or is a descendant of. |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
type | str | | | Name of the class to check if AttributeTessellation is, or is a descendant of. |
Return value
Type: bool
IsNull
Returns true if the AttributeTessellation object is invalid. (Inherited from Object)
Syntax
Parameters
IsNull takes no parameters.
Return value
Type: bool
Syntax
Parameters
IsNull takes no parameters.
Return value
Type: bool
Syntax
Parameters
IsNull takes no parameters.
Return value
Type: bool
IsSameObjectAs
Returns true if the AttributeTessellation object is valid. (Inherited from Object)
Syntax
Parameters
Type | Name | Min | Max | Description |
Object | object | | | Object to compare with. |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
Object | object | | | Object to compare with. |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
object | Object | | | Object to compare with. |
Return value
Type: bool
NewTessellatedGeometry
Generates a new tessellated geometry with tessellated attributes applied.
Syntax
Parameters
Type | Name | Min | Max | Description |
GeometryData | sourceGeometry | | | The source geometry that is the basis of the tessellation. |
Return value
Type: GeometryData
Syntax
Parameters
Type | Name | Min | Max | Description |
GeometryData | sourceGeometry | | | The source geometry that is the basis of the tessellation. |
Return value
Type: GeometryData
Syntax
Parameters
Name | Type | Min | Max | Description |
sourceGeometry | GeometryData | | | The source geometry that is the basis of the tessellation. |
Return value
Type: GeometryData
NewTessellatedScene
Generates a new copy of the scene with tessellated geometries which have tessellated attributes applied.
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The source scene that is the basis of the tessellation. |
Return value
Type: Scene
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The source scene that is the basis of the tessellation. |
Return value
Type: Scene
Syntax
Parameters
Name | Type | Min | Max | Description |
scene | Scene | | | The source scene that is the basis of the tessellation. |
Return value
Type: Scene
NonNull
Returns true if the AttributeTessellation object is valid. (Inherited from Object)
Syntax
Parameters
NonNull takes no parameters.
Return value
Type: bool
Syntax
Parameters
NonNull takes no parameters.
Return value
Type: bool
Syntax
Parameters
NonNull takes no parameters.
Return value
Type: bool
PrintInfo
Prints the content/info of the AttributeTessellation object to the log. (Inherited from Object)
Syntax
Parameters
PrintInfo takes no parameters.
Syntax
Parameters
PrintInfo takes no parameters.
Syntax
Parameters
PrintInfo takes no parameters.
RemoveObserver
Removes a previously added observer object. (Inherited from Object)
Syntax
Parameters
Type | Name | Min | Max | Description |
rid | observerId | | | ObserverId is the id returned by AddObserver when the observer was added. |
Syntax
Parameters
Type | Name | Min | Max | Description |
int | observerId | | | ObserverId is the id returned by AddObserver when the observer was added. |
Syntax
Parameters
Name | Type | Min | Max | Description |
observerId | int | | | ObserverId is the id returned by AddObserver when the observer was added. |
SetupAttributeTessellationOnGeometry
Sets up attribute tessellation setup and primitive tessellation on a single geometry.
Syntax
Parameters
Type | Name | Min | Max | Description |
GeometryData | geometry | | | The geometry which will receive attribute tessellation basic setup. |
AttributeTessellationSettings | settings | | | An attribute tessellation setting to apply to all geometries in the scene |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
GeometryData | geometry | | | The geometry which will receive attribute tessellation basic setup. |
AttributeTessellationSettings | settings | | | An attribute tessellation setting to apply to all geometries in the scene |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
geometry | GeometryData | | | The geometry which will receive attribute tessellation basic setup. |
settings | AttributeTessellationSettings | | | An attribute tessellation setting to apply to all geometries in the scene |
Return value
Type: bool
SetupAttributeTessellationOnScene
Sets up attribute tessellation and primitive tessellation on a scene.
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene whose geometries will receive attribute tessellation setup. |
AttributeTessellationSettings | settings | | | An attribute tessellation setting to apply to all geometries in the scene |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
Scene | scene | | | The scene whose geometries will receive attribute tessellation setup. |
AttributeTessellationSettings | settings | | | An attribute tessellation setting to apply to all geometries in the scene |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
scene | Scene | | | The scene whose geometries will receive attribute tessellation setup. |
settings | AttributeTessellationSettings | | | An attribute tessellation setting to apply to all geometries in the scene |
Return value
Type: bool
Static methods details
IsClassA
Returns true if the class is a or is a descendant of the class named as the type parameter. (Inherited from Object)
Syntax
Parameters
Type | Name | Min | Max | Description |
const char * | type | | | Name of the class to check if the class is, or is a descendant of. |
Return value
Type: bool
Syntax
Parameters
Type | Name | Min | Max | Description |
string | type | | | Name of the class to check if the class is, or is a descendant of. |
Return value
Type: bool
Syntax
Parameters
Name | Type | Min | Max | Description |
type | str | | | Name of the class to check if the class is, or is a descendant of. |
Return value
Type: bool
SafeCast
SafeCast makes sure the input object is of a class that can be cast into spAttributeTessellation, and if this is the case, returns the object cast into spAttributeTessellation. (Inherited from Object)