Funzione D3DXMatrixReflect (D3DX10Math.h)

Nota

La libreria di utilità D3DX10 è deprecata. È consigliabile usare invece DirectXMath .

Compila una matrice che riflette il sistema di coordinate su un piano.

Sintassi

D3DXMATRIX* D3DXMatrixReflect(
  _Inout_       D3DXMATRIX *pOut,
  _In_    const D3DXPLANE  *pPlane
);

Parametri

pOut [in, out]

Tipo: D3DXMATRIX*

Puntatore alla struttura D3DXMATRIX risultante dall'operazione.

pPlane [in]

Tipo: const D3DXPLANE*

Puntatore all'origine D3DXPLANE.

Valore restituito

Tipo: D3DXMATRIX*

Puntatore a una struttura D3DXMATRIX che riflette il sistema di coordinate sul piano di origine.

Commenti

Questa funzione normalizza l'equazione del piano prima di creare la matrice riflessa.

Il valore restituito per questa funzione è lo stesso valore restituito nel parametro pOut. In questo modo, la funzione D3DXMatrixReflect può essere usata come parametro per un'altra funzione.

Questa funzione usa la formula seguente per calcolare la matrice restituita.

P = normalize(Plane);

-2 * P.a * P.a + 1  -2 * P.b * P.a      -2 * P.c * P.a        0
-2 * P.a * P.b      -2 * P.b * P.b + 1  -2 * P.c * P.b        0
-2 * P.a * P.c      -2 * P.b * P.c      -2 * P.c * P.c + 1    0
-2 * P.a * P.d      -2 * P.b * P.d      -2 * P.c * P.d        1

Requisiti

Requisito Valore
Intestazione
D3DX10Math.h
Libreria
D3DX10.lib

Vedi anche

Funzioni matematiche