I am using Canvas
in QML to draw rotating Rectangle
with OpenGL. Here is the code:
//...
property variant points: []
onPointsChang
Consider using the new scene graph classes instead of Canvas
if performance is critical. In particular, you'd be interested in the QSGGeometryNode class. If you prefer the simplicity of the Canvas
API, you have to be aware of how it's best used. This article gives you some insight into that.
Edit: I've also found improvements on embedded hardware (specifically the Raspberry Pi) using the QQuickPaintedItem class in certain cases.