Main Page | Class Hierarchy | Alphabetical List | Compound List | Compound Members

# IRdMesh Struct Reference

Inherits IDispatch.

List of all members.

## Public Member Functions
HRESULT | Clear (void)
HRESULT | Create ([in] IRsGenStream *pVerticesStream,[in] IRsGenStream *pTrianglesStream,[in] IRsGenStream *pFacesStream)
HRESULT | GetVerticesStreamGroup ([out, retval] IRdStreamGroup **ppVerticesStreamGrp)
HRESULT | SetVerticesStreamGroup ([in] IRdStreamGroup *pVerticesStreamGrp)
HRESULT | GetTrianglesStreamGroup ([out, retval] IRdStreamGroup **ppTrianglesStreamGrp)
HRESULT | SetTrianglesStreamGroup ([in] IRdStreamGroup *pTrianglesStreamGrp)
HRESULT | GetFacesStreamGroup ([out, retval] IRdStreamGroup **ppFacesStreamGrp)
HRESULT | SetFacesStreamGroup ([in] IRdStreamGroup *pFacesStreamGrp)
RtDWORD | GetNumVertices (void)
HRESULT | SetNumVertices ([in] RtDWORD dwNumVertices)
HRESULT | LockVerticesStream ([in] RtStreamId idStream,[in] RtDWORD dwFlags,[out, retval] void **ppVerticesStream)
HRESULT | UnLockVerticesStream ([in] RtStreamId idStream)
HRESULT | InsertVertices ([in] RtDWORD dwInsertAfter,[in] RtDWORD dwNumVertices)
HRESULT | DeleteVertices ([in] RtDWORD dwDeleteFrom,[in] RtDWORD dwNumVertices)
HRESULT | AttachVerticesStream ([in] IRsGenStream *pGenStream)
HRESULT | DeleteVerticesStream ([in] RtStreamId idStream)
HRESULT | DetachVerticesStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
HRESULT | GetVerticesStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
RtDWORD | GetNumTriangles (void)
HRESULT | SetNumTriangles ([in] RtDWORD dwNumTriangles)
HRESULT | LockTrianglesStream ([in] RtStreamId idStream,[in] RtDWORD dwFlags,[out, retval] void **ppTrianglesStream)
HRESULT | UnLockTrianglesStream ([in] RtStreamId idStream)
HRESULT | InsertTriangles ([in] RtDWORD dwInsertAfter,[in] RtDWORD dwNumTriangles)
HRESULT | DeleteTriangles ([in] RtDWORD dwDeleteFrom,[in] RtDWORD dwNumTriangles)
HRESULT | AttachTrianglesStream ([in] IRsGenStream *pGenStream)
HRESULT | DeleteTrianglesStream ([in] RtStreamId idStream)
HRESULT | DetachTrianglesStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
HRESULT | GetTrianglesStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
RtDWORD | GetNumFaces (void)
HRESULT | SetNumFaces ([in] RtDWORD dwNumFaces)
HRESULT | LockFacesStream ([in] RtStreamId idStream,[in] RtDWORD dwFlags,[out, retval] void **ppFacesStream)
HRESULT | UnLockFacesStream ([in] RtStreamId idStream)
HRESULT | InsertFaces ([in] RtDWORD dwInsertAfter,[in] RtDWORD dwNumFaces)
HRESULT | DeleteFaces ([in] RtDWORD dwDeleteFrom,[in] RtDWORD dwNumFaces)
HRESULT | AttachFacesStream ([in] IRsGenStream *pGenStream)
HRESULT | DeleteFacesStream ([in] RtStreamId idStream)
HRESULT | DetachFacesStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
HRESULT | GetFacesStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
HRESULT | LockCustStream ([in] RtStreamId idStream,[in] RtDWORD dwFlags,[out] void **ppCustStream)
HRESULT | UnLockCustStream ([in] RtStreamId idStream)
HRESULT | DeleteCustStream ([in] RtStreamId idStream)
HRESULT | AttachCustStream ([in] IRsGenStream *pGenStream)
HRESULT | DetachCustStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
HRESULT | GetCustStream ([in] RtStreamId idStream,[out, retval] IRsGenStream **ppGenStream)
HRESULT | GetVertices ([out, retval] IRdVertexStream **pVal)
HRESULT | GetNormals ([out, retval] IRdVertexNormalStream **pVal)
HRESULT | GetTriangles ([out, retval] IRdTriangleStream **pVal)
HRESULT | RemoveAutomaticStreams ()

## Detailed Description

IRdMesh data object contain mesh representation of the object. It provides storage for vertices, triangles and faces, provides serialization, stream managements... . Meshes in Rosetta are defined by indexed data streams. Indexes are usualy stored in triangle streams or vertex streams, data objects are stored in custom streams.
Example:
Create IRdTriangleStream with triangles. Each item of triangle tripple index structure contains index to vertex stream. Vertex stream (IRdVertexStream) contain actual positions of vertices in object space.
To add texture coordinates, create IRdUVTriangleStream and fill it with indices to UV coordinates. UV coordinates are stored in IRdUVCoordStream.

## Member Function Documentation

HRESULT IRdMesh::Clear | ( | void |  | ) |

| Clears all streams in mesh Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::Create | ( | [in] IRsGenStream * | pVerticesStream,
|  | [in] IRsGenStream * | pTrianglesStream,
|  | [in] IRsGenStream * | pFacesStream
| ) |

  | Creates mesh with given streams for vertices, triangles = triple indices and faces Parameters:
  pVerticesStream | stream with vertex coordinates
  pTrianglesStream | stream with triangle triple indices
  pFacesStream | stream with identification of faces to triangles
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetVerticesStreamGroup | ( | [out, retval] IRdStreamGroup ** | ppVerticesStreamGrp | ) |

  | Returns stream group object with all streams for vertices Parameters:
  ppVerticesStreamGrp | returned vertex stream group object
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::SetVerticesStreamGroup | ( | [in] IRdStreamGroup * | pVerticesStreamGrp | ) |

  | Sets stream group object with all streams for vertices Parameters:
  pVerticesStreamGrp | given vertex stream group object
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetTrianglesStreamGroup | ( | [out, retval] IRdStreamGroup ** | ppTrianglesStreamGrp | ) |

  | Returns stream group object with all streams for triangles Parameters:
  ppTrianglesStreamGrp | returned triangle stream group object
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::SetTrianglesStreamGroup | ( | [in] IRdStreamGroup * | pTrianglesStreamGrp | ) |

  | Sets stream group object with all streams for triangles Parameters:
  pTrianglesStreamGrp | triangle stream group object to be set
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetFacesStreamGroup | ( | [out, retval] IRdStreamGroup ** | ppFacesStreamGrp | ) |

  | Returns stream group object with all streams for faces Parameters:
  ppFacesStreamGrp | returned face stream group object
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::SetFacesStreamGroup | ( | [in] IRdStreamGroup * | pFacesStreamGrp | ) |

  | Sets stream group object with all streams for faces Parameters:
  pFacesStreamGrp | face stream group object
Returns: standard HRESULT processing can be applied to returned value

