2 $sur = new CairoImageSurface(FORMAT_ARGB32
,100, 100);
3 $con = new CairoContext($sur);
5 $s = new CairoImageSurface(FORMAT_ARGB32
,1,1);
6 $s->createFromPng("romedalen.png");
8 $con->setSourceRgb(0,0,0);
9 $con->rectangle(0,0,100,100);
12 $con->translate(10,10);
13 $con->setOperator(OPERATOR_SOURCE
);
14 $con->setSourceSurface($s,0,0);
15 $con->rectangle(0,0,90,90);
17 $sur->writeToPng("composite-integer-translate-source-php.png");