You are here

function imagecache_canvasactions_image_effect_info in ImageCache Actions 7

Same name and namespace in other branches
  1. 8 canvasactions/imagecache_canvasactions.module \imagecache_canvasactions_image_effect_info()

Implements hook_image_effect_info().

Defines information about the supported effects.

File

canvasactions/imagecache_canvasactions.module, line 56

Code

function imagecache_canvasactions_image_effect_info() {
  $effects = array();
  $effects['canvasactions_definecanvas'] = array(
    'label' => t('Define canvas'),
    'help' => t('Define the size of the working canvas and background color, this controls the dimensions of the output image.'),
    'effect callback' => 'canvasactions_definecanvas_effect',
    'dimensions callback' => 'canvasactions_definecanvas_dimensions',
    'form callback' => 'canvasactions_definecanvas_form',
    'summary theme' => 'canvasactions_definecanvas_summary',
  );
  $effects['canvasactions_imagemask'] = array(
    'label' => t('Image mask'),
    'help' => t(' Choose the file image you wish to use as a mask, and apply it to the canvas.'),
    'dimensions passthrough' => TRUE,
    'effect callback' => 'canvasactions_imagemask_effect',
    'form callback' => 'canvasactions_imagemask_form',
    'summary theme' => 'canvasactions_imagemask_summary',
  );
  $effects['canvasactions_file2canvas'] = array(
    'label' => t('Overlay (watermark)'),
    'help' => t('Choose the file image you wish to use as an overlay, and position it in a layer on top of the canvas.'),
    'dimensions passthrough' => TRUE,
    'effect callback' => 'canvasactions_file2canvas_effect',
    'form callback' => 'canvasactions_file2canvas_form',
    'summary theme' => 'canvasactions_file2canvas_summary',
  );
  $effects['canvasactions_canvas2file'] = array(
    'label' => t('Underlay (background)'),
    'help' => t('Choose the file image you wish to use as an background, and position the processed image on it.'),
    'effect callback' => 'canvasactions_canvas2file_effect',
    'dimensions callback' => 'canvasactions_canvas2file_dimensions',
    'form callback' => 'canvasactions_canvas2file_form',
    'summary theme' => 'canvasactions_canvas2file_summary',
  );
  $effects['canvasactions_source2canvas'] = array(
    'label' => t('Overlay: source image to canvas'),
    'help' => t('Places the source image onto the canvas for compositing.'),
    'dimensions passthrough' => TRUE,
    'effect callback' => 'canvasactions_source2canvas_effect',
    'form callback' => 'canvasactions_source2canvas_form',
    'summary theme' => 'canvasactions_source2canvas_summary',
  );
  $effects['canvasactions_roundedcorners'] = array(
    'label' => t('Rounded Corners'),
    'help' => t('This is true cropping, not overlays, so the result <em>can</em> be transparent.'),
    'dimensions passthrough' => TRUE,
    'effect callback' => 'canvasactions_roundedcorners_effect',
    'form callback' => 'canvasactions_roundedcorners_form',
    'summary theme' => 'canvasactions_roundedcorners_summary',
  );
  $effects['canvasactions_aspect'] = array(
    'label' => t('Aspect switcher'),
    'help' => t('Use different effects depending on whether the image is landscape of portrait shaped. This re-uses other preset definitions, and just chooses between them based on the rule.'),
    'effect callback' => 'canvasactions_aspect_effect',
    'dimensions callback' => 'canvasactions_aspect_dimensions',
    'form callback' => 'canvasactions_aspect_form',
    'summary theme' => 'canvasactions_aspect_summary',
  );
  $effects['canvasactions_resizepercent'] = array(
    'label' => t('Resize (percent)'),
    'help' => t('Resize the image based on percent. If only a single dimension is specified, the other dimension will be calculated.'),
    'effect callback' => 'canvasactions_resizepercent_effect',
    'dimensions callback' => 'canvasactions_resizepercent_dimensions',
    'form callback' => 'canvasactions_resizepercent_form',
    'summary theme' => 'canvasactions_resizepercent_summary',
  );
  $effects['canvasactions_blur'] = array(
    'label' => t('Blur'),
    'help' => t('Make the image become unclear.'),
    'effect callback' => 'canvasactions_blur_effect',
    'dimensions passthrough' => TRUE,
    'form callback' => 'canvasactions_blur_form',
    'summary theme' => 'canvasactions_blur_summary',
  );
  $effects['canvasactions_interlace'] = array(
    'label' => t('Interlace / Progressive'),
    'help' => t('Create interlaced PNG/GIF or progressive JPG.'),
    'effect callback' => 'canvasactions_interlace_effect',
    'dimensions passthrough' => TRUE,
    'form callback' => 'canvasactions_interlace_form',
  );
  $effects['canvasactions_perspective'] = array(
    'label' => t('Perspective transform'),
    'help' => t('Adds a perspective transformation to the image.'),
    'effect callback' => 'canvasactions_perspective_effect',
    'dimensions passthrough' => TRUE,
    'form callback' => 'canvasactions_perspective_form',
    'summary theme' => 'canvasactions_perspective_summary',
  );
  return $effects;
}