Commit graph

72 commits

Author SHA1 Message Date
Ravi Shankar
889eec364b sorted the extern crate, mod & use declarations 2015-09-24 02:12:45 +05:30
Brandon Fairchild
de3547e401 Fix reported test-tidy errors for unmerged import blocks
This merges import blocks that were reported by tidy as unmerged.
2015-09-19 12:50:14 -04:00
Mathieu Rheaume
7320433cca Remove 'get_*' on getters as per RFC 0344 on various components 2015-09-12 20:14:01 -04:00
Johann Tuffe
ec07178b6f sort all uses 2015-08-20 20:47:12 +08:00
João Oliveira
9c11781880 replace .len() == 0 with is_empty()
closes #7198
2015-08-14 04:00:33 +01:00
bors-servo
6a8bc85284 Auto merge of #7092 - dzbarsky:putimagedata, r=jdm
Clean up and fix PutImageData



<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7092)
<!-- Reviewable:end -->
2015-08-09 07:00:56 -06:00
David Zbarsky
2f47bdff4b Fix getImageData with sizes < 1 pixel 2015-08-08 15:43:22 -04:00
David Zbarsky
05c78fbd48 Inline write_pixels 2015-08-08 15:35:16 -04:00
David Zbarsky
51938d579f Switch PutImageData to using CopySurface 2015-08-08 15:35:08 -04:00
David Zbarsky
9a88348978 Clean up dirty rect computation 2015-08-08 05:00:37 -04:00
David Zbarsky
7bcb911cea Inline dirty rect computation 2015-08-08 04:55:23 -04:00
David Zbarsky
48c24f8492 Pass a Rect instead of an Option<Rect> to PutImageData 2015-08-08 04:50:55 -04:00
David Zbarsky
1d02239804 Respect the composition op when drawing images 2015-08-05 20:38:48 -04:00
David Zbarsky
9fbe33b6f2 Implement strokeRect with zero-width or zero-height rects 2015-08-04 17:44:18 -04:00
Patrick Walton
bb99b2f3c8 script: Make most of 2D canvas and WebGL run over IPC.
To actually make the multiprocess communication work, we'll need to
reroute the task creation to the pipeline or the compositor. But this
works as a first step.
2015-07-25 00:50:12 -07:00
Patrick Walton
626974994a canvas: Move to shared memory for images and canvas backing stores.
The idea here is to land this before making images and canvas IPC-safe,
because this will shake out bugs relating to the shared memory. There
are currently test timeouts that are preventing multiprocess images and
canvas from landing, and I believe those are due to the inefficiency of
sending large amounts of data in the unoptimized builds we test with. By
moving to shared memory, this should drastically reduce the number of
copies and `serde` serialization.

Under the hood, this uses Mach OOL messages on Mac and temporary
memory-mapped files on Linux.
2015-07-24 16:14:24 -07:00
Martin Robinson
efdf2cd601 Update to latest rust-layers, azure, and skia
GLRasterizationContext is now responsible for doing GPU rasterization.
It can coexist with its target NativeSurface, so we don't have to
continually recreate NativeSurfaces when doing GPU rasterization.
2015-07-14 17:48:50 -07:00
ecoal95
8cbfb3482c Use euclid from crates.io 2015-06-19 00:04:24 +02:00
Hyowon Kim
2e230bdb93 Implement fill and stroke functions for all pattern types and check the zero size gradient. 2015-06-17 09:46:38 +09:00
Hyowon Kim
465cea8db5 Implement drawing shadows in canvas. 2015-06-16 08:57:00 +09:00
Corey Farwell
5c408d2be9 rust-geom API changes
https://github.com/servo/rust-geom/pull/81
2015-06-13 12:28:21 -07:00
Hyowon Kim
00240e5550 Implementation of pattern fill style for canvas. 2015-06-13 14:35:13 +09:00
Mátyás Mustoha
3ae64fe739 Remove gfx_traits from the dependencies of [script]. 2015-06-12 12:59:46 +02:00
Hyowon Kim
473afdb196 Add attributes for canvas shadows. 2015-06-12 09:40:00 +09:00
Mátyás Mustoha
f4c0bd3b80 Turn off default antialiasing for most DrawOptions. 2015-05-28 18:42:16 +02:00
Mátyás Mustoha
322fd5ad9d Add disable-canvas-aa option to test runner. 2015-05-28 11:10:58 +02:00
Mátyás Mustoha
adef44183d Enable antialiasing for the canvas. 2015-05-28 11:10:57 +02:00
Corey Farwell
8e3f4bba85 Reduce max line length from 150 to 120 characters
Part of https://github.com/servo/servo/issues/6041
2015-05-24 00:01:49 -04:00
ecoal95
3350522306 Layerize canvas
Note that this keeps using readback right now, `NativeSurface` painting
will be implemented soon.

