D29131: [scene] Generate window quads for sub-surfaces
Vlad Zahorodnii
noreply at phabricator.kde.org
Thu Apr 23 18:17:26 BST 2020
zzag added inline comments.
INLINE COMMENTS
> apol wrote in scene.cpp:1035
> How about
>
> for (const QRectF &rect : region) {
> const QRect positioned = rect.translated(position);
> const QRect scaled = rect * scale;
>
> quad[0] = WindowVertex(positioned.topLeft(), scaled.topLeft());
> quad[1] = WindowVertex(positioned.topRight(), scaled.topRight());
> quad[2] = WindowVertex(positioned.bottomRight(), scaled.bottomRight());
> quad[3] = WindowVertex(positioned.bottomLeft(), scaled.bottomLeft());
>
> quads << quad;
> }
Can't do `rect * scale` because it rounds numbers.
REPOSITORY
R108 KWin
REVISION DETAIL
https://phabricator.kde.org/D29131
To: zzag, #kwin
Cc: apol, ngraham, kwin, Orage, cacarry, LeGast00n, The-Feren-OS-Dev, cblack, jraleigh, zachus, fbampaloukas, mkulinski, ragreen, jackyalcine, iodelay, crozbo, bwowk, ZrenBot, alexeymin, himcesjf, lesliezhai, ali-mohamed, hardening, romangg, jensreuterberg, abetts, sebas, ahiemstra, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kwin/attachments/20200423/84162016/attachment.html>
More information about the kwin
mailing list