Vertex/Vertices Movment..

Blitz3D Forums/Blitz3D Programming/Vertex/Vertices Movment..

hi, i am no b3d pro but i see that your post has been on the forum for several days without recieveing any answer, so here am i.

the philosphy of what you want to do is the following :
. a mesh is a collection of surfaces (one or more)
. a surface is a collection of vertices (one or more)
(. triangles are made of (3) vertices)

so if you want to manipulate vertices, you have to go from the bigger structure to the smaller, that is from the mesh to the vertex :

. mesh=loadmesh() or createmesh() or any mesh
. surface=getsurface(mesh, index of the surface)
. vertex-coord-X=vertexx(surface, index of the vertex)
. idem for Y and Z coordinates

then change those X Y and Z values as you wish :
. vertexcoords surface,index of vertex,X,Y,Z

you will have to adapt the XYZ values of every vertex you want to change ...

but if you change the XYZ coords of a vertex that is part of several triangles, all the triangles will deform.

hoping to be of some help

orion one
.