Commit 2fa97ce1 authored by Nicolas Widart's avatar Nicolas Widart

Adding invert implementation

parent 905e0f66
...@@ -31,12 +31,13 @@ return [ ...@@ -31,12 +31,13 @@ return [
// 'gamma' => [ // 'gamma' => [
// 'correction' => '1.8' // 'correction' => '1.8'
// ], // ],
// 'greyscale' => [], // 'greyscale' => [],
'heighten' => [ // 'heighten' => [
'height' => 500, // 'height' => 500,
'callback' => function($constraint) { // 'callback' => function($constraint) {
$constraint->upsize(); // $constraint->upsize();
} // }
] // ]
'invert' => [],
] ]
]; ];
<?php namespace Modules\Media\Image\Intervention\Manipulations;
use Modules\Media\Image\ImageHandlerInterface;
class Invert implements ImageHandlerInterface
{
/**
* Handle the image manipulation request
* @param \Intervention\Image\Image $image
* @param array $options
* @return \Intervention\Image\Image
*/
public function handle($image, $options)
{
return $image->invert();
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment