[Contrast / Blur Effects] Port from QRegion::rects() to QRegion iterators
ClosedPublic

Authored by broulik on Dec 2 2017, 10:09 AM.

Details

Summary

Especially the BlurEffect::expanded() method is called a lot. Saves creating a temporary QVector.

Diff Detail

Repository
R108 KWin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
broulik created this revision.Dec 2 2017, 10:09 AM
Restricted Application added a project: KWin. · View Herald TranscriptDec 2 2017, 10:09 AM
Restricted Application added a subscriber: kwin. · View Herald Transcript
broulik requested review of this revision.Dec 2 2017, 10:09 AM
graesslin added inline comments.
effects/blur/blur.cpp
342

data.clip is not const, so maybe a qAsConst is required here.

broulik added inline comments.Dec 2 2017, 1:58 PM
effects/blur/blur.cpp
342

QRegion::begin() is const, there's no mutable iterator for it.

graesslin accepted this revision.Dec 2 2017, 2:11 PM
This revision is now accepted and ready to land.Dec 2 2017, 2:11 PM
This revision was automatically updated to reflect the committed changes.