Comparing QQuickPaintedItem with QQuickImageProvider
-
Hello PySide community:
I tried to display the video stream from a camera in real-time with PySide6, and it worked well by implementing a subclass of QQuickImageProvider. However, someone mentioned that QQuickImageProvider is a bit complicated, QQuickPaintedItem could be a good alternative which may bring performance improvements, higher customizability, and the ability to implement more features.
Since he was talking based on the context of C++, I've been searching the web for several days. Sadly, there weren't too many results related to implementing QQuickPaintedItem within a PySide/QML project, not to mentions comparison between them.
So here is the quetion from a rookie: Is QQuickPaintedItem really a better option? How about the implement? Can you provide some examples?
Thanks.
-
For an example , see https://doc.qt.io/qtforpython-6/examples/example_quick_painteditem.html . About performance, I cannot really comment.
-
For an example , see https://doc.qt.io/qtforpython-6/examples/example_quick_painteditem.html . About performance, I cannot really comment.
@friedemannkleint Thank you for the reply! I found the same page but didn't pay much attention to it :( , AND it did work. The implement is quite simple. As for the comparision, I'm working on it.
-
E Evko has marked this topic as solved on