BaseMesh.UpdateSemantics Method |
Language: |
Allows the user to change the mesh declaration without changing the data layout of the vertex buffer.
The call is valid only if the old and new declaration formats have the same vertex size.
Visual Basic Public Sub UpdateSemantics( _
ByVal declaration() As VertexElement _
)C# public void UpdateSemantics(
VertexElement[] declaration
);C++ public:
void UpdateSemantics(
array<VertexElement>^ declaration
);JScript public function UpdateSemantics(
declaration : VertexElement[]
);
declaration Microsoft.DirectX.Direct3D.VertexElement[]
Array of VertexElement structures that describe the vertex format of the mesh vertices.
The BaseMesh.Clone method is used to reformat and change the vertex data layout. For example, it can be used to add space for new normals, texture coordinates, colors, and weights that were not present before.
The BaseMesh.UpdateSemantics method updates the vertex declaration with new semantic information without changing the layout of the vertex buffer. For example, it can be used to re-label a 3-D texture coordinate as a binormal or a tangent, or vice versa.
Exceptions
InvalidCallException The method call is invalid. For example, a method's parameter might contain an invalid value.
Mesh, ProgressiveMesh
Send comments about this topic to Microsoft. © Microsoft Corporation. All rights reserved.
Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center