Wireframe of mesh in QtQuick3D (Outlines / Borders of triangles)

258 Views Asked by At

Does anyone know how to make a mesh wireframe in a QtQuick3D (Qt 6.4)? Setting the lines width and their color would be very much appreciated.

Something that would be looking like this (it's done in a Qt3D, not the QtQuick3D, unfortunately):

enter image description here

(https://docs.kdab.com/gammaray-manual/latest/gammaray-qt3dgeometry-inspector.html)

Alternatively, making outline of every triangle would be also very helpful. I'm trying to make it on this custom geometry example, but without any progress. The only thing I figured out was to double-display the single triangles and scale one so that it displays over the other (which is a different color). This creates the outline of the triangle I mean.

I'm using Qt for Python and QML, so they are preferred to do this, but I can also rewrite it from C++, so I will accept anything gratefully :)

1

There are 1 best solutions below

0
user9230031 On

Use DebugSettings object and override the material to show wireframe https://doc-snapshots.qt.io/qt6-dev/qml-qtquick3d-debugsettings.html