WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
Bug 64126
Turn antialiasing on only for rects which are are rotated or not scaled
https://bugs.webkit.org/show_bug.cgi?id=64126
Summary
Turn antialiasing on only for rects which are are rotated or not scaled
Dmitry Gorbik
Reported
2011-07-07 14:10:58 PDT
Created
attachment 100029
[details]
reduction If we have two nested divs with different background color, and scaling is applied, border appears.
Attachments
reduction
(395 bytes, text/html)
2011-07-07 14:10 PDT
,
Dmitry Gorbik
no flags
Details
Proposed fix 0.1
(15.06 KB, patch)
2011-07-14 18:07 PDT
,
Dmitry Gorbik
simon.fraser
: review-
Details
Formatted Diff
Diff
Proposed fix 0.2
(11.26 KB, patch)
2011-07-15 15:01 PDT
,
Dmitry Gorbik
no flags
Details
Formatted Diff
Diff
Proposed fix 0.3
(12.71 KB, patch)
2011-07-15 15:15 PDT
,
Dmitry Gorbik
no flags
Details
Formatted Diff
Diff
Proposed fix 0.4
(9.79 KB, patch)
2011-07-15 17:29 PDT
,
Dmitry Gorbik
no flags
Details
Formatted Diff
Diff
Proposed fix 0.5
(12.72 KB, patch)
2011-07-18 15:30 PDT
,
Dmitry Gorbik
webkit-ews
: commit-queue-
Details
Formatted Diff
Diff
Proposed fix 0.6
(15.17 KB, patch)
2011-07-18 16:54 PDT
,
Dmitry Gorbik
simon.fraser
: review-
Details
Formatted Diff
Diff
Proposed fix 0.7
(14.22 KB, patch)
2011-08-15 14:53 PDT
,
Dmitry Gorbik
no flags
Details
Formatted Diff
Diff
Show Obsolete
(6)
View All
Add attachment
proposed patch, testcase, etc.
Dmitry Gorbik
Comment 1
2011-07-14 18:07:27 PDT
Created
attachment 100907
[details]
Proposed fix 0.1 Proposed fix 0.1
Simon Fraser (smfr)
Comment 2
2011-07-15 11:24:23 PDT
Comment on
attachment 100907
[details]
Proposed fix 0.1 View in context:
https://bugs.webkit.org/attachment.cgi?id=100907&action=review
> LayoutTests/transforms/2d/antialiasing-pixel-cracks.html:10 > + There should not be a border
We try to avoid text in pixel results because of platform differences. You can make it an HTML comment.
> Source/WebCore/ChangeLog:8 > + we need to turn antialiasing in the cases when we do not need it: when
... turn off...
> Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp:721 > + if (!canEnableAntialiasing()) > + CGContextSetShouldAntialias(platformContext(), false);
I think this is going to have unwanted side effects. You're changing a lot of behavior here.
> Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp:845 > + if (!canEnableAntialiasing()) > + CGContextSetShouldAntialias(platformContext(), false);
You should call canEnableAntialiasing() just once, and use a flag to reset it.
> Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp:851 > + if (!canEnableAntialiasing()) > + CGContextSetShouldAntialias(platformContext(), true);
These aren't going to nest correctly if you always set it back to true.
> Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp:1159 > +bool GraphicsContext::canEnableAntialiasing(void)
How is this different from !AffineTransform::isIdentityOrTranslationOrFlipped()?
> Source/WebCore/platform/graphics/cg/ImageCG.cpp:188 > + if (!ctxt->canEnableAntialiasing()) > + CGContextSetShouldAntialias(ctxt->platformContext(), false);
I think this is going to have unwanted side effects. You're changing a lot of behavior here.
Dmitry Gorbik
Comment 3
2011-07-15 15:01:53 PDT
Created
attachment 101050
[details]
Proposed fix 0.2
Dmitry Gorbik
Comment 4
2011-07-15 15:15:06 PDT
Created
attachment 101053
[details]
Proposed fix 0.3
Dmitry Gorbik
Comment 5
2011-07-15 17:29:18 PDT
Created
attachment 101076
[details]
Proposed fix 0.4
Dmitry Gorbik
Comment 6
2011-07-18 15:30:27 PDT
Created
attachment 101221
[details]
Proposed fix 0.5
Early Warning System Bot
Comment 7
2011-07-18 15:59:37 PDT
Comment on
attachment 101221
[details]
Proposed fix 0.5
Attachment 101221
[details]
did not pass qt-ews (qt): Output:
http://queues.webkit.org/results/9115441
Gyuyoung Kim
Comment 8
2011-07-18 16:01:13 PDT
Comment on
attachment 101221
[details]
Proposed fix 0.5
Attachment 101221
[details]
did not pass efl-ews (efl): Output:
http://queues.webkit.org/results/9111492
Gustavo Noronha (kov)
Comment 9
2011-07-18 16:08:47 PDT
Comment on
attachment 101221
[details]
Proposed fix 0.5
Attachment 101221
[details]
did not pass gtk-ews (gtk): Output:
http://queues.webkit.org/results/9110582
WebKit Review Bot
Comment 10
2011-07-18 16:13:32 PDT
Comment on
attachment 101221
[details]
Proposed fix 0.5
Attachment 101221
[details]
did not pass chromium-ews (chromium-xvfb): Output:
http://queues.webkit.org/results/9115445
Dmitry Gorbik
Comment 11
2011-07-18 16:54:46 PDT
Created
attachment 101237
[details]
Proposed fix 0.6
Simon Fraser (smfr)
Comment 12
2011-08-12 10:18:03 PDT
Comment on
attachment 101237
[details]
Proposed fix 0.6 View in context:
https://bugs.webkit.org/attachment.cgi?id=101237&action=review
> Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp:724 > + bool restoreAntialiasMode = false; > + if (shouldAntialias()) { > + CGContextSetShouldAntialias(platformContext(), false); > + restoreAntialiasMode = true; > + }
I think this is too general a fix. You'll affect all rendering here, including canvas rendering.
> Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp:1165 > +bool GraphicsContext::needsAntialiasing()
Should be const.
> Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp:1175 > + // Enable AA for any rotated objects. > + if (ctm.a() == -ctm.d() && ctm.b() == ctm.c() && !ctm.b()) > + return false;
The comment doesn't match the code.
> Source/WebCore/platform/graphics/cg/ImageCG.cpp:191 > + bool restoreAntialiasMode = false; > + if (ctxt->shouldAntialias()) { > + CGContextSetShouldAntialias(ctxt->platformContext(), false); > + restoreAntialiasMode = true; > + }
Again, this is too general. You'll change canvas rendering.
Dmitry Gorbik
Comment 13
2011-08-15 14:53:27 PDT
Created
attachment 103959
[details]
Proposed fix 0.7
Andreas Kling
Comment 14
2014-02-05 10:48:05 PST
Comment on
attachment 103959
[details]
Proposed fix 0.7 Clearing review flag on patches from before 2014. If this patch is still relevant, please reset the r? flag.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug