The module provides an image toolkit that has 'feature parity' with core's GD toolkit: it includes the framework for integrating ImageMagick to the Image API, and the corresponding image toolkit operations (create_new, convert, crop, desaturate, resize, rotate, scale, scale_and_crop).

By default, the toolkit supports the same image formats of the GD toolkit (GIF, JPEG, PNG). However, it can be configured to manage any of the image formats that ImageMagick or GraphicsMagick binaries support (like e.g. TIFF, SVG, WEBP, BMP, etc.), through image toolkit's configuration admin UI.

Image effects (Automatic Orientation based on Exif, Strip Metadata) and image toolkit operations (auto_orient, sharpen, strip, watermark) that were part of the advanced module in the Drupal 7 version, have been ported to the Image Effects module.

Development branches

8.x-1.x

ImageMagick 8.x-1.0 is in alpha stage. The only issue blocking a stable release is #2620930: Remove the Todo2311679 class.

Issues to solve before stable release:

8.x-2.x

This version integrates with the File Metadata Manager module, providing the the opportunity to cache results of the image file parsing and improve performance (#2749283: Enable caching of ::parseFile results to reduce file I/O and shell calls).
It requires a Composer based build workflow.

Changes from Drupal 7 version:

  1. the former 'ops' array of command line arguments has been renamed and made protected in the toolkit. Toolkit methods have been introduced to manage the arguments.
  2. there is no longer a separate 'imagemagick_advanced' module. Part of it is incorporated in the main module, additional non-core operations and effects will be contributed to a separate module.
  3. implements automated tests based on GDToolkitTest - they can run locally but not on the automated testing infrastructure, since bots do not have ImageMagick executables installed.
  4. provides an implementation for #2064223: image_imagemagick_get_info() should use Imagemagick Identify command
  5. provides an implementation for #1551262: Rotate should alter dimensions
  6. in the rotate operation, a +repage operation is added, otherwise further operations like e.g. crop would not work properly because of changed image geometry
  7. implements the solution proposed in #1502924: escapeshellarg() has problems with non-ASCII filenames to remediate that escapeshellarg() drops non-ascii characters (for filenames, but also if you want to use 'label:' Imagemagick commands).
  8. using the identify command to parse image file, the EXIF orientation tag from JPEG images is retrieved and can be used by autorotation operations.
  9. the hooks have been changed - now we have alters for
    • pre-parse: before the image file is parsed, the modules can change the location of the source image file
    • arguments: before the convert operation is invoked, all arguments can be changed
    • post-save: after the image file has been converted to a destination path, the modules can change its location
  10. provides a default implementation to support processing image files stored in remote file systems, which works by copying remote files from/to a temporary local path. Alternative modules can override the default by implementing the hooks stated above and setting the local path to files, ensuring that their hook implementations are executed before ImageMagick's ones.

Changes from version 8.x-1.x to 8.x-2.x:

The signatures of the hooks provided by the module have been changed. The method names that can be usually called within the hook implementations are the same, but arguments are stored now in a value object of its own rather than in the toolkit class.

FROM:

function hook_imagemagick_pre_parse_file_alter(\Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit $toolkit)
function hook_imagemagick_post_save_alter(\Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit $toolkit)
function hook_imagemagick_arguments_alter(\Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit $toolkit, $command)

TO:

function hook_imagemagick_pre_parse_file_alter(\Drupal\imagemagick\ImagemagickExecArguments $arguments)
function hook_imagemagick_post_save_alter(\Drupal\imagemagick\ImagemagickExecArguments $arguments)
function hook_imagemagick_arguments_alter(\Drupal\imagemagick\ImagemagickExecArguments $arguments, $command)

Comments

mondrake created an issue. See original summary.

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

mondrake’s picture

mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Related issues: +#2698933: Require Drupal 8.1
mondrake’s picture

mondrake’s picture

mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes

Added info about the 8.x-2.x branch

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Issue summary: View changes
mondrake’s picture

Status: Active » Fixed

Released stable 8.x-2.0. Closing this one now.

If anyone interested, porting #2620930: Remove the Todo2311679 class is the blocker for a full 8.x-1.0 release.

mondrake’s picture

Issue summary: View changes

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.