D7460: Treat input RGB buffers as premultiplied
David Edmundson
noreply at phabricator.kde.org
Tue Aug 22 09:20:07 UTC 2017
davidedmundson created this revision.
Restricted Application added projects: Plasma on Wayland, Frameworks.
Restricted Application added subscribers: Frameworks, plasma-devel.
REVISION SUMMARY
Currently the server treats incoming buffers as not premultiplied.
KWayland::Client sends data that is ARGB32 and ARGB32_Premultiplied as the same
WL_SHM_FORMAT_ARGB8888.
According to a post on wayland-devel by Fredrik Höglund, all RGB data
should be treated as premultiplied, which matches what Qt is doing.
I've changed client to perform a conversion rather than sending
mismatched data, but this commit will still breaks a bunch of tests in
the stable kwin branch as it compares the server output to a fixed
QImage with a format.
TEST PLAN
Existing tests pass
Modified surface test to check the pixel data relative to the output QImage format
not the input format (i.e both input from ARGB32 and ARGB32_Premultiplied) should
both end up in a QImage with format Premultiplied with premultiplied values.
The existing test was confirming that data was corrupted, checking that even though
the output format was not pre-multiplied, the data was.
REPOSITORY
R127 KWayland
BRANCH
mart/xdgforeign
REVISION DETAIL
https://phabricator.kde.org/D7460
AFFECTED FILES
autotests/client/test_drag_drop.cpp
autotests/client/test_shadow.cpp
autotests/client/test_shm_pool.cpp
autotests/client/test_wayland_seat.cpp
autotests/client/test_wayland_subsurface.cpp
autotests/client/test_wayland_surface.cpp
src/client/buffer.h
src/client/shm_pool.cpp
src/server/buffer_interface.cpp
To: davidedmundson, #plasma
Cc: plasma-devel, #frameworks, leezu, ZrenBot, progwolff, lesliezhai, ali-mohamed, jensreuterberg, abetts, eliasp, sebas, apol, mart, hein, lukas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20170822/041be1a6/attachment.html>
More information about the Plasma-devel
mailing list