[effects/screenshot] Upload data to xpixmap in chunks
Summary:
xcb_put_image doesn't handle big images well. Contrary to XPutImage, the
caller must manually split the data in such a way that each xcb_put_image
request doesn't exceed the maximum request length. Not doing so will result
in libxcb shutting down the connection.
CCBUG: 338489
CCBUG: 388182
Test Plan: Take a screenshot of an active fullscreen client on a 4K monitor.
Reviewers: KWin, davidedmundson
Reviewed By: KWin, davidedmundson
Subscribers: davidedmundson, kwin
Tags: KWin
Differential Revision: https://phabricator.kde.org/D21370