=J D H C ImageMagick - Image Processing and Display Package; C
D Convert



Ú
>Contents







Ú
>Synopsis




Uconvert [ options ... ] input_fileoutput_file

*Back to Contents




Ý
>Description




IConvert converts an input file using one image format to an outputGfile with a differing image format. In addition, various types of imageHprocessing can be performed on the converted image during the conversionDprocess. Convert recognizes the following image formats:





J*AVS - AVS X image file.

Q*BIE+ - Joint Bi-level Image experts#Group file interchange format.

S*BMP+ - Microsoft Windows bitmap image file.

V*BMP24+ - Microsoft Windows 24-bit bitmapimage file.

T*CGM - Computer Graphics Metafile.

S*CMYK - Raw cyan, magenta, yellow, andblack bytes.

W*DCX+ - ZSoft IBM PC multi-page Paintbrush file.

R*DIB - Microsoft Windows bitmap image file.

N*DICOM - Medical image file.

S*EPDF - Encapsulated Portable Document Format.

Q*EPI - Adobe Encapsulated PostScriptInterchange format.

Q*EPS - Adobe Encapsulated PostScript file.

P*EPS2 - Adobe Level II EncapsulatedPostScript file.

R*EPSF - Adobe Encapsulated PostScript file.

R*EPSI - Adobe Encapsulated PostScriptInterchange format.

Q*EPT - Adobe Encapsulated PostScript*Interchange format with TIFF preview.

B*FAX+ - Group 3.

O*FIG - TransFig image format.

Z*FITS - Flexible Image Transport System.

I*FPX - FlashPix Format.

S*GIF - CompuServe graphics interchangeformat; 8-bit color.

U*GIF87 - CompuServe graphics interchange'format; 8-bit color (version 87a).

I*GRAY - Raw gray bytes.

R*GRADATION - gradual passing from onehshade to another. Specify the desired shading with the filename (e.g. gradation:red-blue).

M*GRANITE - granite texture.

S*HDF+ - Hierarchical Data Format.

<*HISTOGRAM

Q*HPGL - HP-GL plotter language.

P*HTML - Hypertext Markup Language a with client-side image map.

R*JBIG+ - Joint Bi-level Image experts#Group file interchange format.

U*JPEG - Joint Photographic Experts Group*JFIF format; compressed 24-bit color.

H*ICO - Microsoft icon.

F*LABEL - text image.

Z*MAP - colormap intensities and indices.

T*MIFF+ - Magick image file format.

Z*MNG+ - Multiple-image Network Graphics.

^*MONO - Bi-level bitmap in least-significant-byte(LSB) first order.

R*MPEG+ - Motion Picture Experts Groupfile interchange format.

9*MTV+ -

Q*M2V+ - Motion Picture Experts Group)file interchange format (version 2).

V*NETSCAPE - Netscape 216 color cube.

E*NULL - NULL image.

R*PBM+ - Portable bitmap format (blackand white).

T*PCD - Photo CD. The maximum resolutionwritten is 512x768 pixels.

S*PCDS - Photo CD. Decode with the sRGBcolor table.

O*PCL - Page Control Language.

V*PCX - ZSoft IBM PC Paintbrush file.

S*PDF+ - Portable Document Format.

R*PGM+ - Portable graymap format (gray scale).

S*PICT - Apple Macintosh QuickDraw/PICT file.

Z*PIX - Alias/Wavefront RLE image format.

T*PLASMA - plasma fractal image. SpecifyPthe base color as the filename (e.g. plasma:gray). Use fractalDto initialize to a random value (e.g. plasma:fractal).

S*PNG - Portable Network Graphics.

J*PNM+ - Portable anymap.

Y*PPM+ - Portable pixmap format (color).

O*PS+ - Adobe PostScript file.

U*PSD - Adobe PhotoShop bitmap file.

Y*PS2+ - Adobe Level II PostScript file.

M*RAD - Radiance image file.

X*RGB - Raw red, green, and blue bytes.

T*RGBA - Raw red, green, blue, and matte bytes.

T*RLA - Alias/Wavefront image file; read only.

Q*RLE - Utah Run length encoded imagefile; read only.

N*SGI+ - Irix RGB image file.

Q*SHTML - Hypertext Markup Language a with client-side image map.

I*SUN+ - SUN Rasterfile.

S*TEXT - raw text file; read only.

V*TGA+ - Truevision Targa image file.

T*TIFF+ - Tagged Image File Format.

P*TIFF24+ - 24-bit Tagged Image File Format.

T*TILE - tile image with a texture.

F*TIM - PSX TIM file.

L*TTF - TrueType font file.

K*UIL - X-Motif UIL table.

J*UYVY - Interleaved YUV.