RtDWORD IRdMesh::GetNumVertices | ( | void |  | ) |

  | Returns number of vertices Parameters:
  pdwNumVertices | number of vertices
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::SetNumVertices | ( | [in] RtDWORD | dwNumVertices | ) |

  | Sets number of vertices Parameters:
  dwNumVertices | number of vertices
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::LockVerticesStream | ( | [in] RtStreamId | idStream,
|  | [in] RtDWORD | dwFlags,
|  | [out, retval] void ** | ppVerticesStream
| ) |

  | Locks given vertices stream and returns access pointer to that stream Parameters:
  idStream | identification of stream to be locked
  dwFlags | flags for locking
  ppVerticesStream | returned locked stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::UnLockVerticesStream | ( | [in] RtStreamId | idStream | ) |

  | Unlocks given vertices stream Parameters:
  idStream | identification of stream to be unlocked
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::InsertVertices | ( | [in] RtDWORD | dwInsertAfter,
|  | [in] RtDWORD | dwNumVertices
| ) |

  | Inserts default elements into all vertices stream Parameters:
  dwInsertAfter | index of element to insert after
  dwNumVertices | number of elements to be inserted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DeleteVertices | ( | [in] RtDWORD | dwDeleteFrom,
|  | [in] RtDWORD | dwNumVertices
| ) |

  | Delete elements in all vertices stream Parameters:
  dwDeleteFrom | index of element to begin deleting
  dwNumVertices | number of elements to be deleted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::AttachVerticesStream | ( | [in] IRsGenStream * | pGenStream | ) |

  | Inserts stream into vertices stream group Parameters:
  pGenStream | stream to be inserted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DeleteVerticesStream | ( | [in] RtStreamId | idStream | ) |

  | Delete stream from vertices stream group Parameters:
  idStream | stream identifier
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DetachVerticesStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Removes stream from vertices stream group and returns it Parameters:
  idStream | stream identifier
  ppGenStream | returned detached stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetVerticesStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Returns stream from vertices stream group Parameters:
  idStream | stream identifier
  ppGenStream | returned stream
Returns: standard HRESULT processing can be applied to returned value

RtDWORD IRdMesh::GetNumTriangles | ( | void |  | ) |

  | Returns number of triangles Parameters:
  pdwNumTriangles | number of triangles
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::SetNumTriangles | ( | [in] RtDWORD | dwNumTriangles | ) |

  | Sets number of triangles Parameters:
  dwNumTriangles | number of triangles
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::LockTrianglesStream | ( | [in] RtStreamId | idStream,
|  | [in] RtDWORD | dwFlags,
|  | [out, retval] void ** | ppTrianglesStream
| ) |

  | Locks given triangles stream and returns access pointer to that stream Parameters:
  idStream | identification of stream to be locked
  dwFlags | flags for locking
  ppTrianglesStream | returned locked stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::UnLockTrianglesStream | ( | [in] RtStreamId | idStream | ) |

  | Unlocks given triangles stream Parameters:
  idStream | identification of stream to be unlocked
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::InsertTriangles | ( | [in] RtDWORD | dwInsertAfter,
|  | [in] RtDWORD | dwNumTriangles
| ) |

  | Inserts default elements into all triangles stream Parameters:
  dwInsertAfter | index of element to insert after
  dwNumTriangles | number of elements to be inserted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DeleteTriangles | ( | [in] RtDWORD | dwDeleteFrom,
|  | [in] RtDWORD | dwNumTriangles
| ) |

  | Delete elements in all triangles stream Parameters:
  dwDeleteFrom | index of element to begin deleting
  dwNumTriangles | number of elements to be deleted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::AttachTrianglesStream | ( | [in] IRsGenStream * | pGenStream | ) |

  | Inserts stream into triangles stream group Parameters:
  pGenStream | stream to be inserted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DeleteTrianglesStream | ( | [in] RtStreamId | idStream | ) |

  | Delete stream from triangles stream group Parameters:
  idStream | stream identifier
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DetachTrianglesStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Removes stream from triangles stream group and returns it Parameters:
  idStream | stream identifier
  ppGenStream | returned detached stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetTrianglesStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Returns stream from triangles stream group Parameters:
  idStream | stream identifier
  ppGenStream | returned stream
Returns: standard HRESULT processing can be applied to returned value

