very interesting functions. As i’m not familiar with geometry data structure, can you please give a usage example ?
How to build a struct vertex for any given mesh ?
I was thinking about that :
- sm = snapshotasmesh (Teapot()) - loop through each vert and get : p = meshop.getvert sm v n = getnormal sm v col = -- vertex color ? uvw1 = getTVert sm <tvert_index_integer> -- how to get tvert from current vert ? - build array of faces indices : fi = for f=1 to sm.numfaces collect ((meshop.getVertsUsingFace sm f) as array) - once i got my vertex array struct, i can call your functions : ComputeTangents myVertStruct fi
Sorry if i bother with noob question