Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Qt3D - Dynamic Mesh
THE_MASTER last edited by
Hi! I have a few questions about Qt3D...
For example, i have cylindrical mesh. Can i without re-creating QBuffer with all data and appending QAttribute make next:
- Change x,y,z coordinates of few vertices of mesh?
- Add or Remove few vertices?
Or, if i need change mesh vertices number or vertices coords, i sheuld to re-create all mesh?
m.sue last edited by
I assume its possible to do this as you have access to the QBuffer data via the
buffer()function. You will have to know the internal structure, of course, and adapt the QAttribute members (number of vertices etc.) accordingly afterwards, then maybe even call some update routine on the Qt3DWindow as there was some doubt lately about it being done automatically when the data buffers change.
On the other hand, I assume the functor in the cylindrical and other mesh examples runs in another thread (as e.g. I was not allowed to update GUI objects from within the functor), so you should ask yourself whether you really need the additional complexity to edit the buffers by yourself.