4 $width = ($pad +
$size +
$pad);
6 $sur = new CairoImageSurface(FORMAT_ARGB32
,$width,$height);
7 $con = new CairoContext($sur);
9 $con->translate($pad, $pad);
10 $con->moveTo($size/2, $size/2);
11 $con->relLineTo($size/2, 0);
12 $con->relLineTo($size/-2, $size/2);
15 $con->setOperator(OPERATOR_SOURCE
);
16 $con->setSourceRgba(1,0,0,0.5);
20 $con->arc($size/2, $size/2, $size/4, 0, 2*M_PI
);
21 $con->setOperator(OPERATOR_OVER
);
22 $con->setSourceRgba(0,1,0,0.5);
26 $sur->writeToPng("over-above-source-php.png");