i have a GUI program built on PyQt, the GUI has a QtGraphicsView widget, which has a GraphicsScene, which has a Pixmap item to be displayed and updated, for instance, I use the following line to do this
view.scene().items().setPixmap(QPixmap.fromImage(qimage))
Everytime, i modify the qimage and call this line to update the image display, and it worked well. later i want to add a loop to update the image continuously:
for i in xrange(10):
qimage = .... #make some changes to qimage
view.scene().items().setPixmap(QPixmap.fromImage(qimage))
well,the image does not get updated within the loop. the viewport only display the first image(i=0) and the last image(i = 9), i thought it was because the ViewportUpate option of the GraphicsView widget, but it still does not work after i use:setViewportUpdateMode(QGraphicsView.FullViewportUpdate)
...
Any idea?
Really thanks for the help!