?/TD> |
Microsoft DirectX 9.0 |
Computes a bounding sphere for the mesh.
Syntax
HRESULT D3DXComputeBoundingSphere(
LPD3DXVECTOR3 pFirstPosition, DWORD NumVertices, DWORD dwStride, D3DXVECTOR3 *pCenter, FLOAT *pRadius );
Parameters
- pFirstPosition
- [in] Pointer to first position.
- NumVertices
- [in] Number of vertices.
- dwStride
- [in] Number of bytes between position vectors. Use D3DXGetFVFVertexSize to get the stride for a flexible vertex format (FVF).
- pCenter
- [out] D3DXVECTOR3 structure, defining the coordinate center of the returned bounding sphere.
- pRadius
- [out] Radius of the returned bounding sphere.
Return Value
If the function succeeds, the return value is D3D_OK.
If the function fails, the return value can be
D3DERR_INVALIDCALL The method call is invalid. For example, a method's parameter may have an invalid value.
Function Information
Header d3dx9mesh.h Import library d3dx9.lib Minimum operating systems Windows 98