Skip to content

Instantly share code, notes, and snippets.

@ronan-gloo
Created July 19, 2012 17:06
Show Gist options
  • Save ronan-gloo/3145370 to your computer and use it in GitHub Desktop.
Save ronan-gloo/3145370 to your computer and use it in GitHub Desktop.
header('Content-type: image/jpeg');
$im = imagecreatefromjpeg('test.jpg');
imagefilter($im, IMG_FILTER_GRAYSCALE);
imagefilter($im, IMG_FILTER_CONTRAST, 255);
imagefilter($im, IMG_FILTER_NEGATE);
imagefilter($im, IMG_FILTER_COLORIZE, 55, 157, 18);
imagefilter($im, IMG_FILTER_NEGATE);
return Response::forge(imagejpeg($im));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment