You are here

function image_imagemagick_auto_orient in ImageMagick 7

Automatically adjusts the orientation of an image.

Parameters

$image: An image object. The $image->resource value will be modified by this call.

Return value

TRUE or FALSE, based on success.

File

imagemagick_advanced/imagemagick_advanced.module, line 103
Provides advanced ImageMagick effects and options.

Code

function image_imagemagick_auto_orient(stdClass $image) {
  $image->ops[] = '-auto-orient';
  return TRUE;
}