private function getImagineImplementation()
{
foreach ($this->magicks as $name) {
$class = 'Imagine\\' . $name . '\\Imagine';
// Will throw an exception if the PHP implementation is not available
try {
new $class();
} catch (RuntimeException $e) {
continue;
}
return $class;
}
return 'Imagine\\Gd\\Imagine';
// see #616
}