Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
12 lines (9 sloc) 331 Bytes
<?php
$sur = new CairoImageSurface(CairoFormat::ARGB32, 2, 2);
$con = new CairoContext($sur);
$s = new CairoImageSurface(CairoFormat::ARGB32, 2, 2);
$s->createFromPng(dirname(__FILE__) ."/create-from-png-ref.png");
$con->setSourceSurface($s);
$con->paint();
$sur->writeToPng(dirname(__FILE__) . "/create-from-png-php.png");
?>