elm-obj-file
elm-obj-file copied to clipboard
Autogenerate normals
This can potentially happen under the hood for Obj.Decode.faces and Obj.Decode.texturedFaces. Right now they would fail if the normals are missing.
Not sure how big of a deal this actually is. One could potentially create an OBJ file that has all the normals in it. In Blender this is as easy as checking “Write Normals” when exporting a file.
If we decide to generate normals in elm-obj-file, we need to consider supporting smoothing groups too. This may increase computational complexity of the code quite a bit. So it might be worth benchmarking loading a file with normals in it and a file where the normals are autogenerated.