View file vendor/intervention/image/src/Intervention/Image/Gd/Commands/InvertCommand.php

File size: 369B
<?php

namespace Intervention\Image\Gd\Commands;

class InvertCommand extends \Intervention\Image\Commands\AbstractCommand
{
    /**
     * Inverts colors of an image
     *
     * @param  \Intervention\Image\Image $image
     * @return boolean
     */
    public function execute($image)
    {
        return imagefilter($image->getCore(), IMG_FILTER_NEGATE);
    }
}