Rand Stats

MagickWand

zef:knarkhov

MagickWand

This module provides a Raku object-oriented NativeCall-based API for ImageMagick's MagickWand C API.

Example

use v6;
use MagickWand;

# A new magic wand
my $wand = MagickWand.new;

# Read an image
$wand.read("examples/images/aero1.jpg");

# Lighten dark areas
$wand.auto-gamma;

# And then write a new image
$wand.write("output.png");

# And cleanup on exit
LEAVE {
    $wand.cleanup if $wand.defined;
}

For more examples, please see the examples folder. For examples of available image effects, please click here.

Prerequisites

Please follow the instructions below based on your platform:

Linux

To install ImageMagick libraries, please check out this guide: https://gitlab.com/pheix/dcms-raku/-/wikis/imagemagick-install

Installation

Install this module using zef:

zef install MagickWand

Handling PDF files

To process PDF files, please remember to install Ghostscript from here.

Testing

To run tests:

prove6 -Ilib -v ./t/

Authors

  1. Konstantin Narkhov, https://narkhov.pro/contact-information.html
  2. Ahmad M. Zawawi, azawawi on #perl6, https://github.com/azawawi/

License

MIT License