How to display an array of vertices as a mesh in QML3D.



  • How to runtime generate a square, curved pipe between given points? I have already a curved line between them (thanks to Bezier), and now the challenge is to 'inflate' it. Turn 2d line into 3d curved cuboid. I have a basic knowledge how to turn a line into an vertex of triangles. But I am green, when it comes to display them inside QML.

    The first step is to load array of floats with triangles vertices into QBuffer I think. But what goes next?

    1. How to generate such an array from a line (array of 2d points).
    2. How to render QBuffer into QML 3D scene?

Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.