Condividi tramite


struttura D3DHAL_DP2LINESTRIP (d3dhal.h)

Una struttura D3DHAL_DP2LINESTRIP viene analizzata dal buffer dei comandi dal callback D3dDrawPrimitives2 quando il membro bCommand della struttura D3DHAL_DP2COMMAND è impostato su D3DDP2OP_LINESTRIP e viene usato per eseguire il rendering dei segmenti di linea connessi specificati.

Sintassi

typedef struct _D3DHAL_DP2LINESTRIP {
  WORD wVStart;
} D3DHAL_DP2LINESTRIP, *LPD3DHAL_DP2LINESTRIP;

Members

wVStart

Specifica l'indice nel buffer dei vertici contenente i dati delle coordinate per il vertice iniziale della striscia di linee.

Commenti

Una struttura D3DHAL_DP2LINESTRIP segue la struttura D3DHAL_DP2COMMAND nel buffer dei comandi.

D3dDrawPrimitives2 deve elaborare in sequenza un totale di vertici (wPrimitiveCount + 1) dal vertex buffer. A partire dall'offset del vertex buffer, la sequenza di righe di cui è stato eseguito il rendering è (wVStart, wVStart + 1), (wVStart+ 2 ), (wVStart + 2, wVStart + 3), ..., (wVStart + (wPrimitiveCount - 1), wVStart + wPrimitiveCount). Il valore di wPrimitiveCount viene specificato nella struttura D3DHAL_DP2COMMAND.

La figura seguente mostra una parte di un buffer di comandi di esempio contenente un comando D3DDP2OP_LINESTRIP e una struttura D3DHAL_DP2LINESTRIP. Il driver deve disegnare tre linee connesse usando i quattro vertici seguenti dal buffer dei vertici: (v[4], v[5]), (v[5], v[6]), (v[6], v[7]).

Figura che mostra un buffer dei comandi con un comando D3DDP2OP_LINESTRIP e una struttura D3DHAL_DP2LINESTRIP

Requisiti

Requisito Valore
Intestazione d3dhal.h (include D3dhal.h)

Vedi anche

D3DDP2OP_LINESTRIP

D3DHAL_DP2COMMAND

D3dDrawPrimitives2