MD2 Rendering
Put all your data in vertex array or dynamic VBO. It needs to be modified a bit, but it works much faster. There has been some posts how to do this in the past so I sugest you use the search function (or google if this doesn't work)
I found few samples but they only do static models, using display lists and arrays (glDrawArray), but how to do interpolation with such implementation, and I am talknig about OpenGL only
You can either do interpolation on CPU or use vertex program to do it. It depends on where your bottleneck is. And you should be using glDrawElements/glDrawRangeElements.
http://www.gamedev.net/community/forums/topic.asp?topic_id=295128
heheheh, notice how i dump everything into a vertex buffer(well its just a vector then, but that gets loaded into a vertex buffer and sent to the video card), once i make sure that none of my frames are getting corrupted ;-), im going to do interpolation in a glsl program, should work out nicely, ill be using glVertexAttrib3f() (maybe thats the wrong function name, i dont have time to look it up atm though) to specify the offset into the vertex buffer, where the second bit of vertex data is, and from there i just load up the change in time (delta time) into a uniform variable, and off i go
hope that helps
-Dan
heheheh, notice how i dump everything into a vertex buffer(well its just a vector then, but that gets loaded into a vertex buffer and sent to the video card), once i make sure that none of my frames are getting corrupted ;-), im going to do interpolation in a glsl program, should work out nicely, ill be using glVertexAttrib3f() (maybe thats the wrong function name, i dont have time to look it up atm though) to specify the offset into the vertex buffer, where the second bit of vertex data is, and from there i just load up the change in time (delta time) into a uniform variable, and off i go
hope that helps
-Dan
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement