How can I set width of lines?

    const lineMesh = MeshBuilder.CreateLineSystem(
      "m " + this.lineMeshIndex,
      {
        lines: lineArray,
        colors: colorArray,
        updatable: true,
        useVertexAlpha: this.lineVertexAlpha || this.liveTracking,
      },
      scene
    );

This is how I create a system. Please tell me, can I set the width of each line?

AFAIK, there is no width for line system.
Check this thread for some more related infos : Set line width for custom mesh primitive types LineListDrawMode and LineStripDrawMode

This said, maybe GreasedLine is what you need : Creating A GreasedLine | Babylon.js Documentation

1 Like

Thank you! I managed! I build various industrial parts using CreateGreasedLine.

Now this is the question. Can I somehow add “shadows”? Without shadows, the details don’t look the same.

it is cube )))

Can you tell us what the end result should be? I don’t get what you are trying to achieve

How to make this cube beautiful? I want all the faces of the cube to be visible.

do you want to render a cube from lines?

Yes. Cube, eccentric, cylinder, etc. - various industrial parts. For their further printing on a 5D printer.

For example

What is a 5D printer? calling @PatrickRyan to the rescue

3D or 5D printers. https://www.youtube.com/watch?v=-T7VTYm64kw&t=53s

1 Like
2 Likes

How can I improve the rendering of a part drawn with CreateGreasedLine?
image
I would like my parts to look like this.
image
But for now they look like this (((

what are you input datas?

image

Maybe extruding a square/circle shape can help here. You would get a dense mesh with normal, so you can get some lighting

1 Like