[PyQt] Implementation of the QQuickFramebufferObject

Phil Thompson phil at riverbankcomputing.com
Fri Sep 18 18:03:12 BST 2015


On 15 Sep 2015, at 12:14 pm, Rostyslav Lyulinetskyy <info at rostik.de> wrote:
> 
> Hi,
> 
> I am trying to port my c++ code to python and I am integrating a custom OpenGL rendering with Qt Quick via QQuickFramebufferObject (as described here: https://blog.qt.io/blog/2015/05/11/integrating-custom-opengl-rendering-with-qt-quick-via-qquickframebufferobject/)
> Everything works well in c++, but for various reasons I need to port this to python and it doesn't seem to work. The virtual function createRenderer() in the QQuickFramebufferObject must be overridden so one can return a new renderer, but for some reason this function is not even called when using PyQt.
> 
> Is it even possible to override this virtual function from python? Am I missing something?
> 
> Here is a small example to replicate that the createRenderer() function is not called:
> https://gist.github.com/rostikL/7876e4c47fc8dd8ce02f

Tonight's snapshot will make sure createRenderer() is called. However there may well be issues with the ownership of the returned renderer. Please test and let me know.

Phil


More information about the PyQt mailing list