?/TD>
Microsoft DirectX 9.0

D3DXTessellateNPatches Function


Tessellates the given mesh using the N-patch tessellation scheme.

Syntax

HRESULT D3DXTessellateNPatches(      

    LPD3DXMESH pMeshIn,     const DWORD *pAdjacencyIn,     FLOAT NumSegs,     BOOL QuadraticInterpNormals,     LPD3DXMESH *ppMeshOut,     LPD3DXBUFFER *ppAdjacencyOut );

Parameters

pMeshIn
[in] Pointer to an ID3DXMesh interface, representing the mesh to tessellate.
pAdjacencyIn
[in] Pointer to an array of three DWORDs per face that specify the three neighbors for each face in the source mesh. This parameter may be NULL.
NumSegs
[in] Number of segments per edge to tessellate.
QuadraticInterpNormals
[in] If set to TRUE, use quadratic interpolation for normals. If set to FALSE, use linear interpolation.
ppMeshOut
[out] Address of a pointer to an ID3DXMesh interface, representing the returned tessellated mesh.
ppAdjacencyOut
[out] Pointer to an array of three DWORDs per face that specify the three neighbors for each face in the output mesh. This parameter may be NULL.

Return Value

If the function succeeds, the return value is D3D_OK.

If the function fails, the return value can be one of the following values.

D3DERR_INVALIDCALLThe method call is invalid. For example, a method's parameter may have an invalid value.
D3DXERR_INVALIDDATAThe data is invalid.
E_OUTOFMEMORYMicrosoft?Direct3D?could not allocate sufficient memory to complete the call.


Remarks

This function tessellates by using the N-patch algorithm.

Function Information

Headerd3dx9mesh.h
Import libraryd3dx9.lib
Minimum operating systems Windows 98


© 2002 Microsoft Corporation. All rights reserved.