Animated Vertex Position

BlitzMax Forums/MiniB3D Module/Animated Vertex Position

Uncle(Posted 2009) [#1]
Hello,

Sorry if this question has been ask before, but I would like to find the position of the vertext of an animated mesh. I have routine to scan through all the vertices of a mesh, but it doesnt seem to work with animated b3d models.

Cheers,


Unc


simonh(Posted 2009) [#2]
Copy the VertexX, VertexY, VertexX functions, rename them to AnimVertexX, etc, and change the 'verts' arrays to 'anim_verts'.


Uncle(Posted 2009) [#3]
Thanks Simon. I will give it a go :)


Uncle(Posted 2009) [#4]
Hi Simon,

I followed your advice, but I can't seem to find the correct verts array to reference i.e. 'anim_verts'. I looked in the source code for the TSurface type but don't see any references to an array which stores the animated vertexs? Am I missing something? I hope you can point me in the right directions.


Cheers,


Unc


simonh(Posted 2009) [#5]
Sorry, I got that wrong. There isn't a separate anim_verts array, but instead animated meshes have a separate anim_surf, which you then need to use with the standard VertexX/Y/Z commands.


Uncle(Posted 2009) [#6]
Cheers Simon and thanks for the pointers. I think I have got it working now.