CreateIndexBuffer only works with shorts!
Im having a slight problem using CreateIndexBuffer on certain computers (all with quite low spec graphics cards)
CreateIndexBuffer always succeedes when I use int's as the indices, but when I come to draw the buffer, nothing renders. If i chahge to shorts, then the Create functions succeeds and the buffer renders correctly.
I am using the correct flags when creating the index buffer (informing DX if they are 16 or 32 bit values). I know this becuase it works fine on computers with quite high spec graphics cards.
Has anyone else encountered this problem?
Daisy
Have you checked if the graphic cards support the 32 bit index lists ? AFAIK the low spec cards don't support that and have set a cap flag accordingly to this.
From the DirectX MSDN docs for CreateIndexbuffer : "The MaxVertexIndex member of the D3DCAPS9 structure indicates the types of index buffers that are valid for rendering."
And from the D3DCAPS9 description for MaxVertexIndex : " Maximum size of indices supported for hardware vertex processing. It is possible to create 32-bit index buffers; however, you will not be able to render with the index buffer unless this value is greater than 0x0000FFFF."
Hope this helps,
Metron
From the DirectX MSDN docs for CreateIndexbuffer : "The MaxVertexIndex member of the D3DCAPS9 structure indicates the types of index buffers that are valid for rendering."
And from the D3DCAPS9 description for MaxVertexIndex : " Maximum size of indices supported for hardware vertex processing. It is possible to create 32-bit index buffers; however, you will not be able to render with the index buffer unless this value is greater than 0x0000FFFF."
Hope this helps,
Metron
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement