D3D8 - DrawIndexedPrimitive arguments?

Started by
2 comments, last by Nedelman 23 years, 2 months ago
What''s the difference between MinIndex and StartIndex in the call to DrawIndexedPrimitive()? Thanks in advance.
www.gameprojects.com - Share Your Games and Other Projects
Advertisement
Confusing isn''t it...
Well from what I have been reading I think it is like this:
(I''m not 100% sure soo please correct me if I got it wrong).

HRESULT DrawIndexedPrimitive(  D3DPRIMITIVETYPE Type,   // Trianglestrip/list etc.  UINT MinIndex,           // The lowest index number used in the indexbuffer (ie lowest index in the buffer is 100, then set it to 100)  UINT NumVertices,        // Number of vertices in the buffer  UINT StartIndex,         // Where to start in the IB to read indexvalues (usually 0 since you set start params in SetIndices)  UINT PrimitiveCount      // How many primitives to render.); 


Death is lifes way saying your fired.
quote:Original post by Nedelman

What''s the difference between MinIndex and StartIndex in the call to DrawIndexedPrimitive()? Thanks in advance.



Right - the MinIndex is the lowest index number into the
vertex buffer that is used. I.e. with an index list of
10, 12, 8, 4, 14 it would be 4.
StartIndex is the start position within the index buffer
that you are going to start drawing primitives from.
Say if you had an index buffer of 100 indicies and your
primitive started at the 20th entry - StartIndex would
be 20.

MrF.


--
Code..reboot..code..reboot..sigh!
MrF.--Code..reboot..code..reboot..sigh!
Beautiful...thanks all.

www.gameprojects.com - Share Your Games and Other Projects

This topic is closed to new replies.

Advertisement