Not working with imported STL files.
jgphilpott opened this issue · 1 comments
Thanks for your awesome code! It works great with meshes that I create in code, however i'm having an issue getting it to work with meshes that are made from imported STL files.
I’m using this STL loader that is included in the same version of three.js that you are using but im getting this error:
Uncaught TypeError: Cannot read properties of undefined (reading 'x')
It seems to be running into a problem on line 21 of three-csg.js, right here:
vertices.push(new Vertex(vs[f[fm[j]]],f.vertexNormals[j],geom.faceVertexUvs[0][i][j]))
I was previously using ThreeCSG from Chandler Prall with this same STL loader and didn't have any issues. I upgraded to your code because of the update matrix feature but now I can't work with my imported STLs. 😭
Any ideas how we could fix this?
What is the problem it's running into? Is it a crash? Can you show me the exception produced?