RtDWORD IRdMesh::GetNumFaces | ( | void |  | ) |

  | Returns number of faces Parameters:
  pdwNumFaces | number of faces
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::SetNumFaces | ( | [in] RtDWORD | dwNumFaces | ) |

  | Sets number of faces Parameters:
  dwNumFaces | number of faces
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::LockFacesStream | ( | [in] RtStreamId | idStream,
|  | [in] RtDWORD | dwFlags,
|  | [out, retval] void ** | ppFacesStream
| ) |

  | Locks given faces stream and returns access pointer to that stream Parameters:
  idStream | identification of stream to be locked
  dwFlags | flags for locking
  ppFacesStream | returned locked stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::UnLockFacesStream | ( | [in] RtStreamId | idStream | ) |

  | Unlocks given faces stream Parameters:
  idStream | identification of stream to be unlocked
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::InsertFaces | ( | [in] RtDWORD | dwInsertAfter,
|  | [in] RtDWORD | dwNumFaces
| ) |

  | Inserts default elements into all faces stream Parameters:
  dwInsertAfter | index of element to insert after
  dwNumFaces | number of elements to be inserted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DeleteFaces | ( | [in] RtDWORD | dwDeleteFrom,
|  | [in] RtDWORD | dwNumFaces
| ) |

  | Delete elements in all faces stream Parameters:
  dwDeleteFrom | index of element to begin deleting
  dwNumFaces | number of elements to be deleted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::AttachFacesStream | ( | [in] IRsGenStream * | pGenStream | ) |

  | Inserts stream into faces stream group Parameters:
  pGenStream | stream to be inserted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DeleteFacesStream | ( | [in] RtStreamId | idStream | ) |

  | Delete stream from faces stream group Parameters:
  idStream | stream identifier
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DetachFacesStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Removes stream from faces stream group and returns it Parameters:
  idStream | stream identifier
  ppGenStream | returned detached stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetFacesStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Returns stream from faces stream group Parameters:
  idStream | stream identifier
  ppGenStream | returned stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::LockCustStream | ( | [in] RtStreamId | idStream,
|  | [in] RtDWORD | dwFlags,
|  | [out] void ** | ppCustStream
| ) |

  | Locks given custom stream and returns access pointer to that stream Parameters:
  idStream | identification of stream to be locked
  dwFlags | flags for locking
  ppFacesStream | returned locked stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::UnLockCustStream | ( | [in] RtStreamId | idStream | ) |

  | Unocks given custom stream Parameters:
  idStream | identification of stream to be unlocked
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DeleteCustStream | ( | [in] RtStreamId | idStream | ) |

  | Deletes given custom stream Parameters:
  idStream | identification of stream to be deleted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::AttachCustStream | ( | [in] IRsGenStream * | pGenStream | ) |

  | Inserts custom stream into mesh Parameters:
  pGenStream | stream to be inserted
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::DetachCustStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Removes custom stream from mesh and returns it Parameters:
  idStream | stream identifier
  ppGenStream | returned detached stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetCustStream | ( | [in] RtStreamId | idStream,
|  | [out, retval] IRsGenStream ** | ppGenStream
| ) |

  | Returns custom stream Parameters:
  idStream | custom stream identifier
  ppGenStream | returned custom stream
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetVertices | ( | [out, retval] IRdVertexStream ** | pVal | ) |

  | Returns stream with vertices coordinates Parameters:
  pVal | returned stream with coordinates of vertices
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetNormals | ( | [out, retval] IRdVertexNormalStream ** | pVal | ) |

  | Returns stream with triple indices for mesh triangles Parameters:
  pVal | returned stream with triple indices
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::GetTriangles | ( | [out, retval] IRdTriangleStream ** | pVal | ) |

  | Returns stream with normals for vertices Parameters:
  pVal | returned stream with normals
Returns: standard HRESULT processing can be applied to returned value

HRESULT IRdMesh::RemoveAutomaticStreams | ( |  | ) |

| Removes all automaticaly generated streams; streams will remain some time in cache if calculation is required again. Returns: standard HRESULT processing can be applied to returned value