Commit Graph

64 Commits

Author SHA1 Message Date
Markus Stange
c9a470f6fb Bug 912945 - Use aligned data storage for DrawTargetCG. r=jrmuizel 2013-09-27 17:20:28 +02:00
Anthony Jones
af656ab898 Bug 918138 - Move Borrowed*Context to a separate header file; r=mattwoodrow 2013-09-23 15:28:16 +12:00
Milan Sreckovic
9618b4a696 Bug 913614 - When the input is invalid, skip the work as we won't get anything useful anyway. r=jmuizelaar 2013-09-06 12:22:20 -07:00
Matt Woodrow
9fd4f7c1c4 Bug 909128 - Support snapshot source surfaces in DrawTargetCG's CopySurface. r=jrmuizel 2013-08-28 10:54:52 +12:00
Jeff Muizelaar
ecae027e49 Bug 897532. Add support for better filtering in Azure. r=bas
This fixes the quality regression on OS X.

--HG--
extra : rebase_source : f045caa95800d05098ea49e05fe90fc933f8849f
2013-07-31 14:46:25 -04:00
Matt Brubeck
c53520d691 Back out d10581fd8202 (bug 897532) on suspicion of causing intermittent pgo-only Metro crashes 2013-08-08 14:58:00 -07:00
Jeff Muizelaar
949f85802a Bug 897532. Add support for better filtering in Azure. r=bas
This fixes the quality regression on OS X.

--HG--
extra : rebase_source : afbf0c332c23933096fa97a022698dc992908c12
2013-07-31 14:46:25 -04:00
Jeff Muizelaar
06379397bc Bug 898803. Add support for different surface formats to DrawTargetCG. r=joe
This causes us to get cleartype when drawing with alpha with CG.

--HG--
extra : rebase_source : 611c5b76ce0ea926ea8e1e26501ca3d8d9a6b452
2013-07-29 15:01:29 -04:00
John Daggett
64789c29d2 Bug 898267 - support font smoothing in Azure CG backend. r=jrmuizel 2013-07-30 05:00:53 +09:00
Jeff Muizelaar
71a7916743 Bug 896129. Use CGContextDrawImage when appropriate in FillRect(). r=mattwoodrow
This fixes the element-paint-paintserversize-rounding-02.html reftest.
2013-07-19 20:39:31 -04:00
Jeff Muizelaar
bda5f61652 Bug 896290. Support drawing with antialaising in DrawTargetCG. r=mattwoodrow 2013-07-19 08:18:18 -04:00
Jeff Muizelaar
f4d062eadf Bug 895646. Use the pattern transform when drawing gradients with DrawTargetCG. r=mattwoodrow 2013-07-16 11:27:12 -04:00
Jeff Muizelaar
c9db22097b Bug 893977. Support repeating gradients in the CoreGraphics backend. r=mattwoordow
CoreGraphics doesn't support repeating gradients natively so we have to
manually repeat them. This change missing support for interpolating a
stop for the center if it doesn't line up correctly. That will come later.
2013-07-18 20:08:51 -04:00
Wes Kocher
27bac0ed90 Backout df425bca5665 (bug 893977) for breaking the build on a CLOSED TREE 2013-07-18 21:16:20 -07:00
Wes Kocher
dfff5aa2ec Backout 7c2fd5db93b2 (bug bug 895646) for breaking the build on a CLOSED TREE 2013-07-18 21:15:29 -07:00
Jeff Muizelaar
5a65f982f2 Bug 895646. Use the pattern transform when drawing gradients with DrawTargetCG. r=mattwoodrow 2013-07-16 11:27:12 -04:00
Jeff Muizelaar
1ea74c7e1a Bug 893977. Support repeating gradients in the CoreGraphics backend. r=mattwoordow
CoreGraphics doesn't support repeating gradients natively so we have to
manually repeat them. This change missing support for interpolating a
stop for the center if it doesn't line up correctly. That will come later.
2013-07-18 20:08:51 -04:00
Matt Woodrow
0debdb2a99 Bug 892966 - Make gfxQuartzNativeDrawing support Moz2D surfaces. r=jrmuizel 2013-07-12 17:19:29 -04:00
Matt Woodrow
6450d9080b Bug 892966 - Setup dashing correctly in DrawTargetCG::StrokeRect. r=jrmuizel 2013-07-12 17:19:28 -04:00
Matt Woodrow
a3629d3dbc Bug 892966 - Take a reference to the CGContext when constructing a DrawTargetCG from one. r=jrmuizel 2013-07-12 17:19:27 -04:00
Phil Ringnalda
82da68ce77 Back out 7160624804ff:69062da26093 (bug 892966) on suspicion of mochitest-4 test_bug767779.html bustage
CLOSED TREE
2013-07-12 16:39:36 -07:00
Jeff Muizelaar
4e9a81da93 Bug 892968. Implement POINT filtering properly in DrawTargetCG. r=mattwoodrow
--HG--
extra : rebase_source : 13528e2c21f96d9c5d5dba6f44593869033479f2
2013-07-12 10:01:58 -04:00
Matt Woodrow
fd6c011a54 Bug 892966 - Make gfxQuartzNativeDrawing support Moz2D surfaces. r=jrmuizel 2013-07-12 17:19:29 -04:00
Matt Woodrow
c1f63582a2 Bug 892966 - Implement CreateSourceSurfaceFromNativeSurface for DrawTargetCG and use it instead of copying pixel data. r=jrmuizel 2013-07-12 17:19:28 -04:00
Matt Woodrow
beabad00b7 Bug 892966 - Setup dashing correctly in DrawTargetCG::StrokeRect. r=jrmuizel 2013-07-12 17:19:28 -04:00
Matt Woodrow
3449d72a96 Bug 892966 - Take a reference to the CGContext when constructing a DrawTargetCG from one. r=jrmuizel 2013-07-12 17:19:27 -04:00
Jeff Muizelaar
a814b7f1d1 Bug 892964. Rewrite DrawTargetCG::MaskSurface to avoid using FillRect(). r=mattwoodrow
With FillRect we were setting the transform twice.

The patch looks really bad because I needed to move the implementation of
MaskSurface so that it was below the helper methods.

The actual change is:

-  FillRect(Rect(aOffset.x, aOffset.y, size.width, size.height), aSource, aDrawOptions);
-
+  if (isGradient(aSource)) {
+    // we shouldn't need to clip to an additional rectangle
+    // as the cliping to the mask should be sufficient.
+    DrawGradient(cg, aSource);
+  } else {
+    SetFillFromPattern(cg, mColorSpace, aSource);
+    CGContextFillRect(cg, CGRectMake(aOffset.x, aOffset.y, size.width, size.height));
+  }

This also avoids setting up other state like alpha and the unboundness fixer twice.

--HG--
extra : rebase_source : 762f2d94ddaff129d584aab1e1f429ddfea99277
2013-07-08 17:35:56 -04:00
Jeff Muizelaar
d4c95018cd Bug 891660. Add support for Azure on Mac with OMTC. r=mattwoodrow
This is not the best approach but it works for now.  We basically pull the cg
context from gfxASurface and wrap a DrawTarget around it. In the end we'll need
to plumb the DrawTarget through more.

--HG--
rename : dom/ipc/PTabContext.ipdlh => dom/ipc/PContent.ipdl
extra : rebase_source : 49eac0354864ae9f2e7434b8b1efacc37d69fc23
2013-07-09 21:02:41 -04:00
Jeff Muizelaar
d5a116ea3f Bug 790673. Add BorrowedCGContext. r=bas
This can be used to safely get at the underlying CGContext.
2013-07-09 18:55:02 -04:00
Jeff Muizelaar
8411163d5f Bug 886531. Fix MaskSurface implementation on CG. r=bas
The offsets were wrong.

--HG--
extra : rebase_source : 810f88c587e4fbcef377c53c13ee59a4b59cbe66
2013-06-24 17:28:21 -04:00
Jeff Muizelaar
9925eb3684 Bug 880836. Add MaskSurface() to Azure. r=bas
This gives a substantial performance improvement over the more general Mask():

Test (MaskSurface10x10):  1.93042ms +/- 0.305028
Test (MaskSurface100x100):  2.33435ms +/- 1.00807
Test (MaskSurface500x500):  28.0472ms +/- 0.820744
Test (MaskSurface1000x1000):  107.656ms +/- 6.44615
Test (Mask10x10):  13.5237ms +/- 0.0932034
Test (Mask100x100):  14.0742ms +/- 1.21005
Test (Mask500x500):  96.5596ms +/- 1.81415
Test (Mask1000x1000):  356.891ms +/- 9.30592

--HG--
extra : rebase_source : a3031305302fb4abe93aa480df35ed0936d68cd8
2013-06-12 23:57:51 -04:00
Ryan VanderMeulen
63406f756c Backed out changeset 8dcb029b9ca5 (bug 880836) for asserts.
CLOSED TREE
2013-06-18 12:08:19 -04:00
Jeff Muizelaar
f9e37e5828 Bug 880836. Add MaskSurface() to Azure. r=bas
This gives a substantial performance improvement over the more general Mask():

