Hello everyone !
I encountered an issue today with line meshes !
It turns out that a material’s getBindedMeshes method doesn’t return the LinesMesh objects.
Check it out in the playground below :
Hello everyone !
I encountered an issue today with line meshes !
It turns out that a material’s getBindedMeshes method doesn’t return the LinesMesh objects.
Check it out in the playground below :
While testing, i also found an additional surprising behavior :
Try replacing the line lines.material = lineMat; with lines.material = boxMat; and you’ll get a wireframe box
.
cc @AlitarSemiramis who has done some digging there yesterday already ![]()
Looking ![]()
Good catch @Lecornflake ! There was a bug on how LineMeshes handled materials, and I have added a PR to fix the issue with getBindedMeshes here:
About the wireframe, that is expected. If you look at the LineMesh.ts code, in the material setter, it sets the material fillMode to LineListDrawMode:
So when you apply the box material to the line, fillMode gets changed and that’s why the box appears as a wireframe. Maybe something we should document, I will add a note.
Lightning fast fix as usual
! Thanks a lot !