Also see https://github.com/servo/servo/issues/6142
2015-05-20 19:10:50 +02:00
Simon Sapin
ef8edd4e87 Upgrade to rustc 551a74dddd84cf01440ee84148ebd18bc68bd7c8. 2015-05-05 10:07:34 -04:00
Ms2ger
024323004d Remove remaining as_slice / as_mut_slice calls. 2015-04-28 23:31:11 +02:00
Ms2ger
9185c3de79 Remove as_mut_slice() calls. 2015-04-26 11:09:03 +02:00
Mátyás Mustoha
a8343a0750 Canvas: implement global composition and blending. 2015-04-22 20:54:27 +02:00
Mátyás Mustoha
6fd6eefb35 Canvas: add clipping path support. 2015-04-22 16:25:02 +02:00
Mátyás Mustoha
5287cb7fba Canvas: implement rectangle drawing. 2015-04-21 15:21:30 +02:00
Diego Marcos
c82485874d Kicks off a WebGL implementation 2015-04-20 14:29:39 -07:00
Mátyás Mustoha
5b8416a2b6 Canvas: implement context state save/restore. 2015-04-19 21:12:13 +02:00
Corey Farwell
8b08c6f43f Don't link to specific WHATWG multipage page
"Links to the multipage version of the specification are unfortunately
likely to break over time."
-- https://html.spec.whatwg.org/multipage/asefij.html

This commit removes all references to the specific pages when viewing
WHATWG using multipage mode. I went through all these links and they
redirect fine.

Regex used to generate this commit:

`s_whatwg.org/multipage/.*#_whatwg.org/multipage/#_g`
2015-04-16 22:39:25 -04:00
Mátyás Mustoha
ccfff159e7 Canvas: added lineCap and lineJoin support. 2015-04-14 18:26:41 +02:00
Mátyás Mustoha
93fa9e607a Canvas: added miterLimit support. 2015-04-09 13:00:05 +02:00
Mátyás Mustoha
5c560397eb Canvas: added support for the globalAlpha attribute. 2015-04-08 11:49:22 +02:00
bors-servo
f57b487e4d Auto merge of #5562 - mmatyas:canvas_linewidth, r=jdm
Rebase of #5488
2015-04-08 00:56:37 -05:00
Diego Marcos
88954e3e18 Implements drawImage for html image as ImageSource 2015-04-07 11:02:50 -07:00
Mátyás Mustoha
6da2ce9b1b Canvas: added lineWidth support. 2015-04-07 16:10:29 +02:00
Mátyás Mustoha
56303e21cc Canvas: added arcTo() support. 2015-04-01 21:20:05 +02:00
bors-servo
f29ea4e4ef auto merge of #5302 : mmatyas/servo/canvas_stroke, r=jdm
This is the servo side patch of servo/rust-azure#149.
2015-03-25 07:54:50 -06:00
Mátyás Mustoha
698b88f71d Canvas: added stroke() support. 2015-03-25 12:52:05 +01:00
Ms2ger
6113dd42b1 Pass a slice to write_pixels. 2015-03-25 09:49:15 +01:00
Ms2ger
cb46a5788d Stop using the deprecated range function in canvas_paint_task. 2015-03-25 09:48:59 +01:00
Ms2ger
86ce20dca3 Fix indentation in canvas_paint_task. 2015-03-25 09:48:32 +01:00