Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.7.0
-
None
-
dfc338613ef54de67f2f2b2962d08b0c5a99fcdd
Description
Qt 3D uses threaded rendering which means we need to be informed when the surface we are drawing to is about to be destroyed. In all other cases we receive the platform surface events informing us of imminent surface destruction. But in the case of using QWidget::createWIndowContainer we do not receive this event until too late. In fact it's only sent in response to the QApplication dtor.
https://codereview.qt-project.org/#/c/159467/ was a hack that works around the issue. However a proper fix is needed to allow Qt 3D to be used with createWindowContainer. Such a fix should ensure that the platform surface event gets emitted sooner to allow Qt 3D's renderer to not cleanup and not use the surface any longer.