Something I've run across with the Obj parser is some exporters
include the material reference regardless if a material was applied or
not. So even though there is no linked material, the file will
contain:
   mtllib example.mtl
   usemtl defaultMat
This will cause the parser to break. It's a simple fix (open the obj
file in notepad++ or equivalent and remove those two lines) but it can
become annoying. I think it would be good to have a property in the
Obj parser that can toggle whether or not the parser looks to apply a
material. I think something as simple as modify the following would
suffice, but you guys are the experts:

case "usemtl":
     if (useMaterial) aMeshes[aMeshes.length-1].materialid = trunk[1];
     break;

Anyways, hope this is useful feedback. As always, keep up the good
work.

-Eric

Reply via email to