E*VICAR - read only.

P*VID - Visual Image Directory.

P*VIFF+ - Khoros Visualization image file.

P*WIN - select image from or display#image to your computer screen.

T*X - select image from or display imageto your X server screen.

T*XC - constant image of X server color.GSpecify the image color as the filename (e.g. xc:yellow).

R*XBM - X Windows system bitmap, blackand white only.

P*XPM - X Windows system pixmap file (color).

P*XWD - X Windows system window dumpfile (color).

N*YUV+ - CCIR 601 4:1:1 file.



NSupport for some of these formats require additional programs or libraries.!README&tells where to find this software.H

Note, a format delineated with + means that if more than oneFimage is specified, it is combined into a single multi-image file. Use+adjoin3if you want a single image produced for each frame.O

Raw images are expected to have one byte per pixel unless ImageMagickGis compiled in 16-bit mode. Here, the raw data is expected to be stored>two bytes per pixel in most-significant-byte-first order.

*Back to Contents




à
>Examples 




MTo convert a MIFF image of a cockatoo to a SUN raster image, use:





4convert cockatoo.miff sun:cockatoo.ras





KTo convert a multi-page PostScript document to individual FAX pages, use:





6convert -monochrome document.ps fax:page





HTo convert a TIFF image to a PostScript A4 page with the image in%the lower left-hand corner, use:





9convert -page A4+0+0 image.tiff document.ps




ITo convert a raw Gray image with a 128 byte header to a portable graymap, use:





<convert -size 768x512"+1"28 gray:raw image.pgm






6To convert a Photo CD image to a TIFF image, use:




<convert -size 1536x1024 img0009.pcd image.tiff





/convert img0009.pcd[4] image.tiff





ETo create a visual image directory of all your JPEG images, use:





0convert 'vid:*.jpg' directory.miff





KTo annotate an image with blue text using font 12x24 at position (100,100), use:





Lconvert -font helvetica -pen blue -draw "text 100,100 Cockatoo" bird.jpgbird.miff





@To tile a 640x480 image with a JPEG texture with bumps use:





<convert -size 640x480 tile:bumps.jpg tiled.png





NTo surround an icon with an ornamental border to use with Mosaic(1), use:





Fconvert -mattecolor #697B8F -frame 6x6 bird.jpg icon.png





ATo create a GIF animation from a DNA molecule sequence, use:





-convert -delay 20 dna.* dna.png


*Back to Contents




Ù
>Options




FOptions are processed in command line order. Any option you specify onOthe command line remains in effect until it is explicitly changed by specifying.the option again with a different effect.


 

Ù
>-adjoin

0join images into a single multi-image file.
E

By default, all images of an image sequence are stored in the sameJfile. However, some formats (e.g. JPEG) do not support more than one imageKand are saved to separate files. Use +adjoin to force this behavior.





Ü
>-antialias

remove pixel aliasing.





Ù
>-append

append a set of images.




FAll the input images must have the same width or height. Images of theKsame width are stacked top-to-bottom. Images of the same height are stackedQleft-to-right. Use +append to stack rectangular images left-to-right.





Ú
>-average

average a set of images.





¹
>-blur+factor

Gblur an image while resizing. Specify factor as the percent enhancement(0.0 - 99.9%).
7

To blur without resizing, use -geometry 100%.





»
>-borderA<width>x<height>

Fsurround the image with a border of color. See X(1) for details&about the geometry specification.





À
>-bordercolor*color

the border color.





¸
>-box*color

Jset the color of the annotation bounding box. See -draw for further details.


º
>-cache.threshold
<
megabytes of memory available to the pixel cache.


B

Image pixels are stored in memory until 80 megabytes of memoryDhave been consumed. Subsequent pixel operations are cached on disk.KOperations to memory are significantly faster but if your computer does notMhave a sufficient amount of free memory you may want to adjust this threshold value.





½
>-charcoal+factor

!simulate a charcoal drawing.





Û
>-coalesce

merge a sequence of images.




?See X(1) for details about the color specification.





½
>-colorize*value

+colorize the image with the pen color.




JSpecify the amount of colorization as a percentage. You can apply separateJcolorization values to the red, green, and blue channels of the image withEa colorization value list delineated with slashes (e.g. 0/0/50).





»
>-colors*value

-preferred number of colors in the image.




GThe actual number of colors in the image may be less than your request,Hbut never more. Note, this is a color reduction option. Images with lessHunique colors than specified with this option will have any duplicate orHunused colors removed. Refer to quantize formore details.
J

Note, options -dither, -colorspace, and -treedepth%affect the color reduction algorithm.





¿
>-colorspace*value

=the type of colorspace: GRAY, OHTA, RGB,Transparent,3XYZ, YCbCr, YIQ, YPbPr, YUV, or CMYK.




