ABCDEFGHIJKLMNOPQRSTUVWXYZ

conjure

conjure(1)                                                          conjure(1)



NAME
       conjure - process a Magick Scripting Language (MSL) script

       WARNING:  Conjure  and MSL are in very early development and the syntax
       is subject to change!


SYNOPSIS
       conjure [ options ] script.msl [ [ options ] script.msl ]


DESCRIPTION
       The Magick scripting language (MSL) will primarily benefit  those  that
       want  to  accomplish  custom  image processing tasks but do not wish to
       program, or those that do not have access to a Perl  interpreter  or  a
       compiler.   The  interpreter  is  called conjure and here is an example
       script:


           <?xml version="1.0" encoding="UTF-8"?>
           <image size="400x400" >
             <read filename="image.gif" />
             <get width="base-width" height="base-height" />
             <resize geometry="%[dimensions]" />
             <get width="width" height="height" />
             <print output=
               "Image sized from %[base-width]x%[base-height]
                to %[width]x%[height].\n" />
             <write filename="image.png" />
           </image>

       invoked with


           conjure -dimensions 400x400 incantation.msl

       All operations will closely follow the key/value pairs defined in Perl-
       Magick, unless otherwise noted.


       Conjure is in the early stages of development as of April 2002.


       This  early  announcement  is  to allow ImageMagick users to contribute
       ideas early in the process so when the scripting language  is  released
       it  will  be  useful/stable from the get-go!  If you want to contribute
       suggestions about the Magick scripting language  (MSL),  post  them  to
       magick-developers@imagemagick.org.


OPTIONS
       Options  are processed in command line order. Any option you specify on
       the command line remains in effect until it is  explicitly  changed  by
       specifying  the  option  again  with  a  different  effect, or if it is
       changed by a statement in the scripting language.


       You can define your own keyword/value pairs on the command  line.   The
       script  can  then use this information when setting values by including
       %[keyword] in the string.  For example, if  you  included  "-dimensions
       400x400"  on  the  command  line, as illustrated above, then any string
       containing  "%[dimensions]"  would  have  400x400   substituted.    The
       "%[string]"  can  be  used  either  an  entire  string,  such as geome-
       try="%[dimensions]" or as a part of a string such as  filename="%[base-
       name].png".

       The keyword can be any string except for the following reserved strings
       (in any upper, lower, or mixed case variant): debug, help, and verbose,
       whose usage is described below.

       The  value  can be any string.  If either the keyword or the value con-
       tains white space or any symbols that have  special  meanings  to  your
       shell  such  as "#", "|", or "%", enclose the string in quotation marks
       or use "\" to escape the white space and special symbols.

       Keywords and values are case dependent.  "Key", "key", and "KEY"  would
       be three different keywords.


       For a more detailed description of each option, see ImageMagick(1).


       -debug enable debug printout

       -help  print usage instructions

       -verbose
              print detailed information about the image

