When loading my new character I have been getting intermittent errors or warnings. The model works fine in game but the pipeline either throws an exception or puts up a warning about not all vertices having UV mapping information.
I had been working on the assumption that I have a vertex missing from the UV map. I did some tests in Blender but I could not get any test model to have un-mapped faces or vertices. However after some hunting through the text of the FBX file I eventually found a PolygonVertexIndex group which was formed of only two points.
Faces need at least three points because Blender uses either quads or triangles. So two points must be wrong.
The clever ones among you will immediately think that this is an edge. Well done you'd be right. Edges cannot be UV mapped on their own and therefore they cause the warning when loading the file!
Finding Orphan Vertices or Edges
Now the tricky bit! How do I find one lone edge out of over 8000 edges!
With a bit of trial and error I was able to select all (A) the faces in face select mode and hide (H) all the faces.
I swapped to edge select mode in order to find the edge. I had to select all (A) several times before I could even see the tiny speck of orange flash on and off.
Once found I added it to its own vertex group so I could easily select it again. I can now delete this edge and export the FBX again.
==
I've seen reference to a Clean Meshes tool with a Fix Edges option which does the above but I cannot find it for Blender 2.5. If anyone knows if its available please post a comment. Thanks
==
An orphan edge or vertex is one that does not form part of a face.
Tuesday, 5 July 2011
Subscribe to:
Post Comments (Atom)
2 comments:
Ive had problems over the last few days with our placeholder mesh giving us literally random compile errors (the error would occur randomly at compile time, same error everytime). Sometimes a simple restart would result in a good build, or even changing around few regular lines of code!
I spent quite a few hours trying to figure out what was wrong, with no luck. The error was slightly 'vague' in a sence, but it pointed towards something being wrong with the info in the mesh. So I begun my hunt for anything that looked out of the ordinary. At which point I realised the problem only started arising once i started to tweak our model a bit (splitting & merging vertices). I managed to clean up the mesh for the most part, but still had a few problems.
I then looked into the Blender Mesh Cleanup Script (that you were most likely wondering about in your post). I couldnt find it in Blender 2.5 either (the version I am currently using), but it still is available in older versios of Blender (2.49b). I simply 'appended' my Model Object into 2.49 (deletes animations!), ran the clean up script (edit mode, Mesh->Scritps->Mesh Cleanup), then appended it back to 2.5 and placed my animations back in.
It managed to cut off a few vertices (it actually tells you how many it finds & deletes!) but it still left me with a few lonely edges & verts.
Luckily I found your post/guide here, which solved the problem perfectly for me :D (found 2 lonely edges and 3 verts!!)
so a big thanks for that! Youve saved me many hours :)
~Pete
Pete. Thank you very much for the comment. It is good to know that my post has helped someone.
Post a Comment