JColor reduction, by default, takes place in the RGB color space. EmpiricalNevidence suggests that distances in color spaces such as YUV or YIQ correspondLto perceptual color differences more closely than do distances in RGB space.HThese color spaces may give better results when color reducing an image.DRefer to quantize for more details.
K

The Transparent color space behaves uniquely in that it preserves,the matte channel of the image if it exists.G

The -colors or -monochrome option is required for thisoption to take effect.





¼
>-comment+string

&annotate an image with a comment.




GBy default, each image is commented with its file name. Use this optionIto assign a specific comment to the image. Optionally you can include theJimage filename, type, width, height, or other image attribute by embeddingspecial format characters:
    %b   file size    %d   directory    %e   filename extention    %f   filename    %h   height    %i   input filename    %l   label    %m   magick    %n   number of scenes    %o   output filename    %p   page number    %q   quantum depth    %s   scene number    %t   top of filename"    %u   unique temporary filename    %w   width    %x   x resolution    %y   y resolution    \\n   newline    \\r   carriage return
For example,(
  -comment "%m:%f %wx%h"

Gproduces an image comment of MIFF:bird.miff 512x480 for an imageFtitled bird.miff and whose width is 512 and height is 480.

FIf the first character of string is @, the image commentJis read from a file titled by the remaining characters in the string.





½
>-compress)type

Dthe type of image compression: None, BZip, Fax,Group4,DJPEG, LZW, RunlengthEncoded or Zip.




MSpecify +compress to store the binary image in an uncompressed format.EThe default is the compression type of the specified image file.





Û
>-contrast

*enhance or reduce the image contrast.




FThis option enhances the intensity differences between the lighter andGdarker elements of the image. Use -contrast to enhance the image6or +contrast to reduce the image contrast.





¹
>-cropl<width>x<height>{+-}<x offset>{+-}<y offset>{%}

Mpreferred size and location of the cropped image. See X(1) for details&about the geometry specification.

MTo specify a percentage width or height instead, append %. For exampleHto crop the image by ten percent on all sides of the image, use -crop 10%.




KUse cropping to apply image processing options to, or display, a particulararea of an image.

FOmit the x and y offset to generate one or more subimages of a uniform size.




HUse cropping to crop a particular area of an image. Use -crop 0x0Kto trim edges that are the background color. Add an x and y offset to leave3a portion of the trimmed edges with the image.





º
>-cycle+amount

'displace image colormap by amount.

RAmount defines the number of positions each colormap entry is shifted.





Þ
>-deconstruct

9break down an image sequence into constituent parts.





º
>-delayA<1/100ths of a second>

*display the next image after pausing.
C

This option is useful for regulating the animation of GIF imagesLwithin Netscape.. 1/100ths of a second must expire before the displayFof the next image. The default is no delay between each showing of the+image sequence. The maximum delay is 65535.





¼
>-densityA<width>x<height>

?vertical and horizontal resolution in pixels of the image.




HThis option specifies an image density when decoding a PostScriptLor Portable Document page. The default is 72 dots per inch in the horizontalNand vertical direction. This option is used in concert with -page.





º
>-depth*value

Ndepth of the image. This is the number of bits in a pixel. The only acceptablevalues are 8 or 16.





Ü
>-despeckle

)reduce the speckles within an image.





¼
>-display:host:display[.screen]

Gspecifies the X server to contact. This option is used with convert forAobtaining image or font from this X server. see X(1).





¼
>-dispose+method

GIF disposal method.




Here are the valid methods:
<
  0     No disposal specified.c  1     Do not dispose between frames.      S  2     Overwrite frame with background color from header.E  3     Overwrite with previous frame.





Ù
>-dither

8apply Floyd/Steinberg error diffusion to the image.




LThe basic strategy of dithering is to trade intensity resolution for spatialFresolution by averaging the intensities of several neighboring pixels.FImages which suffer from severe contouring when reducing colors can beimproved with this option.




KThe -colors or -monochrome option is required for this optionto take effect.




NUse +dither to render Postscript without text or graphic aliasing.





¹
>-draw+string

;annotate an image with one or more graphic primitives.




IUse this option to annotate an image with one or more graphic primitives.The primitives include
#
     point     line"     rectangle&     fillRectangle     circle#     fillCircle      ellipse$     fillEllipse      polygon$     fillPolygon     color     matte     text$     image




