Microsoft DirectX 8.1 (Visual Basic)

D3DXBaseMesh.GetDeclaration

Retrieves a declaration describing the vertices in the mesh.

object.GetDeclaration( _ 
    Declaration As Long)

Parts

object
Object expression that resolves to a D3DXBaseMesh object.
Declaration
First element of an array describing the vertex format of the vertices in the queried mesh. The upper limit of this declarator array is MAX_FVF_DECL_SIZE, limiting the declarator to a maximum of 20 Long values. See Remarks.

Error Codes

If the method fails, an error is raised and Err.Number can be set to D3DERR_INVALIDCALL.

For information on trapping errors, see the Microsoft® Visual Basic® Error Handling topic.

Applies To

This method applies to the following classes, which implement methods from D3DXBaseMesh.

Remarks

This code fragment shows how to pass in a D3DXDECLARATOR to retrieve the declaration of a mesh. This assumes there is an existing D3DXMesh object (d3dxm) that contains a mesh.

Dim d3dxd As D3DXDECLARATOR

'This assumes that (d3dxm) has been properly initialized
Call d3dxd.GetDeclaration(d3dxd.Value(0))

See Also

D3DXBaseMesh.GetFVF