I want to draw many EdgeGeometries, so I want to use Instancing to get better performance.
For a normal Mesh its pretty straightforward with InstancedMesh.
How can I do the same with LineSegments?
When I use something like new InstancedMesh(edgeGeo, someMaterial)
Here is a clean fiddle with a normal LineSegment:
How do I make multiple EdgeGeometries/LineSegments with instancing?
Thank you for the link. Is it also possible to achieve this without a shader program?
I want to set the edges on the same position as a normal mesh to get the edges drawn like in this example: https://jsfiddle.net/Browork/pjnsgk0o/16/
I’m searching for a relativly simple solution that has good performance/loadtime with for example 1000 meshes/cylinders
AFAIK, there is no way to achieve it without modifying of shaders, unfortunately. As lines and points have no implemetation of instancing.
Just an example:
Though, maybe there is a way to re-use the data from
.instanceMatrix property of
InstancedMesh, but I didn’t get how to make it.
I also struggle, when the cylinders have different sizes and rotation:
@prisoner849 Haven’t got a notification. Looks amazing!