GPoint, line, color, matte, text, and imageFeach require a single coordinate. Line requires a start and endHcoordinate, while rectangle expects an upper left and lower rightIcoordinate. Circle has a center coordinate and a coordinate on theHouter edge. Use Ellipse to draw a partial ellipse centered at theLgiven point, specified width and height, and start and end of arc in degreesG(e.g. 100,100 100,150 0,360). Finally, polygon requires three orLmore coordinates defining its boundaries. Coordinates are integers separatedIby an optional comma. For example, to define a circle centered at 100,100!that extends to 150,150 use:
B
     -draw 'circle 100,100 150,150'




LUse color to change the color of a pixel. Follow the pixel coordinatewith a method:


#

     point      replace"     floodfill%     filltoborder$     reset




CConsider the target pixel as that specified by your coordinate. The pointHmethod recolors the target pixel. The replace method recolors any1pixel that matches the color of the target pixel.Floodfill recolorsGany pixel that matches the color of the target pixel and is a neighbor,Gwhereas filltoborder recolors any neighbor pixel that is not the=border color. Finally, reset recolors all pixels.




KUse matte to the change the pixel matte value to transparent. FollowFthe pixel coordinate with a method (see the color primitive forJa description of methods). The point method changes the matte valueFof the target pixel. The replace method changes the matte valueIof any pixel that matches the color of the target pixel. FloodfillIchanges the matte value of any pixel that matches the color of the target pixel and is a neighbor, whereas%filltoborder changes the matteOvalue of any neighbor pixel that is not the border color (-bordercolor).@Finally reset changes the matte value of all pixels.




KUse text to annotate an image with text. Follow the text coordinatesFwith a string. If the string has embedded spaces, enclose it in doubleKquotes. Optionally you can include the image filename, type, width, height,Sor other image attribute by embedding special format character. See -commentfor details.




For example,
F
     -draw 'text 100,100 "%m:%f %wx%h"'
Lannotates the image with MIFF:bird.miff 512x480 for an image titledHbird.miff and whose width is 512 and height is 480. To generateFa Unicode character (TrueType fonts only), embed the code as an+escaped hex string (e.g. \0x30a3).H

Use image to composite an image with another image. Follow the0image coordinates with the filename of an image.



JIf the first character of string is @, the text is read from=a file titled by the remaining characters in the string.
E

You can set the primitive color, font color, and font bounding box color with@-pen, -font, and -box respectively. OptionsNare processed in command line order so be sure to use -penbeforethe -draw option.





¹
>-edge+factor

Ndetect edges within an image. Specify factor as the percent enhancement(0.0 - 99.9%).





Ú
>-enhance

5apply a digital filter to enhance a noisy image.





Û
>-equalize

1perform histogram equalization to the image.





»
>-filter)type

4use this type of filter when resizing an image.


@

Use this option to affect the resizing operation of an image(see--geometry). Choose from these filters:#
     Point     Box!     Triangle      Hermite      Hanning      Hamming!     Blackman!     Gaussian"     Quadratic     Cubic     Catrom!     Mitchell      Lanczos     Bessel#     Sinc




*The default filter is Lanczos.





×
>-flip

Screate a "mirror image" by reflecting the scanlines in the vertical direction.





×
>-flop

Kcreate a "mirror image" by reflecting the image scanlines in the horizontaldirection.





¹
>-font)name

7use this font when annotating the image with text.




IIf the font is a fully qualified X server font name, the font is obtainedfrom an X server (e.g.;-*-helvetica-medium-r-*-*-12-*-*-*-*-*-iso8859-*).GTo use a TrueType font, precede the TrueType filename with a @(e.g.@@times.ttf). Otherwise, specify a Postscript font (e.g.helvetica).





º
>-framem<width>x<height+<outer bevel width>+<inner bevel width

1surround the image with an ornamental border. SeeX(1) for details&about the geometry specification.




-The color of the border is specified with the-mattecolor commandline option.





¹
>-fuzz-distance

6colors within this distance are considered equal.




FA number of algorithms search for a target color. By default the colorKmust be exact. Use this option to match colors that are close to the targetFcolor in RGB space. For example, if you want to automatically trim theFedges of an image with -crop 0x0 but the image was scanned. TheMtarget background color may differ by a small amount. This option can accountfor these differences.





º
>-gamma*value

level of gamma correction.




OThe same color image displayed on two different workstations may look differentIdue to differences in the display monitor. Use gamma correction to adjustFfor this color difference. Reasonable values extend from 0.8 to2.3.




HYou can apply separate gamma values to the red, green, and blue channelsjof the image with a gamma value list delineated with slashes (i.e. 1.7,2.3,1.2).




IUse +gamma to set the image gamma level without actually adjustingHthe image pixels. This option is useful if the image is of a known gamma9but not set as an image attribute (e.g. PNG images).





