bd.ByteWidth = sizeof( unsigned int ) * posIndices.size(); // 36 vertices needed for 12 triangles in a triangle list
That could be your problem, You should only hard code values for basic testing or when lazy.
Try changing that to three(assuming that there are only three vertices).
And what do you intend to do with: "posIndices", norIndices, uvIndices?
HTH
As you say it's just for testing.
I use drawIndexed() to draw my vertices. So you mean assimp doesn't export indices for me? If so, I would have to kill myself for struggling for that.................
Assimp does provide/produce indices.
Can you set a breakpoint just after you imported/load the mesh and validate the indices and vertices?
Make sure that the cube has:
- 36 indices
- 24 vertices( if there are per vertex normals ) / 8 if there are no normals.
What GPU do you have?, You could then use the tool from the manufacturer to check out the data.
So if you still get invalid results after stepping through the code with the debugger (look at the indices and positions) I will upload the code I am currently using to get the data from Assimp and an explanation of how it is handled.
But it does seam strange that it is not working as the code looks right.
HTH.