GreasedLine direction

In addition to @Tricotou ‘s answer you can specify directions when creating the line in ribbon mode. Your PG with the flat array points should work with the direction specified.

Here is a nice example (this one uses 2D arrays though, but demonstrates the direction property):
ArcRotateCamera axes are confusing - #12 by roland

Docs;
https://doc.babylonjs.com/features/featuresDeepDive/mesh/creation/param/greased_line/greased_line_ribbon#direction-and-width

General advice:
Don’t use Vector3’’s when specifying the points array unless you really need to. Use plain numbers. Vectors are converted to numbers anyway when creating the line mesh.

1 Like