½
>-geometry{<width>x<height>{+-}<x offset>{+-}<y offset>{%}{!}{<}{>}

4preferred size and location of the Image window. SeeX(1) for detailsJabout the geometry specification. By default, the window size is the image>size and the location is chosen by you when it is mapped.




GBy default, the width and height are maximum values. That is, the imageMis expanded or contracted to fit the width and height value while maintainingMthe aspect ratio of the image. Append an exclamation point to the geometryIto force the image size to exactly the size you specify. For example,Gif you specify 640x480! the image width is set to 640 pixels andIheight to 480. If only one factor is specified, both the width and heightassume the value.




ITo specify a percentage width or height instead, append %. The image sizeKis multiplied by the width and height percentages to obtain the final imageFdimensions. To increase the size of an image, use a value greater thanH100 (e.g. 125%). To decrease an image's size, use a percentage less than 100.
G

Use > to change the dimensions of the image only ifJits size exceeds the geometry specification. < resizes the imageFonly if its dimensions is less than the geometry specification.MFor example, if you specify 640x480> and the image size is 512x512,Fthe image size does not change. However, if the image is 1024x1024, itis resized to 640x480.G

Use < to change the dimensions of the image only ifJits size exceeds the geometry specification. > resizes the imageFonly if its dimensions is less than the geometry specification.MFor example, if you specify 640x480> and the image size is 512x512,Fthe image size does not change. However, if the image is 1024x1024, itis resized to 640x480.:

There are 72 pixels per inch in PostScript coordinates.





¼
>-gravity)type

Idirection text gravitates to when annotating the image: NorthWest, North,HNorthEast, West, Center, East, SouthWest, South, SouthEast. See X(1) for-details about the gravity specification.




MThe direction you choose specifies where to position the text when annotatingKthe image. For example Center gravity forces the text to be centeredIwithin the image. By default, the image gravity is NorthWest.





¼
>-implode+factor

Kimplode image pixels about the center. Specify factor as the percent5implosion (0 - 99.9%) or explosion (-99.9 - 0%).





¾
>-interlace)type

Gthe type of interlacing scheme: None, Line, Plane,5or Partition. The default is None.




KThis option is used to specify the type of interlacing scheme for raw imageLformats such as RGB or YUV. None means do not interlacef(RGBRGBRGBRGBRGBRGB...), Line uses scanline interlacing (RRR...GGG...BBB...RRR...GGG...BBB...),Fand Plane uses plane interlacing (RRRRRR...GGGGGG...BBBBBB...).GPartition is like plane except the different planes are saved to;individual files (e.g. image.R, image.G, and image.B).




FUse Line, or Plane to create an interlaced GIF or#progressive JPEG image.





º
>-label)name

assign a label to an image.




GUse this option to assign a specific label to the image. Optionally youMcan include the image filename, type, width, height, or other image attributeLby embedding special format character. See -comment for details.




For example,
2
    -label "%m:%f %wx%h"




Lproduces an image label of MIFF:bird.miff 512x480 for an image titled?bird.miff and whose width is 512 and height is 480.




GIf the first character of string is @, the image label isGread from a file titled by the remaining characters in the string.




IWhen converting to PostScript, use this option to specify a header<string to print above the image. Specify the label font with-font.





º
>-layer)type

Othe type of layer: Red, Green, Blue, or Matte.




DUse this option to extract a particular layer from the image. Matte,Lfor example, is useful for extracting the opacity values from an image.





¾
>-linewidth*value

Cset the width of a line. See -draw for further details.





¹
>-loop/iterations

7add Netscape loop extension to your GIF animation.




CA value other than zero forces the animation to repeat itself up toiterations times.





¸
>-map-filename

7choose a particular set of colors from this image.




