Vertex Normal issues
Brought to you by:
marcus256
If i try to export an .obj to a .ctm I am experiencing -what looks to me like - vertex normal issues.
Is it possible that duplicate vertices are the reason and if yes why?
http://threever.org/demos/problem/webgl_loader_ctm2.html
http://threever.org/demos/problem/assimpobj.png
obj
http://threever.org/demos/problem/sphereDAEtoOBJ_ASSIMP.obj
converted ctm
Something important to note: Iam using the open asset import library to export different file formats to.obj.
I commented on another bug in which may be referenced by this one:
https://sourceforge.net/tracker/?func=detail&aid=3514482&group_id=258139&atid=1172237
And created a thread on the assimp forum:
https://sourceforge.net/projects/assimp/forums/forum/817654/topic/6063901/index/page/1
I've been experiencing issues with normals during
obj
toctm
conversion. I suspect it's to do with the wayobj
can use separate indices for position/normal. I created a small python script to generate unique vertex/normal pairs within theobj
and the normals came out just fine afterwards.Last edit: jozxyqk 2013-11-01
Could you post a link to your script please???
Had a look for it but can't find it sorry. The basic idea was as follows:
Faces (with "f" at the start of the line) specify indices for each vertex such as '3/4/5'. I just kept a dictionary of these combinations, creating new vertex/texture coord/normals every time I found a new combination, replacing the face's vertex with indices of all the same number (the index of the combination in the dictionary).