XMVector3ComponentsFromNormal

Using a reference normal vector, splits a 3D vector into components that are parallel and perpendicular to the normal.

Syntax

void XMVector3ComponentsFromNormal(
         XMVECTOR *pParallel,
         XMVECTOR *pPerpendicular,
         XMVECTOR V,
         XMVECTOR Normal
)  

Parameters

pParallel
Type: XMVECTOR *

[out]

Address of the component of V that is parallel to Normal.

pPerpendicular
Type: XMVECTOR *

[out]

Address of the component of V that is perpendicular to Normal.

V
Type: XMVECTOR 

[in]

3D vector to break into components.

Normal
Type: XMVECTOR 

[in]

3D reference normal vector.

Return value

None.

Requirements

Header: Declared in directxmath.h.