FBy default, color reduction chooses an optimal set of colors that bestHrepresent the original image. Alternatively, you can choose a particular6set of colors from an image file with this option. Use+map to reduceIall images provided on the command line to a single optimal set of colors(that best represent all the images.





Ø
>-matte

Mstore matte channel if the image has one otherwise create an opaque one.





½
>-modulate*value

:vary the brightness, saturation, and hue of an image.




GSpecify the percent change in brightness, the color saturation, and theFhue separated by commas. For example, to increase the color brightnessLby 20% and decrease the color saturation by 10% and leave the hue unchanged,"use: -modulate 20,-10.





»
>-median+radius

(apply a median filter to the image.




EEach pixel is replaced by the median color in a circular neighborhood1whose width is specified with radius.









Ý
>-monochrome

,transform the image to black and white.





º
>-morph+frames

morphs an image sequence.




OBoth the image pixels and size are linearly interpolated to give the appearance4of a meta-morphosis from one image to the next.





Ù
>-mosaic

-create an mosaic from an image sequence.





Ù
>-negate

Freplace every pixel with its complementary color (white becomes black, yellow becomes blue, etc.).




PThe red, green, and blue intensities of an image are negated. Use +negate6to only negate the grayscale pixels of the image.





Ø
>-noise

%add or reduce noise in an image.




HThe principal function of noise peak elimination filter is to smooth theLobjects within an image without losing edge information and without creatingGundesired structures. The central idea of the algorithm is to replace aJpixel with its next neighbor in value within a 3 x 3 window, if this pixelFhas been found to be noise. A pixel is defined as noise if and only if@this pixel is a maximum or minimum within the 3 x 3 window.




IUse +noise followed by a noise type to add noise to an image.#Choose from these noise types:




    Uniform    Gaussian!    Multiplicative    Impulse    Laplacian     Poisson





Ü
>-normalize

<transform image to span the full range of color values.




5This is a contrast enhancement technique.





»
>-opaque*color

4change this color to the pen color within the image.



&See -pen for more details.





¹
>-page{<width>x<height>{+-}<x offset>{+-}<y offset>{%}{!}{<}{>}

*size and location of an image canvas.




0Use this option to specify the dimensions of thePostScript pageGin dots per inch or a TEXT page in pixels. The choices for a Postscriptpage are:


t

       11x17         792  1224 |       Ledger       1224   792    i       Legal         612  1008i       Letter        612   792P       LetterSmall   612   792d       ArchE        2592  3456d       ArchD        1728  2592d       ArchC        1296  1728i       ArchB         864  1296n       ArchA         648   864s       A0           2380  3368s       A1           1684  2380s       A2           1190  1684x       A3            842  1190}       A4            595   842d       A4Small       595   842}       A5            421   595}       A6            297   421}       A7            210   297}       A8            148   210}       A9            105   148}       A10            74   105s       B0           2836  4008s       B1           2004  2836s       B2           1418  2004s       B3           1002  1418x       B4            709  1002}       B5            501   709s       C0           2600  3677s       C1           1837  2600s       C2           1298  1837x       C3            918  1298}       C4            649   918}       C5            459   649}       C6            323   459y       Flsa          612   936 s       Flse          612   936[       HalfLetter    396   612




HFor convenience you can specify the page size by media (e.g. A4, Ledger,0etc.). Otherwise, -page behaves much like-geometry (e.g.&-page letter+43+43>).




ITo position a GIF image, use -page{+-}<x offset>{+-}<y,offset> (e.g. -page "+1"00+200).




OFor a Postscript page, the image is sized as in -geometry and positionedFrelative to the lower left hand corner of the page by {+-}<x8offset>{+-}<y offset>. Use-page 612x792>,Kfor example, to center the image within the page. If the image size exceeds8the Postscript page, it is reduced to fit the page.




=The default page dimensions for a TEXT image is 612x792.




9This option is used in concert with -density.





º
>-paint+radius

simulate an oil painting.




LEach pixel is replaced by the most frequent color in a circular neighborhood1whose width is specified with radius.





¸
>-pen*color

Gset the color of the font or opaque color. See -draw for further details.
C

See X(1) for details about the color specification. A penHcan also be an image. Specify the pen color as an image name preceded by'a @ (e.g. @tile.png).





¾
>-pointsize*value

&pointsize of the Postscript font.





¼
>-preview)type

image preview type.


E

Use this option to affect the preview operation of an image (e.g.Oconvert -preview Gamma Preview:gamma.png). Choose from these previews:$
     Rotate     Shear     Roll     Hue#     Saturation#     Brightness     Gamma     Spiff     Dull"     Grayscale!     Quantize"     Despeckle$     ReduceNoise"     Add Noise      Sharpen     Blur"     Threshold#     EdgeDetect     Spread     Shade     Raise      Segment!     Solarize     Swirl      Implode     Wave!     OilPaint(     CharcoalDrawing#     JPEG




(The default preview is JPEG.





¼
>-profile+string

Aadd ICC color or IPTC newswire information profile to image.




LThe filename must be prefixed with the particular profile type. For example,6icc:color.dat or iptc:news.dat.




6By default, each image is commented with its file





¼
>-quality*value

%JPEG/MIFF/PNG compression level.




JFor the JPEG image format, quality is 0 (worst) to 100 (best). The defaultquality is 75.




NQuality for the MIFF and PNG image format sets the amount of image compressionI(quality / 10) and filter-type (quality % 10). Compression quality valuesNrange from 0 (worst) to 100 (best). If filter-type is 4 or less, the specified+filter-type is used for all scanlines:




    0: none    1: sub    2: up    3: average!    4: Paeth




GIf filter-type is 5, adaptive filtering is used when quality is greaterGthan 50 and the image does not have a color map, otherwise no filtering is used.




ZIf filter-type is 6 or more, adaptive filtering with minimum-sum-of-absolute-values is used.




JThe default is quality is 75. Which means nearly the best compression withadaptive filtering.




!For further information, see the BPNG specification.





º
>-raiseA<width>x<height>

Ilighten or darken image edges to create a 3-D effect. See X(1) for.details about the geometry specification.




NUse -raise to create a raised effect, otherwise use +raise.





»
>-regioni<width>x<height>{+-}<x offset>{+-}<y offset>

-apply options to a portion of the image.




IBy default, any command line options are applied to the entire image. Use-region>to restrict operations to a particular area of the image.





¹
>-rollF{+-}<x offset>{+-}<y offset>

Kroll an image vertically or horizontally. See X(1) for details about the geometry specification.




IA negative x offset rolls the image left-to-right. A negative y.offset rolls the image top-to-bottom.





»
>-rotate8degrees{<}{>}

-apply Paeth image rotation to the image.




CUse > to rotate the image only if its width exceeds theHheight. < rotates the image only if its width is lessKthan the height. For example, if you specify -90> and the imageJsize is 480x640, the image is not rotated by the specified angle. However,;if the image is 640x480, it is rotated by -90 degrees.




KEmpty triangles left over from rotating the image are filled with the color$defined as bordercolor (class$borderColor). See X(1)for details.





»
>-sample-geometry

Gscale image with pixel sampling. See -geometry for details about the geometry specification.





º
>-scene*value

image scene number.





¹
>-seed*value

/pseudo-random number generator seed value.





¼
>-segmentZ<cluster threshold>x<smoothing threshold>

Hsegment an image by analyzing the histograms of the color components andMidentifying units that are homogeneous with the fuzzy c-means technique.




HSpecify cluster threshold as the number of pixels in each clusterJmust exceed the the cluster threshold to be considered valid. SmoothingIthreshold eliminates noise in the second derivative of the histogram.GAs the value is increased, you can expect a smoother second derivative.PThe default is 1.5. See Image Segmentation for details.





º
>-shadeF<azimuth>x<elevation>

2shade the image using a distant light source.




HSpecify azimuth and elevation as the position of the lightFsource. Use +shade to return the shading results as a grayscaleimage. image.





¼
>-sharpen+factor

Gsharpen an image. Specify factor as the percent enhancement (0.0- 99.9%).





º
>-shearA<x degrees>x<y degrees>

Qshear the image along the X or Y axis by a positive or negative shear angle.




FShearing slides one edge of an image along the X or Y axis, creating aJparallelogram. An X direction shear slides an edge along the X axis, whileFa Y direction shear slides an edge along the Y axis. The amount of theNshear is controlled by a shear angle. For X direction shears, x degreesIis measured relative to the Y axis, and similarly, for Y direction shears9y degrees is measured relative to the X axis.




KEmpty triangles left over from shearing the image are filled with the color$defined as bordercolor (class$borderColor). See X(1)for details.





¹
>-sizeC<width>x<height>{+offset}

#width and height of the image.




NUse this option to specify the width and height of raw images whose dimensions are unknown such as GRAY,'RGB, or CMYK. In additionto width and height, use.-size to skip any header information inHthe image or tell the number of colors in a MAP image file, (e.g.-size 640x512+256).




2For Photo CD images, choose from these sizes:




   192x128   384x256   768x512   1536x1024   3072x2048




JFinally, use this option to choose a particular resolution layer of a JBIG)or JPEG image (e.g. -size 1024x768).





½
>-solarize+factor

Inegate all pixels above the threshold level. Specify factor as the4percent threshold of the intensity (0 - 99.9%).




FThis option produces a solarization effect seen when exposing a?photographic film to light during the development process.





»
>-spread+amount

.displace image pixels by a random amount.




GAmount defines the size of the neighborhood around each pixel to&choose a candidate pixel to swap.





º
>-swirl,degrees

)swirl image pixels about the center.




7Degrees defines the tightness of the swirl.





Á
>-transparency*color

2make this color transparent within the image.





¼
>-texture-filename

7name of texture to tile onto the image background.





¾
>-threshold*value

threshold the image.




FCreate a bi-level image such that any pixel intensity that is equal orGexceeds the threshold is reassigned the maximum intensity otherwise theminimum intensity.





¾
>-treedepth*value

HNormally, this integer value is zero or one. A zero or one tells displayGto choose an optimal tree depth for the color reduction algorithm.




GAn optimal depth generally allows the best representation of the sourceJimage with the fastest computational speed and the least amount of memory.FHowever, the default depth is inappropriate for some images. To assureGthe best representation, try values between 2 and 8 for this parameter.Refer to;quantize for more details.




KThe -colors or -monochrome option is required for this optionto take effect.





º
>-units)type

