5 <canvas id=
"mycanvas" width=
"600" height=
"480"></canvas>
8 testRunner
.dumpAsTextWithPixelResults();
10 var canvas
= document
.getElementById('mycanvas');
11 var ctx
= canvas
.getContext('2d');
13 ctx
.fillStyle
= 'rgba(0, 0, 0, 0.5)';
17 -123.7, -2.3, -2, -1, -0.3, -0.000001, 0, 0.000001, 0.3, 0.7,
18 1, 1.3, 1.5, 1.7, 1.99999, 2, 2.00001, 2.3, 4.3, 3934723942837.3
20 for (var i
= 0; i
< sweepAngles
.length
; i
++) {
21 sweepAngles
[i
] = sweepAngles
[i
] * Math
.PI
;
27 for (var i
= 0; i
< startAngles
.length
; i
++) {
28 startAngles
[i
] = startAngles
[i
] * Math
.PI
;
36 var anticlockwise
= false;
39 for (var r
= 0; r
< rotations
.length
; r
++) {
41 for (var i
= 0; i
< startAngles
.length
* 2; i
++) {
42 if (i
== startAngles
.length
) {
46 startAngle
= startAngles
[i
% startAngles
.length
] * sign
;
48 for (var j
= 0; j
< sweepAngles
.length
; j
++) {
52 ctx
.ellipse(18, 15, 8, 12, rotations
[r
], startAngle
, startAngle
+ (sweepAngles
[j
] * sign
), anticlockwise
);
59 ctx
.translate(0, height
);
62 ctx
.translate(0, height
* startAngles
.length
* 2);