MAGICK SCRIPTING LANGUAGE
       The  Magick  Scripting  Language  (MSL) presently defines the following
       elements and their attributes:

               <image>

                    .in 20 Define a new image object.  </image>  destroys  it.
                    Because of this, if you wish to reference multiple "subim-
                    ages" (aka pages or layers), you can embed one image  ele-
                    ment inside of another. For example:



                        <image>
                        <read filename="input.png" />
                        <get width="base-width" height="base-height" />
                        <image height="base-height" width="base-width">
                        <image />
                        <write filename="output.mng" />
                        </image>



                        <image size="400x400" />

               <group>

                    .in  20  Define a new group of image objects.  By default,
                    images are only valid for the life  of  their  <image>ele-
                    ment.



                        <image>   -- creates the image
                        .....     -- do stuff with it
                        </image>  -- dispose of the image


                    However,  in  a  group, all images in that group will stay
                    around for the life of the group:



                        <group>                           -- start a group
                            <image>                       -- create an image
                            ....                          -- do stuff
                            </image>                      -- NOOP
                            <image>                        --  create  another
                    image
                            ....                          -- do more stuff
                            </image>                      -- NOOP
                            <write filename="image.mng" />  -- output
                        </group>                           --  dispose of both
                    images

               <read>

                    .in 20 Read a new image from a disk file.



                        <read filename="image.gif" />

                    To read two images use



                        <read filename="image.gif" />
                        <read filename="image.png />

               <write>

                    .in 20 Write the image(s) to disk, either as a single mul-
                    tiple-image file or multiple ones if necessary.



                         <write filename=image.tiff" />
               <get>

                    .in 20 Get any attribute recognized by PerlMagick's GetAt-
                    tribute() and stores it as an image  attribute  for  later
                    use. Currently only width and height are supported.


                        <get width="base-width" height="base-height" />
                        <print  output="Image  size  is  %[base-width]x%[base-
                    height].\n" />

               <set>

                    .in 20  background,  bordercolor,  clip-mask,  colorspace,
                    density,  magick,  mattecolor,  opacity.  Set an attribute
                    recognized by PerlMagick's GetAttribute().
               <border>

                    .in 20
                        fill, geometry, height, width
               <blur>

                    .in 20
                        radius, sigma
               <charcoal>

                    .in 20
                        radius, sigma
               <chop>

                    .in 20
                        geometry, height, width, x, y
               <crop>

                    .in 20
                        geometry, height, width, x, y
               <despeckle>

                    .in 15 <emboss>

                    .in 20
                        radius, sigma
               <enhance>

                    .in 15 <equalize>

                    .in 15 <flip>

                    .in 15 <flop>

                    .in 15 <frame>

                    .in 20
                        fill, geometry, height, width, x, y, inner, outer
               <get>

                    .in 20
                        height, width
               <image>

                    .in 20
                        background, color, id, size
               <magnify>

                    .in 15 <minify>

                    .in 15 <normalize>

                    .in 15 <print>

                    .in 20
                        output
               <read>

                    .in 15 <resize>

                    .in 20
                        blur, filter, geometry, height, width
               <roll>

                    .in 20
                        geometry, x, y
               <rotate>

                    .in 20
                        degrees
               <sample>

                    .in 20
                        geometry, height, width
               <scale>

                    .in 20
                        geometry, height, width
               <sharpen>

                    .in 20
                        radius, sigma
               <shave>

                    .in 20
                        geometry, height, width
               <shear>

                    .in 20
                        x, y
               <solarize>

                    .in 20
                        threshold
               <spread>

                    .in 20
                        radius
               <stegano>

                    .in 20
                        image
               <stereo>

                    .in 20
                        image
               <swirl>

                    .in 20
                        degrees
               <texture>

                    .in 20
                        image
               <threshold>

                    .in 20
                        threshold
               <transparent>

                    .in 20
                        color
               <trim>



SEE ALSO
       animate(1),   display(1),   composite(1),   convert(1),    identify(1),
       import(1), mogrify(1), montage(1)


COPYRIGHT
       Copyright (C) 2002 ImageMagick Studio

       Permission is hereby granted, free of charge, to any person obtaining a
       copy of this software and associated  documentation  files  ("ImageMag-
       ick"),  to  deal  in ImageMagick without restriction, including without
       limitation the rights to use, copy, modify, merge, publish, distribute,
       sublicense, and/or sell copies of ImageMagick, and to permit persons to
       whom the ImageMagick is furnished to do so, subject  to  the  following
       conditions:

       The above copyright notice and this permission notice shall be included
       in all copies or substantial portions of ImageMagick.

       The software is provided "as is", without warranty of any kind, express
       or  implied,  including  but  not  limited  to  the  warranties of mer-
       chantability, fitness for a particular purpose  and  noninfringement.In
       no  event  shall ImageMagick Studio be liable for any claim, damages or
       other liability, whether in an action of contract, tort  or  otherwise,
       arising  from,  out  of or in connection with ImageMagick or the use or
       other dealings in ImageMagick.

       Except as contained in this notice, the name of the ImageMagick  Studio
       LLC  shall not be used in advertising or otherwise to promote the sale,
       use or other dealings in ImageMagick without prior  written  authoriza-
       tion from the ImageMagick Studio.

AUTHORS
        John Cristy, ImageMagick Studio LLC,
       Glenn Randers-Pehrson, ImageMagick Studio LLC,
       Leonard Rosenthol, ImageMagick Studio LLC.




ImageMagick                Date: 2002/02/15 01:00:00                conjure(1)