Bug 48211

Summary: [Qt] ImageBuffer::platformTransformColorSpace is unnecessarily slow
Product: WebKit Reporter: Andreas Kling <kling>
Component: Layout and RenderingAssignee: QtWebKit Unassigned <webkit-qt-unassigned>
Severity: Normal CC: abarth, eric, webkit.review.bot
Priority: P2 Keywords: Performance, Qt, QtTriaged
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Description Flags
Proposed patch none

Description Andreas Kling 2010-10-24 13:41:57 PDT
This function iterates over a QImage getting and setting every pixel with pixel() and setPixel().
This is ridiculously slow since it does bounds checking and detach() for every pixel. We should grab the bits() and do direct access.
Comment 1 Andreas Kling 2010-10-24 13:55:08 PDT
Created attachment 71697 [details]
Proposed patch
Comment 2 Kenneth Rohde Christiansen 2010-10-24 13:59:12 PDT
Comment on attachment 71697 [details]
Proposed patch

Looks fine. Where did you run into this issue?
Comment 3 Andreas Kling 2010-10-24 14:01:59 PDT
(In reply to comment #2)
> (From update of attachment 71697 [details])
> Looks fine. Where did you run into this issue?

The SVG folks were discussing http://svg-wow.org/filterEffects/chiseled.svg so I gave it a spin in QtTestBrowser. I should have included that in the bug description, sorry.

Thanks for reviewing! <3
Comment 4 Andreas Kling 2010-10-24 14:08:27 PDT
Comment on attachment 71697 [details]
Proposed patch

Clearing flags on attachment: 71697

Committed r70424: <http://trac.webkit.org/changeset/70424>
Comment 5 Andreas Kling 2010-10-24 14:08:36 PDT
All reviewed patches have been landed.  Closing bug.
Comment 6 WebKit Review Bot 2010-10-24 17:58:58 PDT
http://trac.webkit.org/changeset/70424 might have broken Leopard Intel Debug (Tests)
The following tests are not passing: