Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.15.2, 6.2.0 Beta1
-
None
-
-
146f8cbf865e0061859dd9f1c7a477db91298052 (qt/qtdeclarative/dev) 2663608da0a3949d3cfb497372cc1b81b0603336 (qt/qtdeclarative/6.2) d7f2ecbc67337f67d497e01271c919766f202614 (qt/qtdeclarative/6.1)
Description
Our application uses QQuickPaintedItem to draw custom elements in QML.
eg a decorated line in the attached example.
With Qt 5.15.2 and Qt 6.2.0 beta we detected a rather large memory leak depending on the
used graphics API.
Qt 5.15.2
OpenGL: no leak
Angle_D3D11: no leak
OpenGLRhi: memory leak
Direct3D11Rhi: memory leak
Qt 6.2.0 (current beta)
OpenGL: memory leak
Angle_D3D11: memory leak
OpenGLRhi: memory leak
Direct3D11Rhi: memory leak
On 6.2.0 all backends seem to "eat" memory" even NullRhi.
A minimum example reproducing the issue is found here:
https://github.com/glaure/qt_rhi_qquickpainteditem_leak
The example is just painting "QLineItems" using a repeater.
(It seems to be important to paint more than one item)
The attached memory screenshots use Qt 5.15.2