Class SBMVisualModelSurface#
ClassList > SBMVisualModelSurface
This class is the base class to describe a visual model surface. More...
#include <SBMVisualModelSurface.hpp>
Inherits the following classes: SBCReferenceTarget
Public Functions#
| Type | Name |
|---|---|
| SBMVisualModelSurface (unsigned int numberOfTriangles, unsigned int numberOfPositions, unsigned int * indexData, float * positionData, float * normalData, float * colorData, unsigned int * flagData, unsigned int * nodeIndexData, float * textureCoordinateData, SBTexture * diffuseTexture) Builds a triangle surface. |
|
| float * | getColorData () const Returns the color data. |
| SBTexture * | getDiffuseTexture () const Returns the diffuse texture. |
| unsigned int * | getFlagData () const Returns the flag data. |
| unsigned int * | getIndexData () const Returns the index data. |
| unsigned int * | getNodeIndexData () const Returns the node index data. |
| float * | getNormalData () const Returns the normal data. |
| unsigned int | getNumberOfPositions () const Returns the number of positions. |
| unsigned int | getNumberOfTriangles () const Returns the number of triangles. |
| float * | getPositionData () const Returns the position data. |
| float * | getTextureCoordinateData () const Returns the texture coordinate data. |
| void | setColorData (float * colorData) Sets the color data. |
| void | setDiffuseTexture (SBTexture * diffuseTexture) Sets the diffuse texture. |
| void | setFlagData (unsigned int * flagData) Sets the flag data. |
| void | setIndexData (unsigned int * indexData) Sets the index data. |
| void | setNodeIndexData (unsigned int * nodeIndexData) Sets the node index data. |
| void | setNormalData (float * normalData) Sets the normal data. |
| void | setNumberOfPositions (unsigned int numberOfPositions) Sets the number of positions. |
| void | setNumberOfTriangles (unsigned int numberOfTriangles) Sets the number of triangles. |
| void | setPositionData (float * positionData) Sets the position data. |
| void | setTextureCoordinateData (float * textureCoordinateData) Sets the texture coordinate data. |
| virtual | ~SBMVisualModelSurface () Deletes the triangle surface. |
Public Functions inherited from SBCReferenceTarget#
| Type | Name |
|---|---|
| SBCReferenceTarget () Builds the reference target. |
|
| unsigned int | getMemoryFootprint () const Returns the memory footprint. |
| void | printReferencesToOwners () const Prints the references to the owners of this reference target. |
| virtual | ~SBCReferenceTarget () Destructor. |
Protected Attributes inherited from SBCReferenceTarget#
| Type | Name |
|---|---|
| SBCReferenceTargetData * | dataPointer A pointer to the private data. |
Protected Functions inherited from SBCReferenceTarget#
| Type | Name |
|---|---|
| SBCReferenceTarget (SBCReferenceTargetData * dataPointer) Protected constructor. |
|
| void | removeAllReferenceOwners () Stops all the reference owners from referencing this reference target. |
Detailed Description#
Short name: SBSurface
Public Functions Documentation#
function SBMVisualModelSurface#
Builds a triangle surface.
SBMVisualModelSurface::SBMVisualModelSurface (
unsigned int numberOfTriangles,
unsigned int numberOfPositions,
unsigned int * indexData,
float * positionData,
float * normalData,
float * colorData,
unsigned int * flagData,
unsigned int * nodeIndexData,
float * textureCoordinateData,
SBTexture * diffuseTexture
)
Constructs a visual model surface with the specified geometry and texture data.
Parameters:
numberOfTrianglesThe number of triangles that compose the surface.numberOfPositionsThe number of vertex positions in the surface.indexDataPointer to the array of triangle indices.positionDataPointer to the array of vertex positions.normalDataPointer to the array of vertex normals.colorDataPointer to the array of vertex colors.flagDataPointer to the array of vertex flags.nodeIndexDataPointer to the array of node indices associated with vertices.textureCoordinateDataPointer to the array of texture coordinates.diffuseTexturePointer to the diffuse texture applied to the surface.
function getColorData#
Returns the color data.
Retrieves the color data array.
Returns:
Pointer to the array of vertex colors.
function getDiffuseTexture#
Returns the diffuse texture.
Retrieves the diffuse texture applied to the surface.
Returns:
Pointer to the diffuse texture.
function getFlagData#
Returns the flag data.
Retrieves the flag data array.
Returns:
Pointer to the array of vertex flags.
function getIndexData#
Returns the index data.
Retrieves the index data array.
Returns:
Pointer to the array of triangle indices.
function getNodeIndexData#
Returns the node index data.
Retrieves the node index data array.
Returns:
Pointer to the array of node indices associated with vertices.
function getNormalData#
Returns the normal data.
Retrieves the normal data array.
Returns:
Pointer to the array of vertex normals.
function getNumberOfPositions#
Returns the number of positions.
Retrieves the number of vertex positions in the surface.
Returns:
The number of positions.
function getNumberOfTriangles#
Returns the number of triangles.
Retrieves the number of triangles in the surface.
Returns:
The number of triangles.
function getPositionData#
Returns the position data.
Retrieves the position data array.
Returns:
Pointer to the array of vertex positions.
function getTextureCoordinateData#
Returns the texture coordinate data.
Retrieves the texture coordinate data array.
Returns:
Pointer to the array of texture coordinates.
function setColorData#
Sets the color data.
Sets the color data array.
Parameters:
colorDataPointer to the new array of vertex colors.
function setDiffuseTexture#
Sets the diffuse texture.
Sets the diffuse texture for the surface.
Parameters:
diffuseTexturePointer to the new diffuse texture.
function setFlagData#
Sets the flag data.
Sets the flag data array.
Parameters:
flagDataPointer to the new array of vertex flags.
function setIndexData#
Sets the index data.
Sets the index data array.
Parameters:
indexDataPointer to the new array of triangle indices.
function setNodeIndexData#
Sets the node index data.
Sets the node index data array.
Parameters:
nodeIndexDataPointer to the new array of node indices.
function setNormalData#
Sets the normal data.
Sets the normal data array.
Parameters:
normalDataPointer to the new array of vertex normals.
function setNumberOfPositions#
Sets the number of positions.
Sets the number of vertex positions in the surface.
Parameters:
numberOfPositionsThe new number of positions.
function setNumberOfTriangles#
Sets the number of triangles.
Sets the number of triangles in the surface.
Parameters:
numberOfTrianglesThe new number of triangles.
function setPositionData#
Sets the position data.
Sets the position data array.
Parameters:
positionDataPointer to the new array of vertex positions.
function setTextureCoordinateData#
Sets the texture coordinate data.
Sets the texture coordinate data array.
Parameters:
textureCoordinateDataPointer to the new array of texture coordinates.
function ~SBMVisualModelSurface#
Deletes the triangle surface.
Destroys the visual model surface and releases its associated resources.