DirectX: VertexBuffer with Length 0?
I've got a question about this line:
D3DDevice->CreateVertexBuffer(NUM_VERTICES * sizeof(MyVertex), D3DUSAGE_WRITEONLY, D3D8T_CUSTOMVERTEX, D3DPOOL_MANAGED, &VBMain);
The first Parameter passed is the "Length". I'm assuming this is the size (amount of room) that will be set aside for VBMain (my Vertex Buffer). Here's the problem though:
I start off with no vertices, so, NUM_VERTICES = 0. This is setting aside 0 "Length". I'm wondering if I'll get into some trouble if I try to pass vertices later on that I create during run-time to a Vertex Buffer that was created in this way.
Thanks for any insight :) (And if anyone could clear up what exactly that "Length" means it'd also be appreciated) :)