Export (0) Print
Expand All

D3DXSphereBoundProbe function

Determines if a ray intersects the volume of a sphere's bounding box.

Syntax


BOOL D3DXSphereBoundProbe(
  _In_  const D3DXVECTOR3 *pCenter,
  _In_  FLOAT Radius,
  _In_  const D3DXVECTOR3 *pRayPosition,
  _In_  const D3DXVECTOR3 *pRayDirection
);

Parameters

pCenter [in]

Type: const D3DXVECTOR3*

Pointer to a D3DXVECTOR3 structure, specifying the center coordinate of the sphere.

Radius [in]

Type: FLOAT

Radius of the sphere.

pRayPosition [in]

Type: const D3DXVECTOR3*

Pointer to a D3DXVECTOR3 structure, specifying the origin coordinate of the ray.

pRayDirection [in]

Type: const D3DXVECTOR3*

Pointer to a D3DXVECTOR3 structure, specifying the direction of the ray. This vector should not be (0,0,0) but does not need to be normalized.

Return value

Type: BOOL

Returns TRUE if the ray intersects the volume of the sphere's bounding box. Otherwise, returns FALSE.

Remarks

D3DXSphereBoundProbe determines if the ray intersects the volume of the sphere's bounding box, not just the surface of the sphere.

Requirements

Header

D3DX9Mesh.h

Library

D3dx9.lib

 

 

Community Additions

ADD
Show:
© 2014 Microsoft