use QQuickRenderControl

Jimmy Girardet ijkl at netc.fr
Wed Jan 6 10:17:06 GMT 2021


Hi, happy new Year,

I was using QQuickRenderControl with pyside2 :

https://github.com/jgirardet/MyCartable/blob/dev/src/mycartable/conversion/grabber.py


I can't make it work with PyQt5. One problematic line is line 45 :

self.m_quickWindow = QQuickWindow(self.m_renderControl)

QQuickWindow with pyqt5 doesn"t accept QQuickREnderControl as parent 
(but it seems C++ does 
https://code.qt.io/cgit/qt/qtdeclarative.git/tree/examples/quick/rendercontrol/window_singlethreaded.cpp?h=5.15#n119)

So how could I use QQuickRenderControl with pyqt5, do you have an example ?

More generally I just want to render some QML offscreen and grab the 
content. Do you have any other way to do it ?


Thanks for help

Jimmy

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20210106/cd613411/attachment.htm>


More information about the PyQt mailing list