Good evening
Is there a simple sample code for converting faceuv to vertex uv while keeping a mesh indexed. If possible only Blender API calls and Python language structures. All the sample scripts are fairly bloated it’s quite hard to get the essential information out of it (the 3ds exporter does that for example).
The format we have to export to basically uses something like that:
v1,…,vn: 1 to n vertices
t1,…,tn: 1 to n texture coordinates
c1,…,cn: 1 to n per vertex colors
i1,…,ik: 1 to k indices where k=3*b with b>0 forming b triangles
[other stuff like motion capture data]
As you can see we only use per vertex colors and texture coordinates (and a bunch of other stuff - all per vertex - the format comes from some research facility they used OpenGL once that’s why this layout for simple usage with glVertexPointer(…) and so on). Has someone a ‘simple’ piece of example code how to convert these face.uv values to per vertex uv’s. The strategy i’d use is duping vertices (3ds export does smth like that) which have multiple texture coordinates associated but i’m somehow not able to get that working in Python:( The 3ds exporter does something like that - it’s just that this code is too complex to adopt it easily for a python newbie><
Or is there an example on the web somewhere (or an article in blender wiki - I could have missed it)
Thanks in advance