Hthe type of image resolution: Undefined, PixelsPerInch, or PixelsPerCentimeter.





Ú
>-verbose

0print detailed information about the image.




HThis information is printed: image scene number; image name; image size;Lthe image class (DirectClass or PseudoClass); the total numberLof unique colors; and the number of seconds to read and transform the image.PRefer to miff for a description of the image class.




IIf -colors is also specified, the total unique colors in the image[and color reduction error values are printed. Refer to quantize'for a description of these values.





¹
>-view+string

FlashPix viewing paramters.





¹
>-waveI<amplitude>x<wavelength>

&alter an image along a sine wave.




LSpecify amplitude and wavelength to effect the characteristicsof the wave.




JBy default, the image format is determined by its magic number. To specifyIa particular image format, precede the filename with an image format nameIand a colon (i.e.ps:image) or specify the image type as thefilename suffix
I

When you specify X as your image type, the filename has special8meaning. It specifies an X window by id, name, orroot. IfFno filename is specified, the window is selected by clicking the mousein the desired window.5

Specify input_file as - for standard input,output_fileJas - for standard output. If input_file has the extension .ZorL.gz, the file is uncompressed with uncompress or gunzipBrespectively. If output_file has the extension .Z or .gz,Sthe file size is compressed using with compress or gzip respectively.GFinally, precede the image file name with | to pipe to or from a systemcommand.J

Use an optional index enclosed in brackets after a file name to specifyIa desired subimage of a multi-resolution image format like Photo CD (e.g.Nimg0001.pcd[4]) or a range for MPEG images (e.g. video.mpg[50-75]). A subimageGspecification can be disjoint (e.g. image.tiff[2,7,4]). For raw images,Qspecify a subimage with a geometry (e.g. -size 640x512 image.rgb[320x256+50+50]).O

Single images are written with the filename you specify. However, multi-partLimages (i.e. a multi-page PostScript document with +adjoin specified)Kare written with the filename followed by a period (.) and the sceneHnumber. You can change this behavior by embedding a printf format,specification in the file name. For example,




image%02d.miff



/converts files image00.miff, image01.miff, etc.



MPrepend an at sign @ to a filename to read a list of image filenamesGfrom that file. This is convenient in the event you have too many image*filenames to fit on the command line.



*Back to Contents




¹
>Image*Segmentation




FUse -segment to segment an image by analyzing the histograms ofHthe color components and identifying units that are homogeneous with theGfuzzy c-means technique. The scale-space filter analyzes the histogramsKof the three color components of the image and identifies a set of classes.RThe extents of each class is used to coarsely segment the image with thresholding.GThe color associated with each class is determined by the mean color ofNall pixels within the extents of a particular class. Finally, any unclassifiedOpixels are assigned to the closest class with the fuzzy c-means technique.


<

The fuzzy c-Means algorithm can be summarized as follows:





FThe fuzzy c-Means technique attempts to cluster a pixel by finding theKlocal minima of the generalized within group sum of squared error objectivePfunction. A pixel is assigned to the closest class of which the fuzzy membershiphas a maximum value."

For additional information see:R

Young Won Lim, Sang Uk Lee, "On The Color Image SegmentationJAlgorithm Based on the Thresholding and the Fuzzy c-Means Techniques",KPattern Recognition, Volume 23, Number 9, pages 935-952, 1990.

*Back to Contents




Ý
>Environment
 
Ù
>DISPLAY

9To get the default host, display number, and screen.


*Back to Contents






Ù
>Authors




cJohn Cristy, magick@wizards.dupont.com=E.I. du Pont de Nemours and Company Incorporated.

*Back to Contents






Û
>Copyright




1Copyright (C) 2000 ImageMagick Studio




HPermission is hereby granted, free of charge, to any person obtainingKa copy of this software and associated documentation files ("ImageMagick"),Hto deal in ImageMagick without restriction, including without limitationHthe rights to use, copy, modify, merge, publish, distribute, sublicense,Pand/or sell copies of ImageMagick, and to permit persons to whom the ImageMagickDis furnished to do so, subject to the following conditions:




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




JThe software is provided "as is", without warranty of any kind, expressKor implied, including but not limited to the warranties of merchantability,Ffitness for a particular purpose and noninfringement.In no event shall6ImageMagick Studio be liable for any claim, damages orMother liability, whether in an action of contract, tort or otherwise, arisingKfrom, out of or in connection with ImageMagick or the use or other dealingsin ImageMagick.




GExcept as contained in this notice, the name of the E. I. du Pont deLNemours and Company shall not be used in advertising or otherwise to promoteRthe sale, use or other dealings in ImageMagick without prior written authorization%from the ImageMagick Studio.

*Back to Contents




Home Page Image3manipulation software that works like magic.