Test (MaskSurface10x10):  1.93042ms +/- 0.305028
Test (MaskSurface100x100):  2.33435ms +/- 1.00807
Test (MaskSurface500x500):  28.0472ms +/- 0.820744
Test (MaskSurface1000x1000):  107.656ms +/- 6.44615
Test (Mask10x10):  13.5237ms +/- 0.0932034
Test (Mask100x100):  14.0742ms +/- 1.21005
Test (Mask500x500):  96.5596ms +/- 1.81415
Test (Mask1000x1000):  356.891ms +/- 9.30592

--HG--
rename : layout/reftests/svg/text/dynamic-non-scaling-stroke-ref.svg => layout/reftests/svg/non-scaling-stroke-03-ref.svg
rename : layout/reftests/svg/text/dynamic-non-scaling-stroke.svg => layout/reftests/svg/non-scaling-stroke-03.svg
extra : rebase_source : a1218b8bc5cdcec7d4dd94561d841fb6e2a8ce5d
2013-06-12 23:57:51 -04:00
Jonathan Kew
bddd660d8e bug 866747 - stroke glyphs individually instead of making a single path for the entire text run. r=bas 2013-04-30 19:26:28 +01:00
Daniel Holbert
c2dca048b1 Bug 839384: Fix build warnings for DrawTargetCG. r=jrmuizel 2013-02-12 20:00:54 -08:00
Milan Sreckovic
0e784ed3ff Bug 818241 - Initialize mCg to nullptr. r=jmuizelaar 2013-01-29 10:22:52 -05:00
Rik Cabanier
4c61fa69ca Bug 748433: Adds support for blending to the canvas globalCompositeOperator. r=jrmuizel 2012-12-12 21:28:17 +01:00
Jeff Muizelaar
7b6c5f3e23 Bug 811919. Include the pattern transform when painting patterns in DrawTargetCG. r=benwa
This fixes a lot of azure content bugs.

--HG--
extra : rebase_source : be84084aa7753862920ddd7b04fbfb0bd0b54ded
2012-11-14 16:52:02 -08:00
Jonathan Kew
8797c7fbb0 bug 715798 pt 3 - support Color Emoji font in the gfx/2d quartz backend. r=jrmuizel 2012-10-23 10:07:14 +01:00
Joe Drew
d8748ac877 Bug 782416 - Switch from NULL to nullptr in gfx::2d. r=Bas
--HG--
extra : rebase_source : cfa9fc8ae592880e22e1f14cee42539b4f911668
2012-08-14 14:06:12 -04:00
Joe Drew
0375708f8e Back out 98d2c24ce932 for failing to build r=moron 2012-08-15 12:51:33 -04:00
Joe Drew
f072936338 Bug 782416 - Switch from NULL to nullptr in gfx::2d. r=Bas
--HG--
extra : rebase_source : 9b12a2af4c55f4dc383e8075b400e7a1fbe1ac23
2012-08-14 14:06:12 -04:00
Benoit Girard
1283cbb069 Bug 724666 - Part 2: Add CGIOSurfaceContext to azure. r=jmuizelaar 2012-07-31 11:17:43 -04:00
Nicolas Silva
ac9c907a9b Bug 775226 - Support CreateDrawTargetForData with Azure's CoreGraphics backend, r=jrmuizel 2012-07-26 14:06:23 -04:00
Jeff Muizelaar
54317a6cbc Bug 764594. Remove some unneeded calls in the Azure CG backend. r=bgirard
Some old code that was copy-n-pasted but never used.
2012-06-12 21:15:32 -07:00
Jeff Muizelaar
6ee514463a Bug 752341. Avoid using CGContextSetTextMatrix. r=bgirard
CGContextSetTextMatrix has behaviour that depends on the text
drawing mode. We want consistency so avoid CGContextSetTextMatrix.

--HG--
extra : rebase_source : c6e46252823586d947ec1dd19db7df980dee23f8
2012-05-21 10:22:11 -04:00
Gervase Markham
87620f5676 Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
Jeff Muizelaar
d2356ee6d6 Bug 743499. Handle negative sizes in CG backend. r=bas, a=akeybl
I didn't realize Sizes could be negative when originally writing this code.
2012-04-23 17:09:57 -04:00
Bas Schouten
c098f1f9b2 Bug 736134 - Part 1: Add GlyphRenderingOptions API to Azure. r=jrmuizel 2012-03-19 19:20:17 +00:00
Jeff Muizelaar
ec40979a31 Bug 731117. Bound the size of CG surfaces to match cairo. r=bas
This fixes crashes that can happen when we try to create
an image surface from a quartz surface larger than the maximum
size supported by image surfaces.

--HG--
extra : rebase_source : 6ef9c66a91068f75ddef90a3453a7360dd91fa78
2012-02-29 21:30:11 -05:00