[prev in list] [next in list] [prev in thread] [next in thread]
List: pykde
Subject: [PyQt] Artifacts in rendering QPixmap
From: massimo di stefano <massimodisasha () gmail ! com>
Date: 2018-04-09 10:28:53
Message-ID: 164888F8-77B3-44D7-8CE8-E2C03861D87D () gmail ! com
[Download RAW message or body]
[Attachment #2 (multipart/signed)]
[Attachment #4 (multipart/alternative)]
Hi,
I trying to code a quick way to scroll over a large number of images (10^6), but Im \
having trouble in rendering the image properly. In my attempt I noticed the precence \
of an artifact when I scroll over the images which is visible inthis screen \
recording:
https://cl.ly/qkul <https://cl.ly/qkul>
I tryied to reduce my code to a minimum working example to reproduce the issue, a \
gist is available here:
https://gist.github.com/epifanio/dab2d8a6b07e889607a313eefa6358d1 \
<https://gist.github.com/epifanio/dab2d8a6b07e889607a313eefa6358d1>
while at this link I stored the whole code including a number of images to facilitate \
testiing
https://nextcloud.epinux.com/index.php/s/Z55puQ9apGXUh6f \
<https://nextcloud.epinux.com/index.php/s/Z55puQ9apGXUh6f>
The ui is generated with QtDesigner, I can post the ui file as well if useful to \
debug.
From the gif I posted it is possible to notice the rendering bug in tree moments:
- single press of the buttons [<<<] [>>>]
- quick scroll over the zoom slider
- quick scroll over the image-indexer slider
If I hold the press on the [<<<] [>>>] the "artifact" is not noticiable.
There is also a second (minor) bug, which I don't know if related to the same issu.
The image-index spinbox doesn't refresh when I single press the [<<<] [>>>] buttons,
while its value gets correcctly update when hold press [<<<] [>>>]
(I have to focus with the pointer inside the spin-box to get the value update).
I'm pretty sure there is some bad coding from my side,
perhaps there is a better way to accomplish what I'm tryingto do.
I will really appreciate an help in understanding what I'm doing wrong.
Thanks!
Massimo.
[Attachment #7 (unknown)]
<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; \
-webkit-line-break: after-white-space;" class=""><div class=""><font face="Arial" \
style="font-size: 14px;" class="">Hi,</font></div><div class=""><font face="Arial" \
style="font-size: 14px;" class="">I trying to code a quick way to scroll over a large \
number of images (10^6), but Im having trouble in rendering the image \
properly. </font></div><div class=""><font face="Arial" style="font-size: 14px;" \
class="">In my attempt I noticed the precence of an artifact when I scroll over the \
images which is visible inthis screen recording:</font></div><div class=""><font \
face="Arial" style="font-size: 14px;" class=""><br class=""></font></div><div \
class=""><a href="https://cl.ly/qkul" class=""><font face="Arial" style="font-size: \
14px;" class="">https://cl.ly/qkul</font></a></div><div class=""><font face="Arial" \
style="font-size: 14px;" class=""><br class=""></font></div><div class=""><font \
face="Arial" style="font-size: 14px;" class="">I tryied to reduce my code to a \
minimum working example to reproduce the issue, a gist is available \
here:</font></div><div class=""><font face="Arial" style="font-size: 14px;" \
class=""><br class=""></font></div><div class=""><a \
href="https://gist.github.com/epifanio/dab2d8a6b07e889607a313eefa6358d1" \
class=""><font face="Arial" style="font-size: 14px;" \
class="">https://gist.github.com/epifanio/dab2d8a6b07e889607a313eefa6358d1</font></a></div><div \
class=""><font face="Arial" style="font-size: 14px;" class=""><br \
class=""></font></div><div class=""><font face="Arial" style="font-size: 14px;" \
class="">while at this link I stored the whole code including a number of images to \
facilitate testiing</font></div><div class=""><font face="Arial" style="font-size: \
14px;" class=""><br class=""></font></div><div class=""><a \
href="https://nextcloud.epinux.com/index.php/s/Z55puQ9apGXUh6f" class=""><font \
face="Arial" style="font-size: 14px;" \
class="">https://nextcloud.epinux.com/index.php/s/Z55puQ9apGXUh6f</font></a></div><div \
class=""><font face="Arial" style="font-size: 14px;" class=""><br \
class=""></font></div><div class=""><font face="Arial" style="font-size: 14px;" \
class="">The ui is generated with QtDesigner, I can post the ui file as well if \
useful to debug.</font></div><div class=""><font face="Arial" style="font-size: \
14px;" class=""><br class=""></font></div><div class=""><font face="Arial" \
style="font-size: 14px;" class="">From the gif I posted it is possible to notice the \
rendering bug in tree moments:</font></div><div class=""><font face="Arial" \
style="font-size: 14px;" class="">- single press of the buttons [<<<] \
[>>>]</font></div><div class=""><font face="Arial" style="font-size: 14px;" \
class="">- quick scroll over the zoom slider</font></div><div class=""><font \
face="Arial" style="font-size: 14px;" class="">- quick scroll over the image-indexer \
slider</font></div><div class=""><font face="Arial" style="font-size: 14px;" \
class=""><br class=""></font></div><div class=""><font face="Arial" style="font-size: \
14px;" class="">If I hold the press on the [<<<] [>>>] the \
"artifact" is not noticiable.</font></div><div class=""><font face="Arial" \
style="font-size: 14px;" class=""><br class=""></font></div><div class=""><font \
face="Arial" style="font-size: 14px;" class="">There is also a second (minor) bug, \
which I don't know if related to the same issu. </font></div><div class=""><font \
face="Arial" style="font-size: 14px;" class="">The image-index spinbox doesn't \
refresh when I single press the [<<<] [>>>] \
buttons, </font></div><div class=""><font face="Arial" style="font-size: 14px;" \
class="">while its value gets correcctly update when hold press [<<<] \
[>>>] </font></div><div class=""><font face="Arial" style="font-size: \
14px;" class="">(I have to focus with the pointer inside the spin-box to get the \
value update).</font></div><div class=""><br class=""></div><div class=""><font \
face="Arial" style="font-size: 14px;" class="">I'm pretty sure there is some bad \
coding from my side, </font></div><div class=""><font face="Arial" \
style="font-size: 14px;" class="">perhaps there is a better way to accomplish what \
I'm tryingto do.</font></div><div class=""><font face="Arial" style="font-size: \
14px;" class=""><br class=""></font></div><div class=""><font face="Arial" \
style="font-size: 14px;" class="">I will really appreciate an help in understanding \
what I'm doing wrong.</font></div><div class=""><br class=""></div><div \
class=""><font face="Arial" style="font-size: 14px;" \
class="">Thanks!</font></div><div class=""><font face="Arial" style="font-size: \
14px;" class="">Massimo.</font></div></body></html>
["signature.asc" (signature.asc)]
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCgAdFiEEwC/khsE8G9dsS7/D7Z0D2e1kPVkFAlrLQGUACgkQ7Z0D2e1k
PVmXfQ/8C2MI0L+m/26+K7CT45bD6zjqILyT/DUtCTN8bWs9KqqvFxGBYsoFy9+O
/27Nw5qZorAn1SzcI1kLSAAd10yIibRWtJx3g1IppVslcZckUe0oczpeCBgIojT7
Ke+kLI7jjSWItXZpyWsGiyeKhTHslO28mjBSJRcJOVjUeaCLvhxBFpyzuMvMZU9Y
rSM04ATVJzo1K6Qqits0E/SqeK3TUQ4Gg8NOnTfLxqtFpHksgJzQSQPWHhX8GM5S
FoOhYnD28Xk64uIKiIdQ9RasC4iq9G8Ivc+OOWFSL9w9HneHQJ1nCPRQ4veoP21m
3CCcdzVO9VMP8EdyBYkf7RlGMIT4eeezhwRarGsSMdYevN3a+vEZF+g9BHZRHXvy
ILrCiJJjLF1ZQL07ynAR6E3x2nBZKV0jrEB52ZJyn5PNrOxuq5hAoxMkxKolvKc/
FS4lo9YmED5+WJ7Rriky78tsaev/4Wkfv97k3KvQCUXmEn50SKn3EcgiXluTuV7k
csxIMa3OvepSGikTS/KfruVqiXyu7c4TXgzWXTfccrTnNeSuM9oFpcBpHXBLp2gc
sW1Q2cAV12FhjOcT7pG3sNM181R3Wi4JIRbpfNCsxx94/EIpfQy3gYAsdxQ+SJc5
hNhpsQoNEQUI46k1kfBiPWrQqD3jZl0A+JWi0Tu4Tr0Metl7qq8=
=0y7N
-----END PGP SIGNATURE-----
[Attachment #9 (text/plain)]
_______________________________________________
PyQt mailing list PyQt@riverbankcomputing.com
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic