Quote:
Heh, it's so incredibly fast it's not even funny Very Happy
Still stuff I can do... in particular, using vertex buffers where supported. Right now, each end octree node has a compiled display list on it that we execute to render that node, and replacing that with a vertex buffer in video RAM might help a bit.
|
On my directX9 renderer at the moment I'm just creating one huge vertex buffer with all the vertices in and one huge index buffer with all the triangles in.
And then I'm going through every triangle and setting it's texture and then drawing it via the index buffer. The only optimization I'm doing is checking if the texture is the same for two consecutive triangles and not setting it again.
Even drawing every triangle individually I'm getting about 3 frames per second on poknowledge.
My next plan would be to pre-sort all triangles into a seperate list for each texture so I can draw many triangles with a single index buffer.
Not sure how culling triangles for visibility fits in with this... I suppose that every frame I need to check each triangle for potential visibility using the octree stuff (Does it have this information for the older zones?) and build a new index buffer containing only the triangles I want to draw for each frame.