cono / perl6-magickwand

ImageMagick's MagickWand API Bindings for Perl6

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MagickWand

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

Build Status

Operating System Build Status CI Provider
Linux / Mac OS X Build Status Travis CI
Windows 7 64-bit Build status AppVeyor

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 (Debian)

  • To install ImageMagick libraries, please run:
$ sudo apt install libmagickwand-dev

MacOSX (Darwin)

  • To install ImageMagick libraries via Homebrew, please run:
$ brew update
$ brew install imagemagick
  • To install ImageMagick libraries via MacPorts, please run:
$ sudo port install ImageMagick

Windows

For 64-bit Windows, please install the 64-bit DLL installer. Otherwise, use the 32-bit version.

Also please remember to enable "Add to PATH" option.

Installation

To install it using Panda (a module management tool bundled with Rakudo Star):

$ panda update
$ panda install MagickWand

Testing

To run tests:

$ prove -ve "perl6 -Ilib"

Author

Ahmad M. Zawawi, azawawi on #perl6, https://github.com/azawawi/

License

MIT License

About

ImageMagick's MagickWand API Bindings for Perl6

License:MIT License


Languages

Language:Perl 6 100.0%