From: Cristy Date: Fri, 1 Apr 2016 11:22:40 +0000 (-0400) Subject: The 'magick' utility supports sub-commands, e.g., 'magick convert' X-Git-Tag: 7.0.1-0~94 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f87e0da4ce289c844a2b63bc4674be31e4cac9b1;p=imagemagick The 'magick' utility supports sub-commands, e.g., 'magick convert' --- diff --git a/ImageMagick-7.0.0-0/enhance.c b/ImageMagick-7.0.0-0/enhance.c deleted file mode 100644 index b59f71714..000000000 --- a/ImageMagick-7.0.0-0/enhance.c +++ /dev/null @@ -1,3886 +0,0 @@ -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% EEEEE N N H H AAA N N CCCC EEEEE % -% E NN N H H A A NN N C E % -% EEE N N N HHHHH AAAAA N N N C EEE % -% E N NN H H A A N NN C E % -% EEEEE N N H H A A N N CCCC EEEEE % -% % -% % -% MagickCore Image Enhancement Methods % -% % -% Software Design % -% Cristy % -% July 1992 % -% % -% % -% Copyright 1999-2016 ImageMagick Studio LLC, a non-profit organization % -% dedicated to making software imaging solutions freely available. % -% % -% You may not use this file except in compliance with the License. You may % -% obtain a copy of the License at % -% % -% http://www.imagemagick.org/script/license.php % -% % -% Unless required by applicable law or agreed to in writing, software % -% distributed under the License is distributed on an "AS IS" BASIS, % -% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. % -% See the License for the specific language governing permissions and % -% limitations under the License. % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% -% -*/ - -/* - Include declarations. -*/ -#include "MagickCore/studio.h" -#include "MagickCore/accelerate.h" -#include "MagickCore/artifact.h" -#include "MagickCore/attribute.h" -#include "MagickCore/cache.h" -#include "MagickCore/cache-view.h" -#include "MagickCore/channel.h" -#include "MagickCore/color.h" -#include "MagickCore/color-private.h" -#include "MagickCore/colorspace.h" -#include "MagickCore/colorspace-private.h" -#include "MagickCore/composite-private.h" -#include "MagickCore/enhance.h" -#include "MagickCore/exception.h" -#include "MagickCore/exception-private.h" -#include "MagickCore/fx.h" -#include "MagickCore/gem.h" -#include "MagickCore/gem-private.h" -#include "MagickCore/geometry.h" -#include "MagickCore/histogram.h" -#include "MagickCore/image.h" -#include "MagickCore/image-private.h" -#include "MagickCore/memory_.h" -#include "MagickCore/monitor.h" -#include "MagickCore/monitor-private.h" -#include "MagickCore/option.h" -#include "MagickCore/pixel.h" -#include "MagickCore/pixel-accessor.h" -#include "MagickCore/quantum.h" -#include "MagickCore/quantum-private.h" -#include "MagickCore/resample.h" -#include "MagickCore/resample-private.h" -#include "MagickCore/resource_.h" -#include "MagickCore/statistic.h" -#include "MagickCore/string_.h" -#include "MagickCore/string-private.h" -#include "MagickCore/thread-private.h" -#include "MagickCore/threshold.h" -#include "MagickCore/token.h" -#include "MagickCore/xml-tree.h" -#include "MagickCore/xml-tree-private.h" - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% A u t o G a m m a I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% AutoGammaImage() extract the 'mean' from the image and adjust the image -% to try make set its gamma appropriatally. -% -% The format of the AutoGammaImage method is: -% -% MagickBooleanType AutoGammaImage(Image *image,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: The image to auto-level -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType AutoGammaImage(Image *image, - ExceptionInfo *exception) -{ - double - gamma, - log_mean, - mean, - sans; - - MagickStatusType - status; - - register ssize_t - i; - - log_mean=log(0.5); - if (image->channel_mask == DefaultChannels) - { - /* - Apply gamma correction equally across all given channels. - */ - (void) GetImageMean(image,&mean,&sans,exception); - gamma=log(mean*QuantumScale)/log_mean; - return(LevelImage(image,0.0,(double) QuantumRange,gamma,exception)); - } - /* - Auto-gamma each channel separately. - */ - status=MagickTrue; - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - ChannelType - channel_mask; - - PixelChannel channel=GetPixelChannelChannel(image,i); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; - channel_mask=SetImageChannelMask(image,(ChannelType) (1 << i)); - status=GetImageMean(image,&mean,&sans,exception); - gamma=log(mean*QuantumScale)/log_mean; - status&=LevelImage(image,0.0,(double) QuantumRange,gamma,exception); - (void) SetImageChannelMask(image,channel_mask); - if (status == MagickFalse) - break; - } - return(status != 0 ? MagickTrue : MagickFalse); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% A u t o L e v e l I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% AutoLevelImage() adjusts the levels of a particular image channel by -% scaling the minimum and maximum values to the full quantum range. -% -% The format of the LevelImage method is: -% -% MagickBooleanType AutoLevelImage(Image *image,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: The image to auto-level -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType AutoLevelImage(Image *image, - ExceptionInfo *exception) -{ - return(MinMaxStretchImage(image,0.0,0.0,1.0,exception)); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% B r i g h t n e s s C o n t r a s t I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% BrightnessContrastImage() changes the brightness and/or contrast of an -% image. It converts the brightness and contrast parameters into slope and -% intercept and calls a polynomical function to apply to the image. -% -% The format of the BrightnessContrastImage method is: -% -% MagickBooleanType BrightnessContrastImage(Image *image, -% const double brightness,const double contrast,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o brightness: the brightness percent (-100 .. 100). -% -% o contrast: the contrast percent (-100 .. 100). -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType BrightnessContrastImage(Image *image, - const double brightness,const double contrast,ExceptionInfo *exception) -{ -#define BrightnessContastImageTag "BrightnessContast/Image" - - double - alpha, - coefficients[2], - intercept, - slope; - - MagickBooleanType - status; - - /* - Compute slope and intercept. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - alpha=contrast; - slope=tan((double) (MagickPI*(alpha/100.0+1.0)/4.0)); - if (slope < 0.0) - slope=0.0; - intercept=brightness/100.0+((100-brightness)/200.0)*(1.0-slope); - coefficients[0]=slope; - coefficients[1]=intercept; - status=FunctionImage(image,PolynomialFunction,2,coefficients,exception); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% C l u t I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% ClutImage() replaces each color value in the given image, by using it as an -% index to lookup a replacement color value in a Color Look UP Table in the -% form of an image. The values are extracted along a diagonal of the CLUT -% image so either a horizontal or vertial gradient image can be used. -% -% Typically this is used to either re-color a gray-scale image according to a -% color gradient in the CLUT image, or to perform a freeform histogram -% (level) adjustment according to the (typically gray-scale) gradient in the -% CLUT image. -% -% When the 'channel' mask includes the matte/alpha transparency channel but -% one image has no such channel it is assumed that that image is a simple -% gray-scale image that will effect the alpha channel values, either for -% gray-scale coloring (with transparent or semi-transparent colors), or -% a histogram adjustment of existing alpha channel values. If both images -% have matte channels, direct and normal indexing is applied, which is rarely -% used. -% -% The format of the ClutImage method is: -% -% MagickBooleanType ClutImage(Image *image,Image *clut_image, -% const PixelInterpolateMethod method,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image, which is replaced by indexed CLUT values -% -% o clut_image: the color lookup table image for replacement color values. -% -% o method: the pixel interpolation method. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType ClutImage(Image *image,const Image *clut_image, - const PixelInterpolateMethod method,ExceptionInfo *exception) -{ -#define ClutImageTag "Clut/Image" - - CacheView - *clut_view, - *image_view; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - PixelInfo - *clut_map; - - register ssize_t - i; - - ssize_t adjust, - y; - - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - assert(clut_image != (Image *) NULL); - assert(clut_image->signature == MagickCoreSignature); - if( SetImageStorageClass(image,DirectClass,exception) == MagickFalse) - return(MagickFalse); - if( (IsGrayColorspace(image->colorspace) != MagickFalse) && - (IsGrayColorspace(clut_image->colorspace) == MagickFalse)) - (void) SetImageColorspace(image,sRGBColorspace,exception); - clut_map=(PixelInfo *) AcquireQuantumMemory(MaxMap+1UL,sizeof(*clut_map)); - if (clut_map == (PixelInfo *) NULL) - ThrowBinaryException(ResourceLimitError,"MemoryAllocationFailed", - image->filename); - /* - Clut image. - */ - status=MagickTrue; - progress=0; - adjust=(ssize_t) (clut_image->interpolate == IntegerInterpolatePixel ? 0 : 1); - clut_view=AcquireVirtualCacheView(clut_image,exception); - for (i=0; i <= (ssize_t) MaxMap; i++) - { - GetPixelInfo(clut_image,clut_map+i); - (void) InterpolatePixelInfo(clut_image,clut_view,method, - (double) i*(clut_image->columns-adjust)/MaxMap,(double) i* - (clut_image->rows-adjust)/MaxMap,clut_map+i,exception); - } - clut_view=DestroyCacheView(clut_view); - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - PixelInfo - pixel; - - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - GetPixelInfo(image,&pixel); - for (x=0; x < (ssize_t) image->columns; x++) - { - PixelTrait - traits; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - GetPixelInfoPixel(image,q,&pixel); - traits=GetPixelChannelTraits(image,RedPixelChannel); - if ((traits & UpdatePixelTrait) != 0) - pixel.red=clut_map[ScaleQuantumToMap(ClampToQuantum( - pixel.red))].red; - traits=GetPixelChannelTraits(image,GreenPixelChannel); - if ((traits & UpdatePixelTrait) != 0) - pixel.green=clut_map[ScaleQuantumToMap(ClampToQuantum( - pixel.green))].green; - traits=GetPixelChannelTraits(image,BluePixelChannel); - if ((traits & UpdatePixelTrait) != 0) - pixel.blue=clut_map[ScaleQuantumToMap(ClampToQuantum( - pixel.blue))].blue; - traits=GetPixelChannelTraits(image,BlackPixelChannel); - if ((traits & UpdatePixelTrait) != 0) - pixel.black=clut_map[ScaleQuantumToMap(ClampToQuantum( - pixel.black))].black; - traits=GetPixelChannelTraits(image,AlphaPixelChannel); - if ((traits & UpdatePixelTrait) != 0) - pixel.alpha=clut_map[ScaleQuantumToMap(ClampToQuantum( - pixel.alpha))].alpha; - SetPixelViaPixelInfo(image,&pixel,q); - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_ClutImage) -#endif - proceed=SetImageProgress(image,ClutImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - clut_map=(PixelInfo *) RelinquishMagickMemory(clut_map); - if ((clut_image->alpha_trait != UndefinedPixelTrait) && - ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0)) - (void) SetImageAlphaChannel(image,ActivateAlphaChannel,exception); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% C o l o r D e c i s i o n L i s t I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% ColorDecisionListImage() accepts a lightweight Color Correction Collection -% (CCC) file which solely contains one or more color corrections and applies -% the correction to the image. Here is a sample CCC file: -% -% -% -% -% 0.9 1.2 0.5 -% 0.4 -0.5 0.6 -% 1.0 0.8 1.5 -% -% -% 0.85 -% -% -% -% -% which includes the slop, offset, and power for each of the RGB channels -% as well as the saturation. -% -% The format of the ColorDecisionListImage method is: -% -% MagickBooleanType ColorDecisionListImage(Image *image, -% const char *color_correction_collection,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o color_correction_collection: the color correction collection in XML. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType ColorDecisionListImage(Image *image, - const char *color_correction_collection,ExceptionInfo *exception) -{ -#define ColorDecisionListCorrectImageTag "ColorDecisionList/Image" - - typedef struct _Correction - { - double - slope, - offset, - power; - } Correction; - - typedef struct _ColorCorrection - { - Correction - red, - green, - blue; - - double - saturation; - } ColorCorrection; - - CacheView - *image_view; - - char - token[MagickPathExtent]; - - ColorCorrection - color_correction; - - const char - *content, - *p; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - PixelInfo - *cdl_map; - - register ssize_t - i; - - ssize_t - y; - - XMLTreeInfo - *cc, - *ccc, - *sat, - *sop; - - /* - Allocate and initialize cdl maps. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (color_correction_collection == (const char *) NULL) - return(MagickFalse); - ccc=NewXMLTree((const char *) color_correction_collection,exception); - if (ccc == (XMLTreeInfo *) NULL) - return(MagickFalse); - cc=GetXMLTreeChild(ccc,"ColorCorrection"); - if (cc == (XMLTreeInfo *) NULL) - { - ccc=DestroyXMLTree(ccc); - return(MagickFalse); - } - color_correction.red.slope=1.0; - color_correction.red.offset=0.0; - color_correction.red.power=1.0; - color_correction.green.slope=1.0; - color_correction.green.offset=0.0; - color_correction.green.power=1.0; - color_correction.blue.slope=1.0; - color_correction.blue.offset=0.0; - color_correction.blue.power=1.0; - color_correction.saturation=0.0; - sop=GetXMLTreeChild(cc,"SOPNode"); - if (sop != (XMLTreeInfo *) NULL) - { - XMLTreeInfo - *offset, - *power, - *slope; - - slope=GetXMLTreeChild(sop,"Slope"); - if (slope != (XMLTreeInfo *) NULL) - { - content=GetXMLTreeContent(slope); - p=(const char *) content; - for (i=0; (*p != '\0') && (i < 3); i++) - { - GetNextToken(p,&p,MagickPathExtent,token); - if (*token == ',') - GetNextToken(p,&p,MagickPathExtent,token); - switch (i) - { - case 0: - { - color_correction.red.slope=StringToDouble(token,(char **) NULL); - break; - } - case 1: - { - color_correction.green.slope=StringToDouble(token, - (char **) NULL); - break; - } - case 2: - { - color_correction.blue.slope=StringToDouble(token, - (char **) NULL); - break; - } - } - } - } - offset=GetXMLTreeChild(sop,"Offset"); - if (offset != (XMLTreeInfo *) NULL) - { - content=GetXMLTreeContent(offset); - p=(const char *) content; - for (i=0; (*p != '\0') && (i < 3); i++) - { - GetNextToken(p,&p,MagickPathExtent,token); - if (*token == ',') - GetNextToken(p,&p,MagickPathExtent,token); - switch (i) - { - case 0: - { - color_correction.red.offset=StringToDouble(token, - (char **) NULL); - break; - } - case 1: - { - color_correction.green.offset=StringToDouble(token, - (char **) NULL); - break; - } - case 2: - { - color_correction.blue.offset=StringToDouble(token, - (char **) NULL); - break; - } - } - } - } - power=GetXMLTreeChild(sop,"Power"); - if (power != (XMLTreeInfo *) NULL) - { - content=GetXMLTreeContent(power); - p=(const char *) content; - for (i=0; (*p != '\0') && (i < 3); i++) - { - GetNextToken(p,&p,MagickPathExtent,token); - if (*token == ',') - GetNextToken(p,&p,MagickPathExtent,token); - switch (i) - { - case 0: - { - color_correction.red.power=StringToDouble(token,(char **) NULL); - break; - } - case 1: - { - color_correction.green.power=StringToDouble(token, - (char **) NULL); - break; - } - case 2: - { - color_correction.blue.power=StringToDouble(token, - (char **) NULL); - break; - } - } - } - } - } - sat=GetXMLTreeChild(cc,"SATNode"); - if (sat != (XMLTreeInfo *) NULL) - { - XMLTreeInfo - *saturation; - - saturation=GetXMLTreeChild(sat,"Saturation"); - if (saturation != (XMLTreeInfo *) NULL) - { - content=GetXMLTreeContent(saturation); - p=(const char *) content; - GetNextToken(p,&p,MagickPathExtent,token); - color_correction.saturation=StringToDouble(token,(char **) NULL); - } - } - ccc=DestroyXMLTree(ccc); - if (image->debug != MagickFalse) - { - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " Color Correction Collection:"); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.red.slope: %g",color_correction.red.slope); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.red.offset: %g",color_correction.red.offset); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.red.power: %g",color_correction.red.power); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.green.slope: %g",color_correction.green.slope); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.green.offset: %g",color_correction.green.offset); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.green.power: %g",color_correction.green.power); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.blue.slope: %g",color_correction.blue.slope); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.blue.offset: %g",color_correction.blue.offset); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.blue.power: %g",color_correction.blue.power); - (void) LogMagickEvent(TransformEvent,GetMagickModule(), - " color_correction.saturation: %g",color_correction.saturation); - } - cdl_map=(PixelInfo *) AcquireQuantumMemory(MaxMap+1UL,sizeof(*cdl_map)); - if (cdl_map == (PixelInfo *) NULL) - ThrowBinaryException(ResourceLimitError,"MemoryAllocationFailed", - image->filename); - for (i=0; i <= (ssize_t) MaxMap; i++) - { - cdl_map[i].red=(double) ScaleMapToQuantum((double) - (MaxMap*(pow(color_correction.red.slope*i/MaxMap+ - color_correction.red.offset,color_correction.red.power)))); - cdl_map[i].green=(double) ScaleMapToQuantum((double) - (MaxMap*(pow(color_correction.green.slope*i/MaxMap+ - color_correction.green.offset,color_correction.green.power)))); - cdl_map[i].blue=(double) ScaleMapToQuantum((double) - (MaxMap*(pow(color_correction.blue.slope*i/MaxMap+ - color_correction.blue.offset,color_correction.blue.power)))); - } - if (image->storage_class == PseudoClass) - for (i=0; i < (ssize_t) image->colors; i++) - { - /* - Apply transfer function to colormap. - */ - double - luma; - - luma=0.21267f*image->colormap[i].red+0.71526*image->colormap[i].green+ - 0.07217f*image->colormap[i].blue; - image->colormap[i].red=luma+color_correction.saturation*cdl_map[ - ScaleQuantumToMap(ClampToQuantum(image->colormap[i].red))].red-luma; - image->colormap[i].green=luma+color_correction.saturation*cdl_map[ - ScaleQuantumToMap(ClampToQuantum(image->colormap[i].green))].green-luma; - image->colormap[i].blue=luma+color_correction.saturation*cdl_map[ - ScaleQuantumToMap(ClampToQuantum(image->colormap[i].blue))].blue-luma; - } - /* - Apply transfer function to image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - double - luma; - - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - luma=0.21267f*GetPixelRed(image,q)+0.71526*GetPixelGreen(image,q)+ - 0.07217f*GetPixelBlue(image,q); - SetPixelRed(image,ClampToQuantum(luma+color_correction.saturation* - (cdl_map[ScaleQuantumToMap(GetPixelRed(image,q))].red-luma)),q); - SetPixelGreen(image,ClampToQuantum(luma+color_correction.saturation* - (cdl_map[ScaleQuantumToMap(GetPixelGreen(image,q))].green-luma)),q); - SetPixelBlue(image,ClampToQuantum(luma+color_correction.saturation* - (cdl_map[ScaleQuantumToMap(GetPixelBlue(image,q))].blue-luma)),q); - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_ColorDecisionListImageChannel) -#endif - proceed=SetImageProgress(image,ColorDecisionListCorrectImageTag, - progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - cdl_map=(PixelInfo *) RelinquishMagickMemory(cdl_map); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% C o n t r a s t I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% ContrastImage() enhances the intensity differences between the lighter and -% darker elements of the image. Set sharpen to a MagickTrue to increase the -% image contrast otherwise the contrast is reduced. -% -% The format of the ContrastImage method is: -% -% MagickBooleanType ContrastImage(Image *image, -% const MagickBooleanType sharpen,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o sharpen: Increase or decrease image contrast. -% -% o exception: return any errors or warnings in this structure. -% -*/ - -static void Contrast(const int sign,double *red,double *green,double *blue) -{ - double - brightness, - hue, - saturation; - - /* - Enhance contrast: dark color become darker, light color become lighter. - */ - assert(red != (double *) NULL); - assert(green != (double *) NULL); - assert(blue != (double *) NULL); - hue=0.0; - saturation=0.0; - brightness=0.0; - ConvertRGBToHSB(*red,*green,*blue,&hue,&saturation,&brightness); - brightness+=0.5*sign*(0.5*(sin((double) (MagickPI*(brightness-0.5)))+1.0)- - brightness); - if (brightness > 1.0) - brightness=1.0; - else - if (brightness < 0.0) - brightness=0.0; - ConvertHSBToRGB(hue,saturation,brightness,red,green,blue); -} - -MagickExport MagickBooleanType ContrastImage(Image *image, - const MagickBooleanType sharpen,ExceptionInfo *exception) -{ -#define ContrastImageTag "Contrast/Image" - - CacheView - *image_view; - - int - sign; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - register ssize_t - i; - - ssize_t - y; - - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (AccelerateContrastImage(image,sharpen,exception) != MagickFalse) - return(MagickTrue); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - sign=sharpen != MagickFalse ? 1 : -1; - if (image->storage_class == PseudoClass) - { - /* - Contrast enhance colormap. - */ - for (i=0; i < (ssize_t) image->colors; i++) - { - double - blue, - green, - red; - - red=(double) image->colormap[i].red; - green=(double) image->colormap[i].green; - blue=(double) image->colormap[i].blue; - Contrast(sign,&red,&green,&blue); - image->colormap[i].red=(MagickRealType) red; - image->colormap[i].green=(MagickRealType) green; - image->colormap[i].blue=(MagickRealType) blue; - } - } - /* - Contrast enhance image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - double - blue, - green, - red; - - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - red=(double) GetPixelRed(image,q); - green=(double) GetPixelGreen(image,q); - blue=(double) GetPixelBlue(image,q); - Contrast(sign,&red,&green,&blue); - SetPixelRed(image,ClampToQuantum(red),q); - SetPixelGreen(image,ClampToQuantum(green),q); - SetPixelBlue(image,ClampToQuantum(blue),q); - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_ContrastImage) -#endif - proceed=SetImageProgress(image,ContrastImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% C o n t r a s t S t r e t c h I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% ContrastStretchImage() is a simple image enhancement technique that attempts -% to improve the contrast in an image by 'stretching' the range of intensity -% values it contains to span a desired range of values. It differs from the -% more sophisticated histogram equalization in that it can only apply a -% linear scaling function to the image pixel values. As a result the -% 'enhancement' is less harsh. -% -% The format of the ContrastStretchImage method is: -% -% MagickBooleanType ContrastStretchImage(Image *image, -% const char *levels,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o black_point: the black point. -% -% o white_point: the white point. -% -% o levels: Specify the levels where the black and white points have the -% range of 0 to number-of-pixels (e.g. 1%, 10x90%, etc.). -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType ContrastStretchImage(Image *image, - const double black_point,const double white_point,ExceptionInfo *exception) -{ -#define MaxRange(color) ((double) ScaleQuantumToMap((Quantum) (color))) -#define ContrastStretchImageTag "ContrastStretch/Image" - - CacheView - *image_view; - - double - *black, - *histogram, - *stretch_map, - *white; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - register ssize_t - i; - - ssize_t - y; - - /* - Allocate histogram and stretch map. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (SetImageGray(image,exception) != MagickFalse) - (void) SetImageColorspace(image,GRAYColorspace,exception); - black=(double *) AcquireQuantumMemory(GetPixelChannels(image),sizeof(*black)); - white=(double *) AcquireQuantumMemory(GetPixelChannels(image),sizeof(*white)); - histogram=(double *) AcquireQuantumMemory(MaxMap+1UL,GetPixelChannels(image)* - sizeof(*histogram)); - stretch_map=(double *) AcquireQuantumMemory(MaxMap+1UL, - GetPixelChannels(image)*sizeof(*stretch_map)); - if ((black == (double *) NULL) || (white == (double *) NULL) || - (histogram == (double *) NULL) || (stretch_map == (double *) NULL)) - { - if (stretch_map != (double *) NULL) - stretch_map=(double *) RelinquishMagickMemory(stretch_map); - if (histogram != (double *) NULL) - histogram=(double *) RelinquishMagickMemory(histogram); - if (white != (double *) NULL) - white=(double *) RelinquishMagickMemory(white); - if (black != (double *) NULL) - black=(double *) RelinquishMagickMemory(black); - ThrowBinaryException(ResourceLimitError,"MemoryAllocationFailed", - image->filename); - } - /* - Form histogram. - */ - status=MagickTrue; - (void) ResetMagickMemory(histogram,0,(MaxMap+1)*GetPixelChannels(image)* - sizeof(*histogram)); - image_view=AcquireVirtualCacheView(image,exception); - for (y=0; y < (ssize_t) image->rows; y++) - { - register const Quantum - *magick_restrict p; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - p=GetCacheViewVirtualPixels(image_view,0,y,image->columns,1,exception); - if (p == (const Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - double - pixel; - - pixel=GetPixelIntensity(image,p); - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - if (image->channel_mask != DefaultChannels) - pixel=(double) p[i]; - histogram[GetPixelChannels(image)*ScaleQuantumToMap( - ClampToQuantum(pixel))+i]++; - } - p+=GetPixelChannels(image); - } - } - image_view=DestroyCacheView(image_view); - /* - Find the histogram boundaries by locating the black/white levels. - */ - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - double - intensity; - - register ssize_t - j; - - black[i]=0.0; - white[i]=MaxRange(QuantumRange); - intensity=0.0; - for (j=0; j <= (ssize_t) MaxMap; j++) - { - intensity+=histogram[GetPixelChannels(image)*j+i]; - if (intensity > black_point) - break; - } - black[i]=(double) j; - intensity=0.0; - for (j=(ssize_t) MaxMap; j != 0; j--) - { - intensity+=histogram[GetPixelChannels(image)*j+i]; - if (intensity > ((double) image->columns*image->rows-white_point)) - break; - } - white[i]=(double) j; - } - histogram=(double *) RelinquishMagickMemory(histogram); - /* - Stretch the histogram to create the stretched image mapping. - */ - (void) ResetMagickMemory(stretch_map,0,(MaxMap+1)*GetPixelChannels(image)* - sizeof(*stretch_map)); - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - register ssize_t - j; - - for (j=0; j <= (ssize_t) MaxMap; j++) - { - double - gamma; - - gamma=PerceptibleReciprocal(white[i]-black[i]); - if (j < (ssize_t) black[i]) - stretch_map[GetPixelChannels(image)*j+i]=0.0; - else - if (j > (ssize_t) white[i]) - stretch_map[GetPixelChannels(image)*j+i]=(double) QuantumRange; - else - stretch_map[GetPixelChannels(image)*j+i]=(double) ScaleMapToQuantum( - (double) (MaxMap*gamma*(j-black[i]))); - } - } - if (image->storage_class == PseudoClass) - { - register ssize_t - j; - - /* - Stretch-contrast colormap. - */ - for (j=0; j < (ssize_t) image->colors; j++) - { - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - { - i=GetPixelChannelOffset(image,RedPixelChannel); - image->colormap[j].red=stretch_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].red))+i]; - } - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - { - i=GetPixelChannelOffset(image,GreenPixelChannel); - image->colormap[j].green=stretch_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].green))+i]; - } - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - { - i=GetPixelChannelOffset(image,BluePixelChannel); - image->colormap[j].blue=stretch_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].blue))+i]; - } - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - { - i=GetPixelChannelOffset(image,AlphaPixelChannel); - image->colormap[j].alpha=stretch_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].alpha))+i]; - } - } - } - /* - Stretch-contrast image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - j; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - for (j=0; j < (ssize_t) GetPixelChannels(image); j++) - { - PixelChannel channel=GetPixelChannelChannel(image,j); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; - q[j]=ClampToQuantum(stretch_map[GetPixelChannels(image)* - ScaleQuantumToMap(q[j])+j]); - } - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_ContrastStretchImage) -#endif - proceed=SetImageProgress(image,ContrastStretchImageTag,progress++, - image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - stretch_map=(double *) RelinquishMagickMemory(stretch_map); - white=(double *) RelinquishMagickMemory(white); - black=(double *) RelinquishMagickMemory(black); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% E n h a n c e I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% EnhanceImage() applies a digital filter that improves the quality of a -% noisy image. -% -% The format of the EnhanceImage method is: -% -% Image *EnhanceImage(const Image *image,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport Image *EnhanceImage(const Image *image,ExceptionInfo *exception) -{ -#define EnhanceImageTag "Enhance/Image" -#define EnhancePixel(weight) \ - mean=QuantumScale*((double) GetPixelRed(image,r)+pixel.red)/2.0; \ - distance=QuantumScale*((double) GetPixelRed(image,r)-pixel.red); \ - distance_squared=(4.0+mean)*distance*distance; \ - mean=QuantumScale*((double) GetPixelGreen(image,r)+pixel.green)/2.0; \ - distance=QuantumScale*((double) GetPixelGreen(image,r)-pixel.green); \ - distance_squared+=(7.0-mean)*distance*distance; \ - mean=QuantumScale*((double) GetPixelBlue(image,r)+pixel.blue)/2.0; \ - distance=QuantumScale*((double) GetPixelBlue(image,r)-pixel.blue); \ - distance_squared+=(5.0-mean)*distance*distance; \ - mean=QuantumScale*((double) GetPixelBlack(image,r)+pixel.black)/2.0; \ - distance=QuantumScale*((double) GetPixelBlack(image,r)-pixel.black); \ - distance_squared+=(5.0-mean)*distance*distance; \ - mean=QuantumScale*((double) GetPixelAlpha(image,r)+pixel.alpha)/2.0; \ - distance=QuantumScale*((double) GetPixelAlpha(image,r)-pixel.alpha); \ - distance_squared+=(5.0-mean)*distance*distance; \ - if (distance_squared < 0.069) \ - { \ - aggregate.red+=(weight)*GetPixelRed(image,r); \ - aggregate.green+=(weight)*GetPixelGreen(image,r); \ - aggregate.blue+=(weight)*GetPixelBlue(image,r); \ - aggregate.black+=(weight)*GetPixelBlack(image,r); \ - aggregate.alpha+=(weight)*GetPixelAlpha(image,r); \ - total_weight+=(weight); \ - } \ - r+=GetPixelChannels(image); - - CacheView - *enhance_view, - *image_view; - - Image - *enhance_image; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - ssize_t - y; - - /* - Initialize enhanced image attributes. - */ - assert(image != (const Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - assert(exception != (ExceptionInfo *) NULL); - assert(exception->signature == MagickCoreSignature); - enhance_image=CloneImage(image,image->columns,image->rows,MagickTrue, - exception); - if (enhance_image == (Image *) NULL) - return((Image *) NULL); - if (SetImageStorageClass(enhance_image,DirectClass,exception) == MagickFalse) - { - enhance_image=DestroyImage(enhance_image); - return((Image *) NULL); - } - /* - Enhance image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireVirtualCacheView(image,exception); - enhance_view=AcquireAuthenticCacheView(enhance_image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,enhance_image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - PixelInfo - pixel; - - register const Quantum - *magick_restrict p; - - register Quantum - *magick_restrict q; - - register ssize_t - x; - - ssize_t - center; - - if (status == MagickFalse) - continue; - p=GetCacheViewVirtualPixels(image_view,-2,y-2,image->columns+4,5,exception); - q=QueueCacheViewAuthenticPixels(enhance_view,0,y,enhance_image->columns,1, - exception); - if ((p == (const Quantum *) NULL) || (q == (Quantum *) NULL)) - { - status=MagickFalse; - continue; - } - center=(ssize_t) GetPixelChannels(image)*(2*(image->columns+4)+2); - GetPixelInfo(image,&pixel); - for (x=0; x < (ssize_t) image->columns; x++) - { - double - distance, - distance_squared, - mean, - total_weight; - - PixelInfo - aggregate; - - register const Quantum - *magick_restrict r; - - if (GetPixelReadMask(image,p) == 0) - { - SetPixelBackgoundColor(enhance_image,q); - p+=GetPixelChannels(image); - q+=GetPixelChannels(enhance_image); - continue; - } - GetPixelInfo(image,&aggregate); - total_weight=0.0; - GetPixelInfoPixel(image,p+center,&pixel); - r=p; - EnhancePixel(5.0); EnhancePixel(8.0); EnhancePixel(10.0); - EnhancePixel(8.0); EnhancePixel(5.0); - r=p+GetPixelChannels(image)*(image->columns+4); - EnhancePixel(8.0); EnhancePixel(20.0); EnhancePixel(40.0); - EnhancePixel(20.0); EnhancePixel(8.0); - r=p+2*GetPixelChannels(image)*(image->columns+4); - EnhancePixel(10.0); EnhancePixel(40.0); EnhancePixel(80.0); - EnhancePixel(40.0); EnhancePixel(10.0); - r=p+3*GetPixelChannels(image)*(image->columns+4); - EnhancePixel(8.0); EnhancePixel(20.0); EnhancePixel(40.0); - EnhancePixel(20.0); EnhancePixel(8.0); - r=p+4*GetPixelChannels(image)*(image->columns+4); - EnhancePixel(5.0); EnhancePixel(8.0); EnhancePixel(10.0); - EnhancePixel(8.0); EnhancePixel(5.0); - pixel.red=((aggregate.red+total_weight/2.0)/total_weight); - pixel.green=((aggregate.green+total_weight/2.0)/total_weight); - pixel.blue=((aggregate.blue+total_weight/2.0)/total_weight); - pixel.black=((aggregate.black+total_weight/2.0)/total_weight); - pixel.alpha=((aggregate.alpha+total_weight/2.0)/total_weight); - SetPixelViaPixelInfo(image,&pixel,q); - p+=GetPixelChannels(image); - q+=GetPixelChannels(enhance_image); - } - if (SyncCacheViewAuthenticPixels(enhance_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_EnhanceImage) -#endif - proceed=SetImageProgress(image,EnhanceImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - enhance_view=DestroyCacheView(enhance_view); - image_view=DestroyCacheView(image_view); - if (status == MagickFalse) - enhance_image=DestroyImage(enhance_image); - return(enhance_image); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% E q u a l i z e I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% EqualizeImage() applies a histogram equalization to the image. -% -% The format of the EqualizeImage method is: -% -% MagickBooleanType EqualizeImage(Image *image,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType EqualizeImage(Image *image, - ExceptionInfo *exception) -{ -#define EqualizeImageTag "Equalize/Image" - - CacheView - *image_view; - - double - black[CompositePixelChannel+1], - *equalize_map, - *histogram, - *map, - white[CompositePixelChannel+1]; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - register ssize_t - i; - - ssize_t - y; - - /* - Allocate and initialize histogram arrays. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (AccelerateEqualizeImage(image,exception) != MagickFalse) - return(MagickTrue); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - equalize_map=(double *) AcquireQuantumMemory(MaxMap+1UL, - GetPixelChannels(image)*sizeof(*equalize_map)); - histogram=(double *) AcquireQuantumMemory(MaxMap+1UL,GetPixelChannels(image)* - sizeof(*histogram)); - map=(double *) AcquireQuantumMemory(MaxMap+1UL,GetPixelChannels(image)* - sizeof(*map)); - if ((equalize_map == (double *) NULL) || (histogram == (double *) NULL) || - (map == (double *) NULL)) - { - if (map != (double *) NULL) - map=(double *) RelinquishMagickMemory(map); - if (histogram != (double *) NULL) - histogram=(double *) RelinquishMagickMemory(histogram); - if (equalize_map != (double *) NULL) - equalize_map=(double *) RelinquishMagickMemory(equalize_map); - ThrowBinaryException(ResourceLimitError,"MemoryAllocationFailed", - image->filename); - } - /* - Form histogram. - */ - status=MagickTrue; - (void) ResetMagickMemory(histogram,0,(MaxMap+1)*GetPixelChannels(image)* - sizeof(*histogram)); - image_view=AcquireVirtualCacheView(image,exception); - for (y=0; y < (ssize_t) image->rows; y++) - { - register const Quantum - *magick_restrict p; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - p=GetCacheViewVirtualPixels(image_view,0,y,image->columns,1,exception); - if (p == (const Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - double intensity=GetPixelIntensity(image,p); - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - histogram[GetPixelChannels(image)*ScaleQuantumToMap(intensity)+i]++; - p+=GetPixelChannels(image); - } - } - image_view=DestroyCacheView(image_view); - /* - Integrate the histogram to get the equalization map. - */ - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - double - intensity; - - register ssize_t - j; - - intensity=0.0; - for (j=0; j <= (ssize_t) MaxMap; j++) - { - intensity+=histogram[GetPixelChannels(image)*j+i]; - map[GetPixelChannels(image)*j+i]=intensity; - } - } - (void) ResetMagickMemory(equalize_map,0,(MaxMap+1)*GetPixelChannels(image)* - sizeof(*equalize_map)); - (void) ResetMagickMemory(black,0,sizeof(*black)); - (void) ResetMagickMemory(white,0,sizeof(*white)); - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - register ssize_t - j; - - black[i]=map[i]; - white[i]=map[GetPixelChannels(image)*MaxMap+i]; - if (black[i] != white[i]) - for (j=0; j <= (ssize_t) MaxMap; j++) - equalize_map[GetPixelChannels(image)*j+i]=(double) - ScaleMapToQuantum((double) ((MaxMap*(map[ - GetPixelChannels(image)*j+i]-black[i]))/(white[i]-black[i]))); - } - histogram=(double *) RelinquishMagickMemory(histogram); - map=(double *) RelinquishMagickMemory(map); - if (image->storage_class == PseudoClass) - { - register ssize_t - j; - - /* - Equalize colormap. - */ - for (j=0; j < (ssize_t) image->colors; j++) - { - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - { - PixelChannel channel=GetPixelChannelChannel(image,RedPixelChannel); - if (black[channel] != white[channel]) - image->colormap[j].red=equalize_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].red))+ - channel]; - } - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - { - PixelChannel channel=GetPixelChannelChannel(image, - GreenPixelChannel); - if (black[channel] != white[channel]) - image->colormap[j].green=equalize_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].green))+ - channel]; - - } - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - { - PixelChannel channel=GetPixelChannelChannel(image,BluePixelChannel); - if (black[channel] != white[channel]) - image->colormap[j].blue=equalize_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].blue))+ - channel]; - } - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - { - PixelChannel channel=GetPixelChannelChannel(image, - AlphaPixelChannel); - if (black[channel] != white[channel]) - image->colormap[j].alpha=equalize_map[GetPixelChannels(image)* - ScaleQuantumToMap(ClampToQuantum(image->colormap[j].alpha))+ - channel]; - } - } - } - /* - Equalize image. - */ - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - j; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - for (j=0; j < (ssize_t) GetPixelChannels(image); j++) - { - PixelChannel channel=GetPixelChannelChannel(image,j); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if (((traits & UpdatePixelTrait) == 0) || (black[j] == white[j])) - continue; - q[j]=ClampToQuantum(equalize_map[GetPixelChannels(image)* - ScaleQuantumToMap(q[j])+j]); - } - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_EqualizeImage) -#endif - proceed=SetImageProgress(image,EqualizeImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - equalize_map=(double *) RelinquishMagickMemory(equalize_map); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% G a m m a I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% GammaImage() gamma-corrects a particular image channel. The same -% image viewed on different devices will have perceptual differences in the -% way the image's intensities are represented on the screen. Specify -% individual gamma levels for the red, green, and blue channels, or adjust -% all three with the gamma parameter. Values typically range from 0.8 to 2.3. -% -% You can also reduce the influence of a particular channel with a gamma -% value of 0. -% -% The format of the GammaImage method is: -% -% MagickBooleanType GammaImage(Image *image,const double gamma, -% ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o level: the image gamma as a string (e.g. 1.6,1.2,1.0). -% -% o gamma: the image gamma. -% -*/ - -static inline double gamma_pow(const double value,const double gamma) -{ - return(value < 0.0 ? value : pow(value,gamma)); -} - -MagickExport MagickBooleanType GammaImage(Image *image,const double gamma, - ExceptionInfo *exception) -{ -#define GammaCorrectImageTag "GammaCorrect/Image" - - CacheView - *image_view; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - Quantum - *gamma_map; - - register ssize_t - i; - - ssize_t - y; - - /* - Allocate and initialize gamma maps. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (gamma == 1.0) - return(MagickTrue); - gamma_map=(Quantum *) AcquireQuantumMemory(MaxMap+1UL,sizeof(*gamma_map)); - if (gamma_map == (Quantum *) NULL) - ThrowBinaryException(ResourceLimitError,"MemoryAllocationFailed", - image->filename); - (void) ResetMagickMemory(gamma_map,0,(MaxMap+1)*sizeof(*gamma_map)); - if (gamma != 0.0) - for (i=0; i <= (ssize_t) MaxMap; i++) - gamma_map[i]=ScaleMapToQuantum((double) (MaxMap*pow((double) i/ - MaxMap,1.0/gamma))); - if (image->storage_class == PseudoClass) - for (i=0; i < (ssize_t) image->colors; i++) - { - /* - Gamma-correct colormap. - */ -#if !defined(MAGICKCORE_HDRI_SUPPORT) - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].red=(double) gamma_map[ScaleQuantumToMap( - ClampToQuantum(image->colormap[i].red))]; - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].green=(double) gamma_map[ScaleQuantumToMap( - ClampToQuantum(image->colormap[i].green))]; - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].blue=(double) gamma_map[ScaleQuantumToMap( - ClampToQuantum(image->colormap[i].blue))]; - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].alpha=(double) gamma_map[ScaleQuantumToMap( - ClampToQuantum(image->colormap[i].alpha))]; -#else - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].red=QuantumRange*gamma_pow(QuantumScale* - image->colormap[i].red,1.0/gamma); - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].green=QuantumRange*gamma_pow(QuantumScale* - image->colormap[i].green,1.0/gamma); - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].blue=QuantumRange*gamma_pow(QuantumScale* - image->colormap[i].blue,1.0/gamma); - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].alpha=QuantumRange*gamma_pow(QuantumScale* - image->colormap[i].alpha,1.0/gamma); -#endif - } - /* - Gamma-correct image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - j; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - for (j=0; j < (ssize_t) GetPixelChannels(image); j++) - { - PixelChannel channel=GetPixelChannelChannel(image,j); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; -#if !defined(MAGICKCORE_HDRI_SUPPORT) - q[j]=gamma_map[ScaleQuantumToMap(q[j])]; -#else - q[j]=QuantumRange*gamma_pow(QuantumScale*q[j],1.0/gamma); -#endif - } - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_GammaImage) -#endif - proceed=SetImageProgress(image,GammaCorrectImageTag,progress++, - image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - gamma_map=(Quantum *) RelinquishMagickMemory(gamma_map); - if (image->gamma != 0.0) - image->gamma*=gamma; - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% G r a y s c a l e I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% GrayscaleImage() converts the image to grayscale. -% -% The format of the GrayscaleImage method is: -% -% MagickBooleanType GrayscaleImage(Image *image, -% const PixelIntensityMethod method ,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o method: the pixel intensity method. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType GrayscaleImage(Image *image, - const PixelIntensityMethod method,ExceptionInfo *exception) -{ -#define GrayscaleImageTag "Grayscale/Image" - - CacheView - *image_view; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - ssize_t - y; - - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (AccelerateGrayscaleImage(image,method,exception) != MagickFalse) - return(MagickTrue); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (image->storage_class == PseudoClass) - { - if (SyncImage(image,exception) == MagickFalse) - return(MagickFalse); - if (SetImageStorageClass(image,DirectClass,exception) == MagickFalse) - return(MagickFalse); - } - /* - Grayscale image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - MagickRealType - blue, - green, - red, - intensity; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - red=(MagickRealType) GetPixelRed(image,q); - green=(MagickRealType) GetPixelGreen(image,q); - blue=(MagickRealType) GetPixelBlue(image,q); - intensity=0.0; - switch (method) - { - case AveragePixelIntensityMethod: - { - intensity=(red+green+blue)/3.0; - break; - } - case BrightnessPixelIntensityMethod: - { - intensity=MagickMax(MagickMax(red,green),blue); - break; - } - case LightnessPixelIntensityMethod: - { - intensity=(MagickMin(MagickMin(red,green),blue)+ - MagickMax(MagickMax(red,green),blue))/2.0; - break; - } - case MSPixelIntensityMethod: - { - intensity=(MagickRealType) (((double) red*red+green*green+ - blue*blue)/3.0); - break; - } - case Rec601LumaPixelIntensityMethod: - { - if (image->colorspace == RGBColorspace) - { - red=EncodePixelGamma(red); - green=EncodePixelGamma(green); - blue=EncodePixelGamma(blue); - } - intensity=0.298839*red+0.586811*green+0.114350*blue; - break; - } - case Rec601LuminancePixelIntensityMethod: - { - if (image->colorspace == sRGBColorspace) - { - red=DecodePixelGamma(red); - green=DecodePixelGamma(green); - blue=DecodePixelGamma(blue); - } - intensity=0.298839*red+0.586811*green+0.114350*blue; - break; - } - case Rec709LumaPixelIntensityMethod: - default: - { - if (image->colorspace == RGBColorspace) - { - red=EncodePixelGamma(red); - green=EncodePixelGamma(green); - blue=EncodePixelGamma(blue); - } - intensity=0.212656*red+0.715158*green+0.072186*blue; - break; - } - case Rec709LuminancePixelIntensityMethod: - { - if (image->colorspace == sRGBColorspace) - { - red=DecodePixelGamma(red); - green=DecodePixelGamma(green); - blue=DecodePixelGamma(blue); - } - intensity=0.212656*red+0.715158*green+0.072186*blue; - break; - } - case RMSPixelIntensityMethod: - { - intensity=(MagickRealType) (sqrt((double) red*red+green*green+ - blue*blue)/sqrt(3.0)); - break; - } - } - SetPixelGray(image,ClampToQuantum(intensity),q); - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_GrayscaleImage) -#endif - proceed=SetImageProgress(image,GrayscaleImageTag,progress++, - image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - image->intensity=method; - image->type=GrayscaleType; - return(SetImageColorspace(image,GRAYColorspace,exception)); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% H a l d C l u t I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% HaldClutImage() applies a Hald color lookup table to the image. A Hald -% color lookup table is a 3-dimensional color cube mapped to 2 dimensions. -% Create it with the HALD coder. You can apply any color transformation to -% the Hald image and then use this method to apply the transform to the -% image. -% -% The format of the HaldClutImage method is: -% -% MagickBooleanType HaldClutImage(Image *image,Image *hald_image, -% ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image, which is replaced by indexed CLUT values -% -% o hald_image: the color lookup table image for replacement color values. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType HaldClutImage(Image *image, - const Image *hald_image,ExceptionInfo *exception) -{ -#define HaldClutImageTag "Clut/Image" - - typedef struct _HaldInfo - { - double - x, - y, - z; - } HaldInfo; - - CacheView - *hald_view, - *image_view; - - double - width; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - PixelInfo - zero; - - size_t - cube_size, - length, - level; - - ssize_t - y; - - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - assert(hald_image != (Image *) NULL); - assert(hald_image->signature == MagickCoreSignature); - if (SetImageStorageClass(image,DirectClass,exception) == MagickFalse) - return(MagickFalse); - if (image->alpha_trait == UndefinedPixelTrait) - (void) SetImageAlphaChannel(image,OpaqueAlphaChannel,exception); - /* - Hald clut image. - */ - status=MagickTrue; - progress=0; - length=(size_t) MagickMin((MagickRealType) hald_image->columns, - (MagickRealType) hald_image->rows); - for (level=2; (level*level*level) < length; level++) ; - level*=level; - cube_size=level*level; - width=(double) hald_image->columns; - GetPixelInfo(hald_image,&zero); - hald_view=AcquireVirtualCacheView(hald_image,exception); - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - double - offset; - - HaldInfo - point; - - PixelInfo - pixel, - pixel1, - pixel2, - pixel3, - pixel4; - - point.x=QuantumScale*(level-1.0)*GetPixelRed(image,q); - point.y=QuantumScale*(level-1.0)*GetPixelGreen(image,q); - point.z=QuantumScale*(level-1.0)*GetPixelBlue(image,q); - offset=point.x+level*floor(point.y)+cube_size*floor(point.z); - point.x-=floor(point.x); - point.y-=floor(point.y); - point.z-=floor(point.z); - pixel1=zero; - (void) InterpolatePixelInfo(image,hald_view,image->interpolate, - fmod(offset,width),floor(offset/width),&pixel1,exception); - pixel2=zero; - (void) InterpolatePixelInfo(image,hald_view,image->interpolate, - fmod(offset+level,width),floor((offset+level)/width),&pixel2,exception); - pixel3=zero; - CompositePixelInfoAreaBlend(&pixel1,pixel1.alpha,&pixel2,pixel2.alpha, - point.y,&pixel3); - offset+=cube_size; - (void) InterpolatePixelInfo(image,hald_view,image->interpolate, - fmod(offset,width),floor(offset/width),&pixel1,exception); - (void) InterpolatePixelInfo(image,hald_view,image->interpolate, - fmod(offset+level,width),floor((offset+level)/width),&pixel2,exception); - pixel4=zero; - CompositePixelInfoAreaBlend(&pixel1,pixel1.alpha,&pixel2,pixel2.alpha, - point.y,&pixel4); - pixel=zero; - CompositePixelInfoAreaBlend(&pixel3,pixel3.alpha,&pixel4,pixel4.alpha, - point.z,&pixel); - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - SetPixelRed(image,ClampToQuantum(pixel.red),q); - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - SetPixelGreen(image,ClampToQuantum(pixel.green),q); - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - SetPixelBlue(image,ClampToQuantum(pixel.blue),q); - if (((GetPixelBlackTraits(image) & UpdatePixelTrait) != 0) && - (image->colorspace == CMYKColorspace)) - SetPixelBlack(image,ClampToQuantum(pixel.black),q); - if (((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) && - (image->alpha_trait != UndefinedPixelTrait)) - SetPixelAlpha(image,ClampToQuantum(pixel.alpha),q); - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_HaldClutImage) -#endif - proceed=SetImageProgress(image,HaldClutImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - hald_view=DestroyCacheView(hald_view); - image_view=DestroyCacheView(image_view); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% L e v e l I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% LevelImage() adjusts the levels of a particular image channel by -% scaling the colors falling between specified white and black points to -% the full available quantum range. -% -% The parameters provided represent the black, and white points. The black -% point specifies the darkest color in the image. Colors darker than the -% black point are set to zero. White point specifies the lightest color in -% the image. Colors brighter than the white point are set to the maximum -% quantum value. -% -% If a '!' flag is given, map black and white colors to the given levels -% rather than mapping those levels to black and white. See -% LevelizeImage() below. -% -% Gamma specifies a gamma correction to apply to the image. -% -% The format of the LevelImage method is: -% -% MagickBooleanType LevelImage(Image *image,const double black_point, -% const double white_point,const double gamma,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o black_point: The level to map zero (black) to. -% -% o white_point: The level to map QuantumRange (white) to. -% -% o exception: return any errors or warnings in this structure. -% -*/ - -static inline double LevelPixel(const double black_point, - const double white_point,const double gamma,const double pixel) -{ - double - level_pixel, - scale; - - scale=(white_point != black_point) ? 1.0/(white_point-black_point) : 1.0; - level_pixel=QuantumRange*gamma_pow(scale*((double) pixel-black_point), - 1.0/gamma); - return(level_pixel); -} - -MagickExport MagickBooleanType LevelImage(Image *image,const double black_point, - const double white_point,const double gamma,ExceptionInfo *exception) -{ -#define LevelImageTag "Level/Image" - - CacheView - *image_view; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - register ssize_t - i; - - ssize_t - y; - - /* - Allocate and initialize levels map. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (image->storage_class == PseudoClass) - for (i=0; i < (ssize_t) image->colors; i++) - { - /* - Level colormap. - */ - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].red=(double) ClampToQuantum(LevelPixel(black_point, - white_point,gamma,image->colormap[i].red)); - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].green=(double) ClampToQuantum(LevelPixel(black_point, - white_point,gamma,image->colormap[i].green)); - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].blue=(double) ClampToQuantum(LevelPixel(black_point, - white_point,gamma,image->colormap[i].blue)); - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].alpha=(double) ClampToQuantum(LevelPixel(black_point, - white_point,gamma,image->colormap[i].alpha)); - } - /* - Level image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - j; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - for (j=0; j < (ssize_t) GetPixelChannels(image); j++) - { - PixelChannel channel=GetPixelChannelChannel(image,j); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; - q[j]=ClampToQuantum(LevelPixel(black_point,white_point,gamma, - (double) q[j])); - } - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_LevelImage) -#endif - proceed=SetImageProgress(image,LevelImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - (void) ClampImage(image,exception); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% L e v e l i z e I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% LevelizeImage() applies the reversed LevelImage() operation to just -% the specific channels specified. It compresses the full range of color -% values, so that they lie between the given black and white points. Gamma is -% applied before the values are mapped. -% -% LevelizeImage() can be called with by using a +level command line -% API option, or using a '!' on a -level or LevelImage() geometry string. -% -% It can be used to de-contrast a greyscale image to the exact levels -% specified. Or by using specific levels for each channel of an image you -% can convert a gray-scale image to any linear color gradient, according to -% those levels. -% -% The format of the LevelizeImage method is: -% -% MagickBooleanType LevelizeImage(Image *image,const double black_point, -% const double white_point,const double gamma,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o black_point: The level to map zero (black) to. -% -% o white_point: The level to map QuantumRange (white) to. -% -% o gamma: adjust gamma by this factor before mapping values. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType LevelizeImage(Image *image, - const double black_point,const double white_point,const double gamma, - ExceptionInfo *exception) -{ -#define LevelizeImageTag "Levelize/Image" -#define LevelizeValue(x) ClampToQuantum(((MagickRealType) gamma_pow((double) \ - (QuantumScale*(x)),gamma))*(white_point-black_point)+black_point) - - CacheView - *image_view; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - register ssize_t - i; - - ssize_t - y; - - /* - Allocate and initialize levels map. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (image->storage_class == PseudoClass) - for (i=0; i < (ssize_t) image->colors; i++) - { - /* - Level colormap. - */ - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].red=(double) LevelizeValue(image->colormap[i].red); - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].green=(double) LevelizeValue( - image->colormap[i].green); - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].blue=(double) LevelizeValue(image->colormap[i].blue); - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].alpha=(double) LevelizeValue( - image->colormap[i].alpha); - } - /* - Level image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - j; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - for (j=0; j < (ssize_t) GetPixelChannels(image); j++) - { - PixelChannel channel=GetPixelChannelChannel(image,j); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; - q[j]=LevelizeValue(q[j]); - } - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_LevelizeImage) -#endif - proceed=SetImageProgress(image,LevelizeImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% L e v e l I m a g e C o l o r s % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% LevelImageColors() maps the given color to "black" and "white" values, -% linearly spreading out the colors, and level values on a channel by channel -% bases, as per LevelImage(). The given colors allows you to specify -% different level ranges for each of the color channels separately. -% -% If the boolean 'invert' is set true the image values will modifyed in the -% reverse direction. That is any existing "black" and "white" colors in the -% image will become the color values given, with all other values compressed -% appropriatally. This effectivally maps a greyscale gradient into the given -% color gradient. -% -% The format of the LevelImageColors method is: -% -% MagickBooleanType LevelImageColors(Image *image, -% const PixelInfo *black_color,const PixelInfo *white_color, -% const MagickBooleanType invert,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o black_color: The color to map black to/from -% -% o white_point: The color to map white to/from -% -% o invert: if true map the colors (levelize), rather than from (level) -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType LevelImageColors(Image *image, - const PixelInfo *black_color,const PixelInfo *white_color, - const MagickBooleanType invert,ExceptionInfo *exception) -{ - ChannelType - channel_mask; - - MagickStatusType - status; - - /* - Allocate and initialize levels map. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if ((IsGrayColorspace(image->colorspace) != MagickFalse) && - ((IsGrayColorspace(black_color->colorspace) == MagickFalse) || - (IsGrayColorspace(white_color->colorspace) == MagickFalse))) - (void) SetImageColorspace(image,sRGBColorspace,exception); - status=MagickTrue; - if (invert == MagickFalse) - { - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - { - channel_mask=SetImageChannelMask(image,RedChannel); - status&=LevelImage(image,black_color->red,white_color->red,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - { - channel_mask=SetImageChannelMask(image,GreenChannel); - status&=LevelImage(image,black_color->green,white_color->green,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - { - channel_mask=SetImageChannelMask(image,BlueChannel); - status&=LevelImage(image,black_color->blue,white_color->blue,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if (((GetPixelBlackTraits(image) & UpdatePixelTrait) != 0) && - (image->colorspace == CMYKColorspace)) - { - channel_mask=SetImageChannelMask(image,BlackChannel); - status&=LevelImage(image,black_color->black,white_color->black,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if (((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) && - (image->alpha_trait != UndefinedPixelTrait)) - { - channel_mask=SetImageChannelMask(image,AlphaChannel); - status&=LevelImage(image,black_color->alpha,white_color->alpha,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - } - else - { - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - { - channel_mask=SetImageChannelMask(image,RedChannel); - status&=LevelizeImage(image,black_color->red,white_color->red,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - { - channel_mask=SetImageChannelMask(image,GreenChannel); - status&=LevelizeImage(image,black_color->green,white_color->green,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - { - channel_mask=SetImageChannelMask(image,BlueChannel); - status&=LevelizeImage(image,black_color->blue,white_color->blue,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if (((GetPixelBlackTraits(image) & UpdatePixelTrait) != 0) && - (image->colorspace == CMYKColorspace)) - { - channel_mask=SetImageChannelMask(image,BlackChannel); - status&=LevelizeImage(image,black_color->black,white_color->black,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - if (((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) && - (image->alpha_trait != UndefinedPixelTrait)) - { - channel_mask=SetImageChannelMask(image,AlphaChannel); - status&=LevelizeImage(image,black_color->alpha,white_color->alpha,1.0, - exception); - (void) SetImageChannelMask(image,channel_mask); - } - } - return(status != 0 ? MagickTrue : MagickFalse); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% L i n e a r S t r e t c h I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% LinearStretchImage() discards any pixels below the black point and above -% the white point and levels the remaining pixels. -% -% The format of the LinearStretchImage method is: -% -% MagickBooleanType LinearStretchImage(Image *image, -% const double black_point,const double white_point, -% ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o black_point: the black point. -% -% o white_point: the white point. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType LinearStretchImage(Image *image, - const double black_point,const double white_point,ExceptionInfo *exception) -{ -#define LinearStretchImageTag "LinearStretch/Image" - - CacheView - *image_view; - - double - *histogram, - intensity; - - MagickBooleanType - status; - - ssize_t - black, - white, - y; - - /* - Allocate histogram and linear map. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - histogram=(double *) AcquireQuantumMemory(MaxMap+1UL,sizeof(*histogram)); - if (histogram == (double *) NULL) - ThrowBinaryException(ResourceLimitError,"MemoryAllocationFailed", - image->filename); - /* - Form histogram. - */ - (void) ResetMagickMemory(histogram,0,(MaxMap+1)*sizeof(*histogram)); - image_view=AcquireVirtualCacheView(image,exception); - for (y=0; y < (ssize_t) image->rows; y++) - { - register const Quantum - *magick_restrict p; - - register ssize_t - x; - - p=GetCacheViewVirtualPixels(image_view,0,y,image->columns,1,exception); - if (p == (const Quantum *) NULL) - break; - for (x=0; x < (ssize_t) image->columns; x++) - { - intensity=GetPixelIntensity(image,p); - histogram[ScaleQuantumToMap(ClampToQuantum(intensity))]++; - p+=GetPixelChannels(image); - } - } - image_view=DestroyCacheView(image_view); - /* - Find the histogram boundaries by locating the black and white point levels. - */ - intensity=0.0; - for (black=0; black < (ssize_t) MaxMap; black++) - { - intensity+=histogram[black]; - if (intensity >= black_point) - break; - } - intensity=0.0; - for (white=(ssize_t) MaxMap; white != 0; white--) - { - intensity+=histogram[white]; - if (intensity >= white_point) - break; - } - histogram=(double *) RelinquishMagickMemory(histogram); - status=LevelImage(image,(double) ScaleMapToQuantum((MagickRealType) black), - (double) ScaleMapToQuantum((MagickRealType) white),1.0,exception); - return(status); -} - - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% M o d u l a t e I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% ModulateImage() lets you control the brightness, saturation, and hue -% of an image. Modulate represents the brightness, saturation, and hue -% as one parameter (e.g. 90,150,100). If the image colorspace is HSL, the -% modulation is lightness, saturation, and hue. For HWB, use blackness, -% whiteness, and hue. And for HCL, use chrome, luma, and hue. -% -% The format of the ModulateImage method is: -% -% MagickBooleanType ModulateImage(Image *image,const char *modulate, -% ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o modulate: Define the percent change in brightness, saturation, and hue. -% -% o exception: return any errors or warnings in this structure. -% -*/ - -static inline void ModulateHCL(const double percent_hue, - const double percent_chroma,const double percent_luma,double *red, - double *green,double *blue) -{ - double - hue, - luma, - chroma; - - /* - Increase or decrease color luma, chroma, or hue. - */ - ConvertRGBToHCL(*red,*green,*blue,&hue,&chroma,&luma); - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue > 1.0) - hue-=1.0; - chroma*=0.01*percent_chroma; - luma*=0.01*percent_luma; - ConvertHCLToRGB(hue,chroma,luma,red,green,blue); -} - -static inline void ModulateHCLp(const double percent_hue, - const double percent_chroma,const double percent_luma,double *red, - double *green,double *blue) -{ - double - hue, - luma, - chroma; - - /* - Increase or decrease color luma, chroma, or hue. - */ - ConvertRGBToHCLp(*red,*green,*blue,&hue,&chroma,&luma); - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue > 1.0) - hue-=1.0; - chroma*=0.01*percent_chroma; - luma*=0.01*percent_luma; - ConvertHCLpToRGB(hue,chroma,luma,red,green,blue); -} - -static inline void ModulateHSB(const double percent_hue, - const double percent_saturation,const double percent_brightness,double *red, - double *green,double *blue) -{ - double - brightness, - hue, - saturation; - - /* - Increase or decrease color brightness, saturation, or hue. - */ - ConvertRGBToHSB(*red,*green,*blue,&hue,&saturation,&brightness); - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue > 1.0) - hue-=1.0; - saturation*=0.01*percent_saturation; - brightness*=0.01*percent_brightness; - ConvertHSBToRGB(hue,saturation,brightness,red,green,blue); -} - -static inline void ModulateHSI(const double percent_hue, - const double percent_saturation,const double percent_intensity,double *red, - double *green,double *blue) -{ - double - intensity, - hue, - saturation; - - /* - Increase or decrease color intensity, saturation, or hue. - */ - ConvertRGBToHSI(*red,*green,*blue,&hue,&saturation,&intensity); - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue > 1.0) - hue-=1.0; - saturation*=0.01*percent_saturation; - intensity*=0.01*percent_intensity; - ConvertHSIToRGB(hue,saturation,intensity,red,green,blue); -} - -static inline void ModulateHSL(const double percent_hue, - const double percent_saturation,const double percent_lightness,double *red, - double *green,double *blue) -{ - double - hue, - lightness, - saturation; - - /* - Increase or decrease color lightness, saturation, or hue. - */ - ConvertRGBToHSL(*red,*green,*blue,&hue,&saturation,&lightness); - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue >= 1.0) - hue-=1.0; - saturation*=0.01*percent_saturation; - lightness*=0.01*percent_lightness; - ConvertHSLToRGB(hue,saturation,lightness,red,green,blue); -} - -static inline void ModulateHSV(const double percent_hue, - const double percent_saturation,const double percent_value,double *red, - double *green,double *blue) -{ - double - hue, - saturation, - value; - - /* - Increase or decrease color value, saturation, or hue. - */ - ConvertRGBToHSV(*red,*green,*blue,&hue,&saturation,&value); - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue >= 1.0) - hue-=1.0; - saturation*=0.01*percent_saturation; - value*=0.01*percent_value; - ConvertHSVToRGB(hue,saturation,value,red,green,blue); -} - -static inline void ModulateHWB(const double percent_hue, - const double percent_whiteness,const double percent_blackness,double *red, - double *green,double *blue) -{ - double - blackness, - hue, - whiteness; - - /* - Increase or decrease color blackness, whiteness, or hue. - */ - ConvertRGBToHWB(*red,*green,*blue,&hue,&whiteness,&blackness); - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue >= 1.0) - hue-=1.0; - blackness*=0.01*percent_blackness; - whiteness*=0.01*percent_whiteness; - ConvertHWBToRGB(hue,whiteness,blackness,red,green,blue); -} - -static inline void ModulateLCHab(const double percent_luma, - const double percent_chroma,const double percent_hue,double *red, - double *green,double *blue) -{ - double - hue, - luma, - chroma; - - /* - Increase or decrease color luma, chroma, or hue. - */ - ConvertRGBToLCHab(*red,*green,*blue,&luma,&chroma,&hue); - luma*=0.01*percent_luma; - chroma*=0.01*percent_chroma; - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue >= 1.0) - hue-=1.0; - ConvertLCHabToRGB(luma,chroma,hue,red,green,blue); -} - -static inline void ModulateLCHuv(const double percent_luma, - const double percent_chroma,const double percent_hue,double *red, - double *green,double *blue) -{ - double - hue, - luma, - chroma; - - /* - Increase or decrease color luma, chroma, or hue. - */ - ConvertRGBToLCHuv(*red,*green,*blue,&luma,&chroma,&hue); - luma*=0.01*percent_luma; - chroma*=0.01*percent_chroma; - hue+=0.5*(0.01*percent_hue-1.0); - while (hue < 0.0) - hue+=1.0; - while (hue >= 1.0) - hue-=1.0; - ConvertLCHuvToRGB(luma,chroma,hue,red,green,blue); -} - -MagickExport MagickBooleanType ModulateImage(Image *image,const char *modulate, - ExceptionInfo *exception) -{ -#define ModulateImageTag "Modulate/Image" - - CacheView - *image_view; - - ColorspaceType - colorspace; - - const char - *artifact; - - double - percent_brightness, - percent_hue, - percent_saturation; - - GeometryInfo - geometry_info; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - MagickStatusType - flags; - - register ssize_t - i; - - ssize_t - y; - - /* - Initialize modulate table. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (modulate == (char *) NULL) - return(MagickFalse); - if (IssRGBCompatibleColorspace(image->colorspace) == MagickFalse) - (void) SetImageColorspace(image,sRGBColorspace,exception); - flags=ParseGeometry(modulate,&geometry_info); - percent_brightness=geometry_info.rho; - percent_saturation=geometry_info.sigma; - if ((flags & SigmaValue) == 0) - percent_saturation=100.0; - percent_hue=geometry_info.xi; - if ((flags & XiValue) == 0) - percent_hue=100.0; - colorspace=UndefinedColorspace; - artifact=GetImageArtifact(image,"modulate:colorspace"); - if (artifact != (const char *) NULL) - colorspace=(ColorspaceType) ParseCommandOption(MagickColorspaceOptions, - MagickFalse,artifact); - if (image->storage_class == PseudoClass) - for (i=0; i < (ssize_t) image->colors; i++) - { - double - blue, - green, - red; - - /* - Modulate image colormap. - */ - red=(double) image->colormap[i].red; - green=(double) image->colormap[i].green; - blue=(double) image->colormap[i].blue; - switch (colorspace) - { - case HCLColorspace: - { - ModulateHCL(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HCLpColorspace: - { - ModulateHCLp(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HSBColorspace: - { - ModulateHSB(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HSIColorspace: - { - ModulateHSI(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HSLColorspace: - default: - { - ModulateHSL(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HSVColorspace: - { - ModulateHSV(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HWBColorspace: - { - ModulateHWB(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case LCHColorspace: - case LCHabColorspace: - { - ModulateLCHab(percent_brightness,percent_saturation,percent_hue, - &red,&green,&blue); - break; - } - case LCHuvColorspace: - { - ModulateLCHuv(percent_brightness,percent_saturation,percent_hue, - &red,&green,&blue); - break; - } - } - image->colormap[i].red=red; - image->colormap[i].green=green; - image->colormap[i].blue=blue; - } - /* - Modulate image. - */ - if(AccelerateModulateImage(image,percent_brightness,percent_hue, - percent_saturation,colorspace,exception) != MagickFalse) - return(MagickTrue); - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - double - blue, - green, - red; - - red=(double) GetPixelRed(image,q); - green=(double) GetPixelGreen(image,q); - blue=(double) GetPixelBlue(image,q); - switch (colorspace) - { - case HCLColorspace: - { - ModulateHCL(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HCLpColorspace: - { - ModulateHCLp(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HSBColorspace: - { - ModulateHSB(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HSLColorspace: - default: - { - ModulateHSL(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HSVColorspace: - { - ModulateHSV(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case HWBColorspace: - { - ModulateHWB(percent_hue,percent_saturation,percent_brightness, - &red,&green,&blue); - break; - } - case LCHabColorspace: - { - ModulateLCHab(percent_brightness,percent_saturation,percent_hue, - &red,&green,&blue); - break; - } - case LCHColorspace: - case LCHuvColorspace: - { - ModulateLCHuv(percent_brightness,percent_saturation,percent_hue, - &red,&green,&blue); - break; - } - } - SetPixelRed(image,ClampToQuantum(red),q); - SetPixelGreen(image,ClampToQuantum(green),q); - SetPixelBlue(image,ClampToQuantum(blue),q); - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_ModulateImage) -#endif - proceed=SetImageProgress(image,ModulateImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% N e g a t e I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% NegateImage() negates the colors in the reference image. The grayscale -% option means that only grayscale values within the image are negated. -% -% The format of the NegateImage method is: -% -% MagickBooleanType NegateImage(Image *image, -% const MagickBooleanType grayscale,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o grayscale: If MagickTrue, only negate grayscale pixels within the image. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType NegateImage(Image *image, - const MagickBooleanType grayscale,ExceptionInfo *exception) -{ -#define NegateImageTag "Negate/Image" - - CacheView - *image_view; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - register ssize_t - i; - - ssize_t - y; - - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - if (image->storage_class == PseudoClass) - for (i=0; i < (ssize_t) image->colors; i++) - { - /* - Negate colormap. - */ - if( grayscale != MagickFalse ) - if ((image->colormap[i].red != image->colormap[i].green) || - (image->colormap[i].green != image->colormap[i].blue)) - continue; - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].red=QuantumRange-image->colormap[i].red; - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].green=QuantumRange-image->colormap[i].green; - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].blue=QuantumRange-image->colormap[i].blue; - } - /* - Negate image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); - if( grayscale != MagickFalse ) - { - for (y=0; y < (ssize_t) image->rows; y++) - { - MagickBooleanType - sync; - - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1, - exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - j; - - if ((GetPixelReadMask(image,q) == 0) || - IsPixelGray(image,q) != MagickFalse) - { - q+=GetPixelChannels(image); - continue; - } - for (j=0; j < (ssize_t) GetPixelChannels(image); j++) - { - PixelChannel channel=GetPixelChannelChannel(image,j); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; - q[j]=QuantumRange-q[j]; - } - q+=GetPixelChannels(image); - } - sync=SyncCacheViewAuthenticPixels(image_view,exception); - if (sync == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_NegateImage) -#endif - proceed=SetImageProgress(image,NegateImageTag,progress++, - image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - return(MagickTrue); - } - /* - Negate image. - */ -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - j; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - for (j=0; j < (ssize_t) GetPixelChannels(image); j++) - { - PixelChannel channel=GetPixelChannelChannel(image,j); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; - q[j]=QuantumRange-q[j]; - } - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_NegateImage) -#endif - proceed=SetImageProgress(image,NegateImageTag,progress++,image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - return(status); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% N o r m a l i z e I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% The NormalizeImage() method enhances the contrast of a color image by -% mapping the darkest 2 percent of all pixel to black and the brightest -% 1 percent to white. -% -% The format of the NormalizeImage method is: -% -% MagickBooleanType NormalizeImage(Image *image,ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o exception: return any errors or warnings in this structure. -% -*/ -MagickExport MagickBooleanType NormalizeImage(Image *image, - ExceptionInfo *exception) -{ - double - black_point, - white_point; - - black_point=(double) image->columns*image->rows*0.0015; - white_point=(double) image->columns*image->rows*0.9995; - return(ContrastStretchImage(image,black_point,white_point,exception)); -} - -/* -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% % -% % -% % -% S i g m o i d a l C o n t r a s t I m a g e % -% % -% % -% % -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% SigmoidalContrastImage() adjusts the contrast of an image with a non-linear -% sigmoidal contrast algorithm. Increase the contrast of the image using a -% sigmoidal transfer function without saturating highlights or shadows. -% Contrast indicates how much to increase the contrast (0 is none; 3 is -% typical; 20 is pushing it); mid-point indicates where midtones fall in the -% resultant image (0 is white; 50% is middle-gray; 100% is black). Set -% sharpen to MagickTrue to increase the image contrast otherwise the contrast -% is reduced. -% -% The format of the SigmoidalContrastImage method is: -% -% MagickBooleanType SigmoidalContrastImage(Image *image, -% const MagickBooleanType sharpen,const char *levels, -% ExceptionInfo *exception) -% -% A description of each parameter follows: -% -% o image: the image. -% -% o sharpen: Increase or decrease image contrast. -% -% o contrast: strength of the contrast, the larger the number the more -% 'threshold-like' it becomes. -% -% o midpoint: midpoint of the function as a color value 0 to QuantumRange. -% -% o exception: return any errors or warnings in this structure. -% -*/ - -/* - ImageMagick 6 has a version of this function which uses LUTs. -*/ - -/* - Sigmoidal function Sigmoidal with inflexion point moved to b and "slope - constant" set to a. - - The first version, based on the hyperbolic tangent tanh, when combined with - the scaling step, is an exact arithmetic clone of the the sigmoid function - based on the logistic curve. The equivalence is based on the identity - - 1/(1+exp(-t)) = (1+tanh(t/2))/2 - - (http://de.wikipedia.org/wiki/Sigmoidfunktion) and the fact that the - scaled sigmoidal derivation is invariant under affine transformations of - the ordinate. - - The tanh version is almost certainly more accurate and cheaper. The 0.5 - factor in the argument is to clone the legacy ImageMagick behavior. The - reason for making the define depend on atanh even though it only uses tanh - has to do with the construction of the inverse of the scaled sigmoidal. -*/ -#if defined(MAGICKCORE_HAVE_ATANH) -#define Sigmoidal(a,b,x) ( tanh((0.5*(a))*((x)-(b))) ) -#else -#define Sigmoidal(a,b,x) ( 1.0/(1.0+exp((a)*((b)-(x)))) ) -#endif -/* - Scaled sigmoidal function: - - ( Sigmoidal(a,b,x) - Sigmoidal(a,b,0) ) / - ( Sigmoidal(a,b,1) - Sigmoidal(a,b,0) ) - - See http://osdir.com/ml/video.image-magick.devel/2005-04/msg00006.html and - http://www.cs.dartmouth.edu/farid/downloads/tutorials/fip.pdf. The limit - of ScaledSigmoidal as a->0 is the identity, but a=0 gives a division by - zero. This is fixed below by exiting immediately when contrast is small, - leaving the image (or colormap) unmodified. This appears to be safe because - the series expansion of the logistic sigmoidal function around x=b is - - 1/2-a*(b-x)/4+... - - so that the key denominator s(1)-s(0) is about a/4 (a/2 with tanh). -*/ -#define ScaledSigmoidal(a,b,x) ( \ - (Sigmoidal((a),(b),(x))-Sigmoidal((a),(b),0.0)) / \ - (Sigmoidal((a),(b),1.0)-Sigmoidal((a),(b),0.0)) ) -/* - Inverse of ScaledSigmoidal, used for +sigmoidal-contrast. Because b - may be 0 or 1, the argument of the hyperbolic tangent (resp. logistic - sigmoidal) may be outside of the interval (-1,1) (resp. (0,1)), even - when creating a LUT from in gamut values, hence the branching. In - addition, HDRI may have out of gamut values. - InverseScaledSigmoidal is not a two-sided inverse of ScaledSigmoidal: - It is only a right inverse. This is unavoidable. -*/ -static inline double InverseScaledSigmoidal(const double a,const double b, - const double x) -{ - const double sig0=Sigmoidal(a,b,0.0); - const double sig1=Sigmoidal(a,b,1.0); - const double argument=(sig1-sig0)*x+sig0; - const double clamped= - ( -#if defined(MAGICKCORE_HAVE_ATANH) - argument < -1+MagickEpsilon - ? - -1+MagickEpsilon - : - ( argument > 1-MagickEpsilon ? 1-MagickEpsilon : argument ) - ); - return(b+(2.0/a)*atanh(clamped)); -#else - argument < MagickEpsilon - ? - MagickEpsilon - : - ( argument > 1-MagickEpsilon ? 1-MagickEpsilon : argument ) - ); - return(b-log(1.0/clamped-1.0)/a); -#endif -} - -MagickExport MagickBooleanType SigmoidalContrastImage(Image *image, - const MagickBooleanType sharpen,const double contrast,const double midpoint, - ExceptionInfo *exception) -{ -#define SigmoidalContrastImageTag "SigmoidalContrast/Image" -#define ScaledSig(x) ( ClampToQuantum(QuantumRange* \ - ScaledSigmoidal(contrast,QuantumScale*midpoint,QuantumScale*(x))) ) -#define InverseScaledSig(x) ( ClampToQuantum(QuantumRange* \ - InverseScaledSigmoidal(contrast,QuantumScale*midpoint,QuantumScale*(x))) ) - - CacheView - *image_view; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - ssize_t - y; - - /* - Convenience macros. - */ - assert(image != (Image *) NULL); - assert(image->signature == MagickCoreSignature); - if (image->debug != MagickFalse) - (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); - /* - Side effect: may clamp values unless contraststorage_class == PseudoClass) - { - register ssize_t - i; - - if( sharpen != MagickFalse ) - for (i=0; i < (ssize_t) image->colors; i++) - { - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].red=(MagickRealType) ScaledSig( - image->colormap[i].red); - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].green=(MagickRealType) ScaledSig( - image->colormap[i].green); - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].blue=(MagickRealType) ScaledSig( - image->colormap[i].blue); - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].alpha=(MagickRealType) ScaledSig( - image->colormap[i].alpha); - } - else - for (i=0; i < (ssize_t) image->colors; i++) - { - if ((GetPixelRedTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].red=(MagickRealType) InverseScaledSig( - image->colormap[i].red); - if ((GetPixelGreenTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].green=(MagickRealType) InverseScaledSig( - image->colormap[i].green); - if ((GetPixelBlueTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].blue=(MagickRealType) InverseScaledSig( - image->colormap[i].blue); - if ((GetPixelAlphaTraits(image) & UpdatePixelTrait) != 0) - image->colormap[i].alpha=(MagickRealType) InverseScaledSig( - image->colormap[i].alpha); - } - } - /* - Sigmoidal-contrast enhance image. - */ - status=MagickTrue; - progress=0; - image_view=AcquireAuthenticCacheView(image,exception); -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp parallel for schedule(static,4) shared(progress,status) \ - magick_threads(image,image,image->rows,1) -#endif - for (y=0; y < (ssize_t) image->rows; y++) - { - register Quantum - *magick_restrict q; - - register ssize_t - x; - - if (status == MagickFalse) - continue; - q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception); - if (q == (Quantum *) NULL) - { - status=MagickFalse; - continue; - } - for (x=0; x < (ssize_t) image->columns; x++) - { - register ssize_t - i; - - if (GetPixelReadMask(image,q) == 0) - { - q+=GetPixelChannels(image); - continue; - } - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - PixelChannel channel=GetPixelChannelChannel(image,i); - PixelTrait traits=GetPixelChannelTraits(image,channel); - if ((traits & UpdatePixelTrait) == 0) - continue; - if( sharpen != MagickFalse ) - q[i]=ScaledSig(q[i]); - else - q[i]=InverseScaledSig(q[i]); - } - q+=GetPixelChannels(image); - } - if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) NULL) - { - MagickBooleanType - proceed; - -#if defined(MAGICKCORE_OPENMP_SUPPORT) - #pragma omp critical (MagickCore_SigmoidalContrastImage) -#endif - proceed=SetImageProgress(image,SigmoidalContrastImageTag,progress++, - image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } - } - image_view=DestroyCacheView(image_view); - return(status); -} diff --git a/ImageMagick-7.0.0-0/www/ImageMagickObject.html b/ImageMagick-7.0.0-0/www/ImageMagickObject.html deleted file mode 100644 index ae5b92907..000000000 --- a/ImageMagick-7.0.0-0/www/ImageMagickObject.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - - - - ImageMagick: Install the ImageMagickObject COM+ Component - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
-

Build ImageMagickObject From Source

- -

The ImageMagickObject is a COM+ compatible component that can be invoked from any language capable of using COM objects. The intended use is for Windows Scripting Host VBS scripts and Visual Basic, but it is also available from to C++, ASP, and other languages like Delphi, Perl and PHP.

- -

The ImageMagickObject COM+ component provides access to the compare, convert, composite, mogrify, identify, montage, and stream tools, efficiently executing them as part of your process, rather than as external programs. The way you use it is exactly the same. You pass it a list of strings including filenames and various options and it does the job. In fact, you can take any existing batch scripts that use the command line tools and translate them into the equivalent calls to the COM+ object in a matter of minutes. Beyond that, there is also a way to pass in and retrieve images in memory in the form of standard smart arrays (byte arrays). Samples are provided, to show both the simple and more elaborate forms of access.

- -

ImageMagick provides a statically-built ImageMagick object as part of its Windows installation package. When this package is installed, ImageMagickObject and its sample programs are installed to this path:

- -
-  c:\Program Files\ImageMagick-7.0.0-Q16\ImageMagickObject
-
- -

The ImageMagickObject is registered if the checkbox, Register ImageMagickObject, is checked at install time.

- -

To execute the sample program from the Windows Command Shell, type:

- -
-cscript SimpleTest.vbs
-
- -

Since the ImageMagick utility command line parsers are incorporated within ImageMagickObject, please refer to the command-line tools discussion to learn how to use it. The sample VBS scripts show how the object should be called and used and have lots of comments.

- -

C++ programmers should have a look at the MagickCMD.cpp command line utility for an example of how to call the object from C++. The object requires a variable size list of BSTR's to emulate the command line argc, argv style calling conventions of the COM component which is more complex in C++ then in VBS or VB.

- -

MagickCMD is a C++ sample, but it also serves as a replacement for all the other command line utilities in most applications. Instead of using convert xxxx yyyy you can use MagickCMD convert xxxx yyyy instead. MagickCMD calls the COM object to accomplish the designated task. This small tight combination replaces the entire usual binary distribution in just a few mebibytes.

- -

Build ImageMagickObject From Source

- -

The source code for ImageMagickObject is available from the ImageMagick GIT repository, or as part of the Windows source distribution. Once the source code has been retrieved and extracted, the source for ImageMagickObject is the directory ImageMagick\contrib\win32\ATL7ImageMagickObject, however, ImageMagick itself must be built using the static-multithread (VisualStaticMT) build configuration. Building ImageMagickObject requires Microsoft Visual C++ 7.0 as delivered with Microsoft's Visual Studio .NET package. See the Windows compilation instructions to get ImageMagick itself built before building the ImageMagick COM+ component.

- -

Once the VisualStaticMT project has been built, build the ImageMagickObject with this procedure:

- -
-cd ImageMagick/contrib/win32/ATL7/ImageMagickObject
-BuildImageMagickObject release
-
- -

Here, we assume that the VisualStaticMT project has been built using the release setting for an optimized build. If the debug setting was used for a debug build, specify the argument debug; instead.

- -

To register the DLL as a COM+ server, type

- -
-regsvr32 /c /s ImageMagickObject.dll
-
- -

To unregister the DLL, type

- -
-regsvr32 /u /s ImageMagickObject.dll
-
- -

Use MagickCMD to exercise ImageMagickObject to verify that it is working properly.

- -
- -
- - - -
- - diff --git a/ImageMagick-7.0.0-0/www/advanced-unix-installation.html b/ImageMagick-7.0.0-0/www/advanced-unix-installation.html deleted file mode 100644 index 6a5a62a47..000000000 --- a/ImageMagick-7.0.0-0/www/advanced-unix-installation.html +++ /dev/null @@ -1,633 +0,0 @@ - - - - - - - - - ImageMagick: Advanced Unix Source Installation - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
-

Download & Unpack • Configure • Build • Install • Linux-specific Build Instructions • Mac OS X-specific Build Instructions • MinGW-specific Build Instructions • Dealing with Unexpected Problems

- -

It's possible you don't want to concern yourself with advanced installation under Unix or Linux systems. If so, you also have the option of installing a pre-compiled binary release or if you still want to install from source without all the fuss see the simple Install From Source instructions. However, if you want to customize the configuration and installation of ImageMagick under Unix or Linux systems, lets begin.

- -

Download & Unpack

- -

ImageMagick builds on a variety of Unix and Unix-like operating systems including Linux, Solaris, FreeBSD, Mac OS X, and others. A compiler is required and fortunately almost all modern Unix systems have one. Download ImageMagick.tar.gz from ftp.imagemagick.org or its mirrors and verify the distribution against its message digest.

- -

Unpack the distribution it with this command:

- -
-tar xvzf ImageMagick.tar.gz
-
- -

Now that you have the ImageMagick Unix/Linux source distribution unpacked, let's configure it.

- - -

Configure

- -

The configure script looks at your environment and decides what it can cobble together to get ImageMagick compiled and installed on your system. This includes finding a compiler, where your compiler header files are located (e.g. stdlib.h), and if any delegate libraries are available for ImageMagick to use (e.g. JPEG, PNG, TIFF, etc.). If you are willing to accept configure's default options, and build from within the source directory, you can simply type:

- -
 cd ImageMagick-7.0.0-0 ./configure
-

Watch the configure script output to verify that it finds everything that - you think it should. Pay particular attention to the last lines of the script output. For example, here is a recent report from our system:

- -
ImageMagick is configured as follows. Please verify that this configuration
-matches your expectations.
-
-Host system type: x86_64-unknown-linux-gnu
-Build system type: x86_64-unknown-linux-gnu
-
-                  Option                     Value
--------------------------------------------------------------------------------
-Shared libraries  --enable-shared=yes		yes
-Static libraries  --enable-static=yes		yes
-Module support    --with-modules=yes		yes
-GNU ld            --with-gnu-ld=yes		yes
-Quantum depth     --with-quantum-depth=16	16
-High Dynamic Range Imagery
-                  --enable-hdri=no		no
-
-Delegate Configuration:
-BZLIB             --with-bzlib=yes		yes
-Autotrace         --with-autotrace=yes	yes
-DJVU              --with-djvu=yes		no
-DPS               --with-dps=yes		no
-FlashPIX          --with-fpx=yes		no
-FontConfig        --with-fontconfig=yes	yes
-FreeType          --with-freetype=yes		yes
-GhostPCL          None			pcl6 (unknown)
-GhostXPS          None			gxps (unknown)
-Ghostscript       None			gs (8.63)
-result_ghostscript_font_dir='none'
-Ghostscript fonts --with-gs-font-dir=default
-Ghostscript lib   --with-gslib=yes		no (failed tests)
-Graphviz          --with-gvc=yes		yes
-JBIG              --with-jbig=		no
-JPEG v1           --with-jpeg=yes		yes
-JPEG-2000         --with-jp2=yes		yes
-LCMS              --with-lcms=yes		yes
-LQR               --with-lqr=yes		no
-Magick++          --with-magick-plus-plus=yes	yes
-OpenEXR           --with-openexr=yes		yes
-PERL              --with-perl=yes		/usr/bin/perl
-PNG               --with-png=yes		yes
-RSVG              --with-rsvg=yes		yes
-TIFF              --with-tiff=yes		yes
-result_windows_font_dir='none'
-Windows fonts     --with-windows-font-dir=
-WMF               --with-wmf=yes		yes
-X11               --with-x=			yes
-XML               --with-xml=yes		yes
-ZLIB              --with-zlib=yes		yes
-
-X11 Configuration:
-      X_CFLAGS        =
-      X_PRE_LIBS      = -lSM -lICE
-      X_LIBS          =
-      X_EXTRA_LIBS    =
-
-Options used to compile and link:
-  PREFIX          = /usr/local
-  EXEC-PREFIX     = /usr/local
-  VERSION         = 6.4.8
-  CC              = gcc -std=gnu99
-  CFLAGS          = -fopenmp -g -O2 -Wall -W -pthread
-  MAGICK_CFLAGS   = -fopenmp -g -O2 -Wall -W -pthread
-  CPPFLAGS        = -I/usr/local/include/ImageMagick
-  PCFLAGS         = -fopenmp
-  DEFS            = -DHAVE_CONFIG_H
-  LDFLAGS         = -lfreetype
-  MAGICK_LDFLAGS  = -L/usr/local/lib -lfreetype
-  LIBS            = -lMagickCore-Q16 -llcms -ltiff -lfreetype -ljpeg -lfontconfig -lXext
-                    -lSM -lICE -lX11 -lXt -lbz2 -lz -lm -lgomp -lpthread -lltdl
-  CXX             = g++
-  CXXFLAGS        = -g -O2 -Wall -W -pthread
-
- -

You can influence choice of compiler, compilation flags, or libraries of the configure script by setting initial values for variables in the configure command line. These include, among others:

- -
-
CC
-
Name of C compiler (e.g. cc -Xa) to use.
-
CXX
-
Name of C++ compiler to use (e.g. CC).
-
CFLAGS
-
Compiler flags (e.g. -g -O2) to compile C code.
-
CXXFLAGS
-
Compiler flags (e.g. -g -O2) to compile C++ code.
-
CPPFLAGS
-
Include paths (.e.g. -I/usr/local) to look for header files.
-
LDFLAGS
-
Library paths (.e.g. -L/usr/local) to look for libraries systems that support the notion of a library run-path may require an additional argument in order to find shared libraries at run time. For example, the Solaris linker requires an argument of the form -R/path. Some Linux systems will work with -rpath /usr/local/lib, while some other Linux systems who's gcc does not pass -rpath to the linker, require an argument of the form -Wl,-rpath,/usr/local/lib.
-
LIBS
-
Extra libraries (.e.g. -l/usr/local/lib) required to link.
-
- -

Here is an example of setting configure variables from the command line:

- -
-configure CC=c99 CFLAGS=-O2 LDFLAGS='-L/usr/local/lib -R/usr/local/lib' LIBS=-lposix
-
- -

Any variable (e.g. CPPFLAGS or LDFLAGS) which requires a directory path must specify an absolute path rather than a relative path.

- -

Configure can usually find the X include and library files automagically, but if it doesn't, you can use the --x-includes=path and --x-libraries=path options to specify their locations.

- -

The configure script provides a number of ImageMagick specific options. When disabling an option --disable-something is equivalent to specifying --enable-something=no and --without-something is equivalent to --with-something=no. The configure options are as follows (execute configure --help to see all options).

- -

ImageMagick options represent either features to be enabled, disabled, or packages to be included in the build. When a feature is enabled (via --enable-something), it enables code already present in ImageMagick. When a package is enabled (via --with-something), the configure script will search for it, and if is properly installed and ready to use (headers and built libraries are found by compiler) it will be included in the build. The configure script is delivered with all features disabled and all packages enabled. In general, the only reason to disable a package is if a package exists but it is unsuitable for the build (perhaps an old version or not compiled with the right compilation flags).

- -

Here are the optional features you can configure:

- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
--enable-sharedbuild the shared libraries and support for loading coder and process modules. Shared libraries are preferred because they allow programs to share common code, making the individual programs much smaller. In addition shared libraries are required in order for PerlMagick to be dynamically loaded by an installed PERL (otherwise an additional PERL (PerlMagick) must be installed. -

- ImageMagick built with delegates (see MAGICK PLUG-INS below) can pose additional challenges. If ImageMagick is built using static libraries (the default without --enable-shared) then delegate libraries may be built as either static libraries or shared libraries. However, if ImageMagick is built using shared libraries, then all delegate libraries must also be built as shared libraries. Static libraries usually have the extension .a, while shared libraries typically have extensions like .so, .sa, or .dll. Code in shared libraries normally must compiled using a special compiler option to produce Position Independent Code (PIC). The only time this not necessary is if the platform compiles code as PIC by default. -

- PIC compilation flags differ from vendor to vendor (gcc's is -fPIC). However, you must compile all shared library source with the same flag (for gcc use -fPIC rather than -fpic). While static libraries are normally created using an archive tool like ar, shared libraries are built using special linker or compiler options (e.g. -shared for gcc). -

- If --enable-shared is not specified, a new PERL interpreter (PerlMagick) is built which is statically linked against the PerlMagick extension. This new interpreter is installed into the same directory as the ImageMagick utilities. If --enable-shared is specified, the PerlMagick extension is built as a dynamically loadable object which is loaded into your current PERL interpreter at run-time. Use of dynamically-loaded extensions is preferable over statically linked extensions so use --enable-shared if possible (note that all libraries used with ImageMagick must be shared libraries!).
--disable-staticstatic archive libraries (with extension .a) are not built. If you are building shared libraries, there is little value to building static libraries. Reasons to build static libraries include: 1) they can be easier to debug; 2) clients do not have external dependencies (i.e. libMagick.so); 3) building PIC versions of the delegate libraries may take additional expertise and effort; 4) you are unable to build shared libraries.
--disable-installeddisable building an installed ImageMagick (default enabled). -

- By default the ImageMagick build is configured to formally install into a directory tree. This the most secure and reliable way to install ImageMagick. Use this option to configure ImageMagick so that it doesn't use hard-coded paths and locates support files by computing an offset path from the executable (or from the location specified by the MAGICK_HOME environment variable. The uninstalled configuration is ideal for binary distributions which are expected to extract and run in any location.
--enable-ccmallocenable 'ccmalloc' memory debug support (default disabled).
--enable-profenable 'prof' profiling support (default disabled).
--enable-gprofenable 'gprof' profiling support (default disabled).
--enable-gcovenable 'gcov' profiling support (default disabled).
--disable-openmpdisable OpenMP (default enabled). -

- Certain ImageMagick algorithms, for example convolution, can achieve a significant speed-up with the assistance of the OpenMP API when running on modern dual and quad-core processors.
--disable-largefiledisable support for large (64 bit) file offsets. -

- By default, ImageMagick is compiled with support for large files (> 2GB on a 32-bit CPU) if the operating system supports large files. Some applications which use the ImageMagick library may also require support for large files. By disabling support for large files via --disable-largefile, dependent applications do not require special compilation options for large files in order to use the library.
- -

Here are the optional packages you can configure:

- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
--with-quantum-depthnumber of bits in a pixel quantum (default 16). -

- Use this option to specify the number of bits to use per pixel quantum (the size of the red, green, blue, and alpha pixel components). For example, --with-quantum-depth=8 builds ImageMagick using 8-bit quantums. Most computer display adapters use 8-bit quantums. Currently supported arguments are 8, 16, or 32. We recommend the default of 16 because some image formats support 16 bits-per-pixel. However, this option is important in determining the overall run-time performance of ImageMagick. -

- The number of bits in a quantum determines how many values it may contain. Each quantum level supports 256 times as many values as the previous level. The following table shows the range available for various quantum sizes. -

-
-Quantum Depth     Valid Range (Decimal)   Valid Range (Hex)
-    8             0-255                   00-FF
-   16             0-65535                 0000-FFFF
-   32             0-4294967295            00000000-FFFFFFFF
-
-

- Larger pixel quantums can cause ImageMagick to run more slowly and to require more memory. For example, using sixteen-bit pixel quantums can cause ImageMagick to run 15% to 50% slower (and take twice as much memory) than when it is built to support eight-bit pixel quantums. -

- The amount of virtual memory consumed by an image can be computed by the equation (5 * Quantum Depth * Rows * Columns) / 8. This an important consideration when resources are limited, particularly since processing an image may require several images to be in memory at one time. The following table shows memory consumption values for a 1024x768 image: -

-
-Quantum Depth   Virtual Memory
-     8               3MB
-    16               8MB
-    32              15MB
-
--enable-hdriaccurately represent the wide range of intensity levels.
--enable-osx-universal-binarybuild a universal binary on OS X.
--without-modulesdisable support for dynamically loadable modules. -

- Image coders and process modules are built as loadable modules which are installed under the directory [prefix]/lib/ImageMagick-X.X.X/modules-QN (where 'N' equals 8, 16, or 32 depending on the quantum depth) in the subdirectories coders and filters respectively. The modules build option is only available in conjunction with --enable-shared. If --enable-shared is not also specified, support for building modules is disabled. Note that if --enable-shared and --disable-modules are specified, the module loader is active (allowing extending an installed ImageMagick by simply copying a module into place) but ImageMagick itself is not built using modules.
--with-cacheset pixel cache threshold (defaults to available memory). -

- Specify a different image pixel cache threshold with this option. This sets the maximum amount of heap memory that ImageMagick is allowed to consume before switching to using memory-mapped temporary files to store raw pixel data.
--without-threadsdisable threads support. -

- By default, the ImageMagick library is compiled with multi-thread support. If this undesirable, specify --without-threads.
--with-frozenpathsenable frozen delegate paths. -

- Normally, external program names are substituted into the delegates.xml configuration file without full paths. Specify this option to enable saving full paths to programs using locations determined by configure. This useful for environments where programs are stored under multiple paths, and users may use different PATH settings than the person who builds ImageMagick.
--without-magick-plus-plusdisable build/install of Magick++. -

- Disable building Magick++, the C++ application programming interface to ImageMagick. A suitable C++ compiler is required in order to build Magick++. Specify the CXX configure variable to select the C++ compiler to use (default g++), and CXXFLAGS to select the desired compiler optimization and debug flags (default -g -O2). Antique C++ compilers will normally be rejected by configure tests so specifying this option should only be necessary if Magick++ fails to compile.
--without-perldisable build/install of PerlMagick, or -

- By default, PerlMagick is conveniently compiled and installed as part of ImageMagick's normal configure, make, sudo make install process. When --without-perl is specified, you must first install ImageMagick, change to the PerlMagick subdirectory, build, and finally install PerlMagick. Note, PerlMagick is configured even if --without-perl is specified. If the argument --with-perl=/path/to/perl is supplied, /../path/to/perl is be taken as the PERL interpreter to use. This important in case the perl executable in your PATH is not PERL5, or is not the PERL you want to use.
--with-perl=PERLuse specified Perl binary to configure PerlMagick.
--with-perl-options=OPTIONSoptions to pass on command-line when generating PerlMagick's Makefile from Makefile.PL. -

- The PerlMagick module is normally installed using the Perl interpreter's installation PREFIX, rather than ImageMagick's. If ImageMagick's installation prefix is not the same as PERL's PREFIX, then you may find that PerlMagick's sudo make install step tries to install into a directory tree that you don't have write permissions to. This common when PERL is delivered with the operating system or on Internet Service Provider (ISP) web servers. If you want PerlMagick to install elsewhere, then provide a PREFIX option to PERL's configuration step via "--with-perl-options=PREFIX=/some/place". Other options accepted by MakeMaker are 'LIB', 'LIBPERL_A', 'LINKTYPE', and 'OPTIMIZE'. See the ExtUtils::MakeMaker(3) manual page for more information on configuring PERL extensions.
--without-bzlibdisable BZLIB support.
--without-dpsdisable Display Postscript support.
--with-fpxenable FlashPIX support.
--without-freetypedisable TrueType support.
--with-gslibenable Ghostscript library support.
--without-jbigdisable JBIG support.
--without-jpegdisable JPEG support.
--without-jp2disable JPEG v2 support.
--without-lcmsdisable LCMS support.
--without-lzmadisable LZMA support.
--without-pngdisable PNG support.
--without-tiffdisable TIFF support.
--without-wmfdisable WMF support.
--with-fontpathprepend to default font search path.
--with-gs-font-dirdirectory containing Ghostscript fonts. -

- Specify the directory containing the Ghostscript Postscript Type 1 font files (e.g. n022003l.pfb) so that they can be rendered using the FreeType library. If the font files are installed using the default Ghostscript installation paths (${prefix}/share/ghostwww/fonts), they should be discovered automagically by configure and specifying this option is not necessary. Specify this option if the Ghostscript fonts fail to be located automagically, or the location needs to be overridden.
--with-windows-font-dirdirectory containing MS-Windows fonts. -

- Specify the directory containing MS-Windows-compatible fonts. This not necessary when ImageMagick is running under MS-Windows.
--without-xmldisable XML support.
--without-zlibdisable ZLIB support.
--without-xdon't use the X Window System. -

- By default, ImageMagick uses the X11 delegate libraries if they are available. When --without-x is specified, use of X11 is disabled. The display, animate, and import sub-commands are not included. The remaining sub-commands have reduced functionality such as no access to X11 fonts (consider using Postscript or TrueType fonts instead).
--with-share-path=DIRAlternate path to share directory (default share/ImageMagick).
--with-libstdc=DIRuse libstdc++ in DIR (for GNU C++).
- -

While configure is designed to ease installation of ImageMagick, it often discovers problems that would otherwise be encountered later when compiling ImageMagick. The configure script tests for headers and libraries by executing the compiler (CC) with the specified compilation flags (CFLAGS), pre-processor flags (CPPFLAGS), and linker flags (LDFLAGS). Any errors are logged to the file config.log. If configure fails to discover a header or library please review this log file to determine why, however, please be aware that *errors in the config.log are normal* because configure works by trying something and seeing if it fails. An error in config.log is only a problem if the test should have passed on your system.

- -

Common causes of configure failures are: 1) a delegate header is not in the header include path (CPPFLAGS -I option); 2) a delegate library is not in the linker search/run path (LDFLAGS -L/-R option); 3) a delegate library is missing a function (old version?); or 4) compilation environment is faulty.

-

If all reasonable corrective actions have been tried and the problem appears be due to a flaw in the configure script, please send a bug report to the ImageMagick Defect Support Forum. All bug reports should contain the operating system type (as reported by uname -a) and the compiler/compiler-version. A copy of the configure script output and/or the relevant portion of config.log file may be valuable in order to find the problem. If you post portions of config.log, please also send a script of the configure output and a description of what you expected to see (and why) so the failure you are observing can be identified and resolved.

- -

ImageMagick is now configured and ready to build

- -

Build

- -

Once ImageMagick is configured, these standard build targets are available from the generated make files:

- -
-
make
-
Build ImageMagick.
-
sudo make install
-
Install ImageMagick.
-
make check
-
Run tests using the installed ImageMagick (sudo make install must be done first). Ghostscript is a prerequisite, otherwise the EPS, PS, and PDF - tests will fail.
-
make clean
-
Remove everything in the build directory created by make.
-
make distclean
-
remove everything in the build directory created by configure and make. This useful if you want to start over from scratch.
-
make uninstall
-
Remove all files from the system which are (or would be) installed by sudo make install using the current configuration. Note that this target is imperfect for PerlMagick since Perl no longer supports an uninstall target.
-
- -

In most cases you will simply wand to compile ImageMagick with this command:

- -
-make
-
- -

Once built, you can optionally install ImageMagick on your system as discussed below.

- -

Install

- -

Now that ImageMagick is configured and built, type:

- -
-make install
-
- -

to install it.

- -

By default, ImageMagick is installs binaries in /../usr/local/bin, libraries in /../usr/local/lib, header files in /../usr/local/include and documentation in /../usr/local/share. You can specify an alternative installation prefix other than /../usr/local by giving configure the option --prefix=PATH. This valuable in case you don't have privileges to install under the default paths or if you want to install in the system directories instead.

- -

To confirm your installation of the ImageMagick distribution was successful, ensure that the installation directory is in your executable search path and type:

- -
-convert logo: logo.gif
-identify logo.gif
-
- -

The ImageMagick logo is displayed on your X11 display.

- -

To verify the ImageMagick build configuration, type:

- -
-identify -list configure
-
- -

To list which image formats are supported , type:

- -
-identify -list format
-
- -

For a more comprehensive test, you run the ImageMagick test suite by typing:

- -
-make check
-
- -

Ghostscript is a prerequisite, otherwise the EPS, PS, and PDF tests will fail. Note that due to differences between the developer's environment and your own it is possible that a few tests may fail even though the results are ok. Differences between the developer's environment environment and your own may include the compiler, the CPU type, and the library versions used. The ImageMagick developers use the current release of all dependent libraries.

- -

Linux-specific Build instructions

- -

Download ImageMagick.src.rpm from ftp.imagemagick.org or its mirrors and verify the distribution against its message digest.

- -

Build ImageMagick with this command:

- -
-rpmbuild --rebuild ImageMagick.src.rpm
-
- -

After the build you, locate the RPMS folder and install the ImageMagick binary RPM distribution:

- -
 rpm -ivh ImageMagick-7.0.0-?.*.rpm
-

Mac OS X-specific Build instructions

- -

Perform these steps as an administrator or with the sudo command:

- -

Install MacPorts. Download and install MacPorts and type the following commands:

- -
-sudo port -v install freetype +bytecode
-sudo port -v install librsvg
-sudo port -v install graphviz +gs +wmf +jbig +jpeg2 +lcms
-
- -

This installs many of the delegate libraries ImageMagick will utilize such as JPEG and FreeType.

- - -

Install the latest Xcode from Apple.

-

Use the port command to install any delegate libraries you require, for example:

- -
-sudo port install jpeg
-
- -

Now lets build ImageMagick:

- -

Download the ImageMagick source distribution and verify the distribution against its message digest.

-

Unpack and change into the top-level ImageMagick directory:

-
 tar xvzf ImageMagick-7.0.0-0.tar.gz cd ImageMagick-7.0.0-0

Configure ImageMagick:

-
-./configure --prefix=/opt --with-quantum-depth=16 \
-  --disable-dependency-tracking --with-x=yes \
-  --x-includes=/usr/X11R6/include --x-libraries=/usr/X11R6/lib/ \
-  --without-perl"
-
-

Build ImageMagick:

-
-make
-
-

Install ImageMagick:

-
-sudo make install
-
-

To verify your install, type

- -
-/opt/local/bin/identify -list font
-
- -

to list all the fonts ImageMagick knows about.

-

To test the ImageMagick GUI, in a new shell, type:

- -
-display -display :0
-
- -

MinGW-specific Build instructions

- -

Although you can download and install delegate libraries yourself, many are already available in the GnuWin32 distribution. Download and install whichever delegate libraries you require such as JPEG, PNG, TIFF, etc. Make sure you specify the development headers when you install a package. Next type,

- -
 tar jxvf ImageMagick-7.0.0-?.tar.bz2
cd ImageMagick-7.0.0-0
export CPPFLAGS="-Ic:/Progra~1/GnuWin32/include"
export LDFLAGS="-Lc:/Progra~1/GnuWin32/lib"
./configure --without-perl
make
sudo make install
-

Dealing with Unexpected Problems

- -

Chances are the download, configure, build, and install of ImageMagick went flawlessly as it is intended, however, certain systems and environments may cause one or more steps to fail. We discuss a few problems we've run across and how to take corrective action to ensure you have a working release of ImageMagick

- -

Build Problems

-

If the build complains about missing dependencies (e.g. .deps/source.PLO), add --disable-dependency-tracking to your configure command line.

- -

Some systems may fail to link at build time due to unresolved symbols. Try adding the LDFLAGS to the configure command line:

- -
-configure LDFLAGS='-L/usr/local/lib -R/usr/local/lib'
-
- -

Dynamic Linker Run-time Bindings

-

On some systems, ImageMagick may not find its shared library, libMagick.so. Try running the ldconfig with the library path:

- -
-/sbin/ldconfig /usr/local/lib
-
- -

Solaris and Linux systems have the ldd command which is useful to track which libraries ImageMagick depends on:

- -
-ldd `which convert`
-
- -

Delegate Libraries

-

On occasion you may receive these warnings:

-
-no decode delegate for this image format
-no encode delegate for this image format
-
-

This exception indicates that an external delegate library or its headers were not available when ImageMagick was built. To add support for the image format, download and install the requisite delegate library and its header files and reconfigure, rebuild, and reinstall ImageMagick. As an example, lets add support for the JPEG image format. First we install the JPEG RPMS:

- -
-yum install libjpeg libjpeg-devel
-
- -

Now reconfigure, rebuild, and reinstall ImageMagick. To verify JPEG is now properly supported within ImageMagick, use this command:

- -
-identify -list format
-
- -

You should see a mode of rw- associated with the JPEG tag. This mode means the image can be read or written and can only support one image per image file.

- -

PerlMagick

-

If PerlMagick fails to link with a message similar to libperl.a is not found, rerun configure with the --enable-shared or --enable-shared --with-modules options.

- -
- -
- - - -
- - diff --git a/ImageMagick-7.0.0-0/www/advanced-windows-installation.html b/ImageMagick-7.0.0-0/www/advanced-windows-installation.html deleted file mode 100644 index 89f2d5750..000000000 --- a/ImageMagick-7.0.0-0/www/advanced-windows-installation.html +++ /dev/null @@ -1,397 +0,0 @@ - - - - - - - - - ImageMagick: Advanced Windows Source Installation - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
-

Download & Unpack • Configure • Build • Install • Create a Self-installing Binary Distribution • Dealing with Unexpected Problems • Building Your Custom Project

- -

It's possible you don't want to concern yourself with advanced installation under Windows. If so, you also have the option of installing a self-installing binary release or if you still want to install from source without all the fuss see the simple Install From Source instructions. However, if you want to customize the configuration and installation of ImageMagick under Windows, lets begin.

- -

Download & Unpack

- -

Building ImageMagick source for Windows requires a modern version of Microsoft Visual Studio IDE. Users have reported success with the Borland C++ compiler as well. If you don't have a compiler you can still install a self-installing binary release.

- -

Download ImageMagick-windows.zip from ftp.imagemagick.org or its mirrors and verify the distribution against its message digest.

- -

You can unpack the distribution with WinZip or type the following from any Command Prompt window:

- -
-unzip ImageMagick-windows.zip
-
- -

Now that you have the ImageMagick Windows source distribution unpacked, let's configure it.

- - -

Configure

- -

These instructions are specific to building ImageMagick with the Visual Studio under Windows XP, Win2K, or Windows 98. ImageMagick does not include any workspace (DSW) or project files (DSP) except for those included with third party libraries. Instead, there is a configure program that must be built and run which creates the Visual Studio workspaces for ImageMagick. The Visual Studio system provides four different types of runtime environments that must match across all application, library, and dynamic-library (DLL) code that is built. The configure program creates a set of build files that are consistent for a specific runtime selection listed here:

- -
    -
  1. Dynamic Multi-threaded DLL runtimes (VisualDynamicMT).
  2. -
  3. Static Single-threaded runtimes (VisualStaticST).
  4. -
  5. Static Multi-threaded runtimes (VisualStaticMT).
  6. -
  7. Static Multi-threaded DLL runtimes (VisualStaticMTDLL).
  8. -
- -

In addition to these runtimes, the VisualMagick build environment allows you to select whether to include the X11 libraries in the build or not. X11 DLLs and headers are provided with the VisualMagick build environment. Most Windows users are probably not interested in using X11, so you might prefer to build without X11 support. Since the animate, display, and import program depends on the X11 delegate libraries, these programs will no work if you choose not to include X11 support.

- -

This leads to five different possible build options. The default binary distribution is built using the Dynamic Multi-threaded DLL (VisualDynamicMT) option with the X11 libraries included. This results in an X11 compatible build using all DLL's for everything and multi-threaded support (the only option for DLL's).

- -

To create a workspace for your requirements, simply go to the VisualMagick\configure folder and open the configure.dsw workspace (for Visual Studio 6) or configure.sln (for Visual Studio 7 or 8). Set the build configuration to Release.

- -

Build and execute the configure program and follow the on-screen instructions. You should not change any of the defaults unless you have a specific reason to do so.

- -

The configure program has a button entitled:

- -

- Edit "magick_config.h" -

- -

Click on this button to bring up magick-config.h in Windows Notepad. Review and optionally change any preprocessor defines in ImageMagick's magick_config.h file to suit your needs. This file is copied to magick\magick_config.h. You may safely open magick\magick_config.h, modify it, and recompile without re-running the configure program. In fact, using Notepad to edit the copied file may be preferable since it preserves the original magick_config.h file.

- -

Key user defines in magick_config.h include:

- -
- - - - - - - - - - - - - -
MAGICKCORE_QUANTUM_DEPTH (default 16)Specify the depth of the pixel component depth (8, 16, or 32). A value of 8 uses half the memory than 16 and may run 30% faster, but provides 256 times less color resolution than a value of 16. We recommend a quantum depth of 16 because 16-bit images are becoming more prevalent on the Internet.
MAGICKCORE_INSTALLED_SUPPORT (default undefined)Define to build a ImageMagick which uses registry settings or embedded paths to locate installed components (coder modules and configuration files). The default is to look for all files in the same directory as the executable. You will wand to define this value if you intend on installing ImageMagick on your system.
ProvideDllMain (default defined)Define to include a DllMain() function ensures that the ImageMagick DLL is properly initialized without participation from dependent applications. This avoids the requirement to invoke InitializeMagick() from dependent applications is only useful for DLL builds.
- -

ImageMagick is now configured and ready to build.

- -

The default build is WIN32. For 64-bit, open a newly created solution and enter Configuration Manager. Add a x64 configuration, copying the configuration from Win32. Be sure that it adds the configuration to all the projects. Now compile. For the 64-bit build, you will also need to disable X11 support. Edit magick-config.h and undefine the MAGICKCORE_X11_DELEGATE define.

- -

Build

- -

After creating your build environment, proceed to open the DSW (or SLN) workspace in the VisualMagick folder. In the DSW file choose the All project to make it the active project. Set the build configuration to the desired one (Debug, or Release) and clean and build:

- -
    -
  1. Right click on the All project and select Set As Active Project
  2. -
  3. Select "Build=>Clean Solution"
  4. -
  5. Select "Build=>Build Solution"
  6. -
- -

The clean step is necessary in order to make sure that all of the target support libraries are updated with any patches needed to get them to compile properly under Visual Studio.

- -

After a successful build, all of the required files that are needed to run any of the command line tools are located in the VisualMagick\bin folder. This includes EXE, DLL libraries, and ImageMagick configuration files. You should be able to test the build directly from this directory without having to move anything to any of the global SYSTEM or SYSTEM32 areas in the operating system installation.

- -

The Visual Studio distribution of ImageMagick comes with the Magick++ C++ wrapper by default. This add-on layer has a large number of demo and test files that can be found in ImageMagick\Magick++\demo, and ImageMagick\Magick++\tests. There are also a variety of tests that use the straight C API as well in ImageMagick\tests.

- -

All of these programs are not configured to be built in the default workspace created by the configure program. You can cause all of these demos and test programs to be built by checking the box in configure that says:

- -

- Include all demo and test programs -

- -

In addition, there is another related checkbox (checked by default) that causes all generated project files to be created standalone so that they can be copied to other areas of you system.

- -

This the checkbox:

- -

- Generate all utility projects with full paths rather then relative paths. -

- -

Visual Studio uses a concept of dependencies that tell it what other components need to be build when a particular project is being build. This mechanism is also used to ensure that components link properly. In my normal development environment, I want to be able to make changes and debug the system as a whole, so I like and NEED to use dependencies. However, most end users don't want to work this way.

- -

Instead they really just want to build the package and then get down to business working on their application. The solution is to make all the utility projects (UTIL_xxxx_yy_exe.dsp) use full absolute paths to all the things they need. This way the projects stand on their own and can actually be copied and used as templates to get a particular custom application compiling with little effort.

- -

With this feature enabled, you should be able to nab a copy of

- -
-VisualMagick\utilities\UTIL_convert_xxx_exe.dsp  (for C) or
-VisualMagick\Magick++\demo\UTIL_demo_xxx_exe.dsp (for C++)
-
- -

and pop it into Notepad, modify it (carefully) to your needs and be on your way to happy compiling and linking.

- -

You can feel free to pick any of the standard utilities, tests, or demo programs as the basis for a new program by copying the project and the source and hacking away.

- -

The choice of what to use as a starting point is very easy.

- -

For straight C API command line applications use something from:

- -
-ImageMagick\tests or
-ImageMagick\utilities (source code) or
-ImageMagick\VisualMagick\tests or
-ImageMagick\Visualmagick\utilities (project - DSP)
-
- -

For C++ and Magick++ command line applications use something from:

- -
-ImageMagick\Magick++\tests or ImageMagick\Magick++\demo (source code) or
-ImageMagick\VisualMagick\Magick++\tests or  
-ImageMagick\VisualMagick\Magick++\demo (project - DSP) -
- -

For C++ and Magick++ and MFC windows applications use:

- -
-ImageMagick\contrib\win32\MFC\NtMagick (source code) or
-ImageMagick\VisualMagick\contrib\win32\MFC\NtMagick (project - DSP)
-
- -

The ImageMagick distribution is very modular. The default configuration is there to get you rolling, but you need to make some serious choices when you wish to change things around.

- -

The default options are all targeted at having all the components in one place (e.g. the bin directory of the VisualMagick build tree). These components may be copied to another folder (such as to another computer).

- -

The folder containing the executables and DLLs should contain the following files:

- -
    -
  1. magic.xml
  2. -
  3. delegates.xml
  4. -
  5. modules.xml
  6. -
  7. colors.xml
  8. -
- -

among others.

- -

The bin folder should contains all EXE's and DLL's as well as the very important modules.xml file.

- -

With this default setup, you can use any of the command line tools and run scripts as normal. You can actually get by quite nicely this way by doing something like pushd e:\xxx\yyy\bin in any scripts you write to execute out of this directory.

- -

By default the core of ImageMagick on Win32 always looks in the place were the exe program is run from in order to find all of the files as well as the DLL's it needs.

- -

ENVIRONMENT VARIABLES

- -

You can use the System control panel to allow you to add and delete what is in any of the environment variables. You can even have user specific environment variables if you wish.

- -

PATH

-

This environmental variable sets the default list of places were Windows looks for EXE's and DLL's. Windows CMD shell seems to look in the current directory first no matter what, which may make it unnecessary to update the PATH. If you wish to run any of utilities from another location then you must add the path to your bin directory in. For instance, to do this for the default build environment like I do, you might add:

- - -
-C:\ImageMagick\VisualMagick\bin
-
- -

MAGICK_HOME

-

If all you do is modify the PATH variable, the first problem you will run into is that ImageMagick may not be able to find any of its modules. Modules are all the IM_MOD*.DLL files you see in the distribution. There is one of these for each and every file format that ImageMagick supports. This environment variable tells the system were to look for these DLL's. The compiled in default is execution path - which says - look in the same place that the application is running in. If you are running from somewhere other then bin - this will no longer work and you must use this variable. If you elect to leave the modules in the same place as the EXE's (a good idea) then you can simply set this to the same place as you did the PATH variable. In my case:

- -
-C:\ImageMagick\coders
-
- -

This also the place were ImageMagick expects to find the colors.xml, delegates.xml, magic.xml, modules.xml, and type.xml files.

- -

One cool thing about the modules build of ImageMagick is that you can now leave out file formats and lighten you load. If all you ever need is GIF and JPEG, then simply drop all the other DLL's into the local trash can and get on with your life.

- -

Always keep the XC format, since ImageMagick uses it internally.

- -

You can elect to changes these things the good old hard-coded way. This define is applicable in magick-config.h:

- -
-#define MagickConfigurePath  "C:\\ImageMagick\\"
-
- -

To view any image in a Microsoft window, type

- -
-convert image.ext win:
-
- -

Make sure Ghostscript is installed, otherwise, you will be unable to convert or view a Postscript document, and Postscript standard fonts will not be available.

- -

You may use any standard web browser (e.g. Internet Explorer) to browse the ImageMagick documentation.

- -

The Win2K executables will work under Windows 98.

- -

ImageMagick is now configured and built. You can optionally install it on your system as discussed below.

- -

If you are looking to install the ImageMagick COM+ object, see Installing the ImageMagickObject COM+ Component.

- -

Install

- -

You can run ImageMagick command line utilities directly from the VisualMagick\bin folder, however, in most cases you may want the convenience of an installer script. ImageMagick provides Inno Setup scripts for this purpose. Note, you must define MAGICKCORE_INSTALLED_SUPPORT at configure time to utilize the installer scripts.

- -

To get started building a self-installing ImageMagick executable, go to VisualMagick\installer folder and click on a script that matches your build environment. Press F9 to build and install ImageMagick. The default location is C:Program Files\ImageMagick-6.?.?\Q?. The exact folder name depends on the ImageMagick version and quantum depth. Once installed, ImageMagick command line utilities and libraries are available to the MS Command Prompt, web scripts, or to meet your development needs.

- - -

Create a Self-Installing Binary Distribution

- -

Prerequisites

- -
    -
  1. Download and install Inno Setup 5.
  2. -
  3. Download and install Strawberry Perl.
  4. -
- -

Run the Configure Wizard

- -
    -
  1. Double-click on VisualMagick/configure/configure.sln to build the configure wizard.
  2. -
  3. Select Rebuild All and launch the configure wizard.
  4. -
  5. Uncheck Use X11 Stubs and check Build demo and test programs.
  6. -
  7. Click on Edit magick_config.h and define MAGICKCORE_INSTALLED_SUPPORT.
  8. -
  9. Complete the configure wizard screens to create the ImageMagick Visual C++ workspace.
  10. -
- -

Build ImageMagick

- -
    -
  1. Double-click on VisualMagick/VisualDynamicMT.sln to launch the ImageMagick Visual workspace.
  2. -
  3. Set the active configuration to Win32 Release.
  4. -
  5. Select Rebuild All to build the ImageMagick binary distribution.
  6. -
- -

Build ImageMagickObject

- -
    -
  1. Launch the Command Prompt application and move to the contrib\win32\ATL7\ImageMagickObject folder.
  2. -
  3. Build ImageMagickObject with these commands: -
    -BuildImageMagickObject clean
    -BuildImageMagickObject release
    -
  4. -
- -

Build PerlMagick

- -
    -
  1. Launch the Command Prompt application and move to the PerlMagick folder.
  2. -
  3. Build PerlMagick with these commands: -
    -perl Makefile.PL
    -dmake release
    -
  4. -
- -

Create the Self-installing ImageMagick Binary Distribution

- -
    -
  1. Double-click on VisualMagick/installer/im-dll-16.iss to launch the Inno Setup 5 wizard.
  2. -
  3. Select File->Compile.
  4. -
- -

Install the Binary Distribution

- -
    -
  1. Double-click on - VisualMagick/bin/ImageMagick-7.0.0-0-Q16-windows-dll.exe - to launch the ImageMagick binary distribution.
  2. -
  3. Complete the installer screens to install ImageMagick on your system.
  4. -
- -

Test the Binary Distribution

- -
    -
  1. Launch the Command Prompt application and move to the PerlMagick folder and type -
    -nmake test
    -
  2. - -
  3. Move to the VisualMagick/tests folder and type -
    -validate
    -
  4. -
  5. Move to the VisualMagick/Magick++/tests folder and type -
    -run_tests.bat
    -
  6. -
  7. Move to the VisualMagick/Magick++/demo folder and type -
    -run_demos.bat
    -
  8. -
- -

If all the tests pass without complaint, the ImageMagick self-install binary distribution is ready for use.

- -

Dealing with Unexpected Problems

- -

Chances are the download, configure, build, and install of ImageMagick went flawlessly as it is intended, however, certain systems and environments may cause one or more steps to fail. We discuss a few problems we've run across and how to take corrective action to ensure you have a working release of ImageMagick.

- -

If the compiler generates an error or if it quits unexpectedly, go to the Visual Studio web site and look for Visual Studio service packs. Chances are, after you download and install all the Visual Studio service packs, ImageMagick will compile and build as expected.

- - -

Building Your Custom Project

- -

The Windows binary distribution includes a number of demo projects that you can use as a template for your own custom project. For example, start with the Button project, generally located in the c:/Program Files/ImageMagick-6.5.5-0/Magick++_demos folder. If not, be sure to select Configuration Properties->C/C++->Preprocessor and set these definitions:

- -
-NDEBUG
-WIN32
-_CONSOLE
-_VISUALC_
-NeedFunctionPrototypes
-_DLL
-_MAGICKMOD_
-
- -
- -
- - - -
- - diff --git a/ImageMagick-7.0.0-0/www/animate.html b/ImageMagick-7.0.0-0/www/animate.html deleted file mode 100644 index b44bdcac8..000000000 --- a/ImageMagick-7.0.0-0/www/animate.html +++ /dev/null @@ -1,528 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Animate - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
-

Example Usage • Option Summary

- -

Use the animate program to animate an image sequence on any X server. See Command Line Processing for advice on how to structure your animate command or see below for example usages of the command.

- -

Example Usage

- -

We list a few examples of the animate command here to illustrate its usefulness and ease of use. To get started, lets animate an image sequence in the GIF format:

- -
-animate movie.gif
-
- -

To animate a directory of JPEG images, use:

- -
-animate *.jpg
-
- -

You can find additional examples of using animate in Examples of ImageMagick Usage.

- - -

Option Summary

- -

The animate command recognizes these options. Click on an option to get more details about how that option works.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
OptionDescription
-alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
-antialiasremove pixel-aliasing
-authenticate valuedecrypt image with this password
-backdropbackground color
-background colorbackground color
-border geometrysurround image with a border of color
-bordercolor colorborder color
-channel typeapply option to select image channels
-clipclip along the first path from the 8BIM profile
-clip-path idclip along a named path from the 8BIM profile
-coalescemerge a sequence of images
-colormap typeShared or Private
-colors valuepreferred number of colors in the image
-colorspace typeset image colorspace
-comment stringannotate image with comment
-compress typeimage compression type
-contrastenhance or reduce the image contrast
-crop geometrypreferred size and location of the cropped image
-debug eventsanimate copious debugging information
-decipher filenameconvert cipher pixels to plain
-define format:optiondefine one or more image format options
-delay valueanimate the next image after pausing
-density geometryhorizontal and vertical density of the image
-depth valueimage depth
-despecklereduce the speckles within an image
-display serverget image or font from this X server
-dispose methodlayer disposal method
-dither methodapply error diffusion to image
-edge radiusapply a filter to detect edges in the image
-endian typeendianness (MSB or LSB) of the image
-enhanceapply a digital filter to enhance a noisy image
-extract geometryextract area from image
-filter typeuse this filter when resizing an image
-flattenflatten a sequence of images
-flipflip image in the vertical direction
-flopflop image in the horizontal direction
-frame geometrysurround image with an ornamental border
-gamma valuelevel of gamma correction
-geometry geometrypreferred size or location of the image
-gravity geometryhorizontal and vertical backdrop placement
-helpprint program options
-identifyidentify the format and characteristics of the image
-immutable typeprohibit image edits
-interlace typetype of image interlacing scheme
-interpolate methodpixel color interpolation method
-label nameassign a label to an image
-limit type valuepixel cache resource limit
-log formatformat of debugging information
-map filenametransform image colors to match this set of colors
-mattecolor colorframe color
-monitormonitor progress
-monochrometransform image to black and white
-negatereplace each pixel with its complementary color
-page geometrysize and location of an image canvas (setting)
-profile filenameadd, delete, or apply an image profile
-quantize colorspacereduce image colors in this colorspace
-quietsuppress all warning messages
-raise valuelighten/darken image edges to create a 3-D effect
-regard-warningspay attention to warning messages.
-remote commandexecute a command in an remote animate process
-resample geometrychange the resolution of an image
-resize geometryresize the image
-respect-parenthesessettings remain in effect until parenthesis boundary.
-roll geometryroll an image vertically or horizontally
-rotate degreesapply Paeth rotation to the image
-sample geometryscale image with pixel sampling
-sampling-factor geometryhorizontal and vertical sampling factor
-scene valueimage scene number
-segment valuessegment an image
-seed valueseed a new sequence of pseudo-random numbers
-set attribute valueset an image attribute
-sharpen geometrysharpen the image
-size geometrywidth and height of image
-stripstrip image of all profiles and comments
-thumbnail geometrycreate a thumbnail of the image
-transparent-color colortransparent color
-trimtrim image edges
-update secondsdetect when image file is modified and reanimate
-verboseprint detailed information about the image
-versionprint version information
-virtual-pixel methodaccess method for pixels outside the boundaries of the image
-visualanimate image using this visual type
-window idanimate images to background of this window
-window-group idexit program when this window id is destroyed
-
- -
- - - -
- - diff --git a/ImageMagick-7.0.0-0/www/api.html b/ImageMagick-7.0.0-0/www/api.html deleted file mode 100644 index 368136b30..000000000 --- a/ImageMagick-7.0.0-0/www/api.html +++ /dev/null @@ -1,176 +0,0 @@ - - - - - - - - - ImageMagick: Application Program Interfaces - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
- -

ImageMagick includes a number of ready-made interfaces. This makes it possible to modify or create images automagically and dynamically utilizing your favorite development platform.

- -
-
Ada
- -
G2F implements an Ada 95 binding to a subset of the low-level MagickCore library.
- -
C
- -
Use MagickWand to convert, compose, and edit images from the C language. There is also the low-level MagickCore library for wizard-level developers.
- -
Ch
- -
ChMagick is a Ch binding to the MagickCore and MagickWand API. Ch is an embeddable C/C++ interpreter for cross-platform scripting.
- -
COM+
- -
Use ImageMagickObject to convert, compose, and edit images from a Windows COM+ compatible component.
- -
C++
- -
magick++ provides an object-oriented C++ interface to ImageMagick. See A Gentle Introduction to Magick++ for an introductory tutorial to Magick++. We include the source if you want to correct, enhance, or expand the tutorial.
- -
GO
-
GoImagick is a set of Go bindings to ImageMagick's MagickWand and MagickCore C APIs.
- -
Java
- -
JMagick provides an object-oriented Java interface to ImageMagick. Im4java is a pure-java interface to the ImageMagick command-line.
- -
LabVIEW
- -
LVOOP ImageMagick is an object-oriented LabVIEW interface to ImageMagick.
- -
Lisp
- -
CL-Magick provides a Common Lisp interface to the ImageMagick library.
- -
Lua
- -
Lua bindings to ImageMagick for LuaJIT using FFI.
- -
Neko
- -
NMagick is a port of the ImageMagick library to the haXe and Neko platforms. It provides image manipulation capabilities to both web and desktop applications using Neko.
- -
.NET
- -
Use Magick.NET to convert, compose, and edit images from Windows .NET.
- -
ImageMagickApp is a .NET application written in C# that utilizes the ImageMagick command line to allow conversion of multiple image formats to different formats.
- -
Pascal
- -
PascalMagick a Pascal binding for the MagickWand API and also the low-level MagickCore library. It works with Free Pascal / Lazarus and Delphi.
- -
Perl
- -
Use PerlMagick to convert, compose, and edit images from the Perl language.
- -
PHP
- -
MagickWand for PHP a native PHP-extension to the ImageMagick MagickWand API.
- -
IMagick is a native PHP extension to create and modify images using the ImageMagick API. Documentation for the extension is available here.
- -
phMagick is a wrapper class for ImageMagick, wrapping the most common web image manipulation actions in easy to use functions, but allowing full access to ImageMagick's power by issuing system calls to it's command-line programs.
- - -
Python
- - -
Wand is a ctypes-based ImagedMagick binding library for Python.
-
PythonMagick is an object-oriented Python interface to ImageMagick.
-
PythonMagickWand is an object-oriented Python interface to MagickWand based on ctypes.
- -
REALbasic
- -
The MBS Realbasic ImageMagick is a plugin that utilizes the power of ImageMagick from within the RealBasic environment.
- -
Ruby
- -
RMagick is an interface between the Ruby programming language and the MagickCore image processing libraries. Get started with RMagick by perusing the documentation.
- -
MagickWand for Ruby is an interface between the Ruby programming language and the MagickWand image processing libraries. Get started with MagickWand for PHP by perusing the documentation.
- -
MiniMagick is a Ruby wrapper for ImageMagick command line. MiniMagick gives you convenient access to all the command line options ImageMagick supports.
- -
QuickMagick is a gem for easily accessing ImageMagick command line tools from Ruby programs.
- -
Rust
- -
RustWand is a MagickWand bindings for the Rust language.
- -
Tcl/Tk
- -
TclMagick a native Tcl-extension to the ImageMagick MagickWand API.
- -
XML RPC
- -
RemoteMagick is an XML-RPC web service that creates image thumbnails.
-
-
- -
- - - -
- - diff --git a/ImageMagick-7.0.0-0/www/architecture.html b/ImageMagick-7.0.0-0/www/architecture.html deleted file mode 100644 index d50b9ee7d..000000000 --- a/ImageMagick-7.0.0-0/www/architecture.html +++ /dev/null @@ -1,1412 +0,0 @@ - - - - - - - - - ImageMagick: Architecture - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
-

The Pixel Cache • Streaming Pixels • Image Properties and Profiles • Large Image Support • Threads of Execution • Heterogeneous Distributed Processing • Custom Image Coders • Custom Image Filters

- -

The citizens of Oz were quite content with their benefactor, the all-powerful Wizard. They accepted his wisdom and benevolence without ever questioning the who, why, and where of his power. Like the citizens of Oz, if you feel comfortable that ImageMagick can help you convert, edit, or compose your images without knowing what goes on behind the curtain, feel free to skip this section. However, if you want to know more about the software and algorithms behind ImageMagick, read on. To fully benefit from this discussion, you should be comfortable with image nomenclature and be familiar with computer programming.

- -

Architecture Overview

- -

An image typically consists of a rectangular region of pixels and metadata. To convert, edit, or compose an image in an efficient manner we need convenient access to any pixel anywhere within the region (and sometimes outside the region). And in the case of an image sequence, we need access to any pixel of any region of any image in the sequence. However, there are hundreds of image formats such JPEG, TIFF, PNG, GIF, etc., that makes it difficult to access pixels on demand. Within these formats we find differences in:

- -
    -
  • colorspace (e.g sRGB, linear RGB, linear GRAY, CMYK, YUV, Lab, etc.)
  • -
  • bit depth (.e.g 1, 4, 8, 12, 16, etc.)
  • -
  • storage format (e.g. unsigned, signed, float, double, etc.)
  • -
  • compression (e.g. uncompressed, RLE, Zip, BZip, etc.)
  • -
  • orientation (i.e. top-to-bottom, right-to-left, etc.),
  • -
  • layout (.e.g. raw, interspersed with opcodes, etc.)
  • -
- -

In addition, some image pixels may require attenuation, some formats permit more than one frame, and some formats contain vector graphics that must first be rasterized (converted from vector to pixels).

- -

An efficient implementation of an image processing algorithm may require we get or set:

- -
    -
  • one pixel a time (e.g. pixel at location 10,3)
  • -
  • a single scanline (e.g. all pixels from row 4)
  • -
  • a few scanlines at once (e.g. pixel rows 4-7)
  • -
  • a single column or columns of pixels (e.g. all pixels from column 11)
  • -
  • an arbitrary region of pixels from the image (e.g. pixels defined at 10,7 to 10,19)
  • -
  • a pixel in random order (e.g. pixel at 14,15 and 640,480)
  • -
  • pixels from two different images (e.g. pixel at 5,1 from image 1 and pixel at 5,1 from image 2)
  • -
  • pixels outside the boundaries of the image (e.g. pixel at -1,-3)
  • -
  • a pixel component that is unsigned (65311) or in a floating-point representation (e.g. 0.17836)
  • -
  • a high-dynamic range pixel that can include negative values (e.g. -0.00716) as well as values that exceed the quantum depth (e.g. 65931)
  • -
  • one or more pixels simultaneously in different threads of execution
  • -
  • all the pixels in memory to take advantage of speed-ups offered by executing in concert across heterogeneous platforms consisting of CPUs, GPUs, and other processors
  • -
- -

Some images include a clip mask that define which pixels are eligible to be updated. Pixels outside the area defined by the clip mask remain untouched.

- -

Given the varied image formats and image processing requirements, we implemented the ImageMagick pixel cache to provide convenient sequential or parallel access to any pixel on demand anywhere inside the image region (i.e. authentic pixels) and from any image in a sequence. In addition, the pixel cache permits access to pixels outside the boundaries defined by the image (i.e. virtual pixels).

- -

In addition to pixels, images have a plethora of image properties and profiles. Properties include the well known attributes such as width, height, depth, and colorspace. An image may have optional properties which might include the image author, a comment, a create date, and others. Some images also include profiles for color management, or EXIF, IPTC, 8BIM, or XMP informational profiles. ImageMagick provides command line options and programming methods to get, set, or view image properties or profiles or apply profiles.

- -

ImageMagick consists of nearly a half million lines of C code and optionally depends on several million lines of code in dependent libraries (e.g. JPEG, PNG, TIFF libraries). Given that, one might expect a huge architecture document. However, a great majority of image processing is simply accessing pixels and its metadata and our simple, elegant, and efficient implementation makes this easy for the ImageMagick developer. We discuss the implementation of the pixel cache and getting and setting image properties and profiles in the next few sections. Next, we discuss using ImageMagick within a thread of execution. In the final sections, we discuss image coders to read or write a particular image format followed by a few words on creating a filter to access or update pixels based on your custom requirements.

- -

The Pixel Cache

- -

The ImageMagick pixel cache is a repository for image pixels with up to 5 channels. The first 4 channels are stored contiguously and an optional second area follows with 1 channel. The channels are at the depth specified when ImageMagick was built. The channel depths are 8 bits-per-pixel component for the Q8 version of ImageMagick, 16 bits-per-pixel component for the Q16 version, and 32 bits-per-pixel component for the Q32 version. By default pixel components are unsigned quantities, however, if you use the high dynamic-range version of ImageMagick, the components are 32-bit floating point. The primary 4 channels can hold any value but typically contain red, green, blue, and alpha intensities or cyan, magenta, yellow, and alpha intensities. The optional fifth channel contains the colormap indexes for colormapped images or the black channel for CMYK images. The pixel cache storage may be heap memory, anonymous memory mapped memory, disk-backed memory mapped, or on disk. The pixel cache is reference-counted. Only the cache properties are copied when the cache is cloned. The cache pixels are subsequently copied only when you signal your intention to update any of the pixels.

- -

Create the Pixel Cache

- -

The pixel cache is associated with an image when it is created and it is initialized when you try to get or put pixels. Here are three common methods to associate a pixel cache with an image:

- -
-
Create an image canvas initialized to the background color:

-
image=AllocateImage(image_info);
-if (SetImageExtent(image,640,480) == MagickFalse)
-  { /* an exception was thrown */ }
-(void) QueryMagickColor("red",&image->background_color,&image->exception);
-SetImageBackgroundColor(image);
-
- -
Create an image from a JPEG image on disk:

-
(void) strcpy(image_info->filename,"image.jpg"):
-image=ReadImage(image_info,exception);
-if (image == (Image *) NULL)
-  { /* an exception was thrown */ }
-
-
Create an image from a memory based image:

-
image=BlobToImage(blob_info,blob,extent,exception);
-if (image == (Image *) NULL)
-  { /* an exception was thrown */ }
-
-
- -

In our discussion of the pixel cache, we use the MagickCore API to illustrate our points, however, the principles are the same for other program interfaces to ImageMagick.

- -

When the pixel cache is initialized, pixels are scaled from whatever bit depth they originated from to that required by the pixel cache. For example, a 1-channel 1-bit monochrome PBM image is scaled to a 4 channel 8-bit RGBA image, if you are using the Q8 version of ImageMagick, and 16-bit RGBA for the Q16 version. You can determine which version you have with the ‑version option:

- -
 identify -versionVersion: ImageMagick 7.0.0-0 2015-12-10 Q16 http://www.imagemagick.org
-

As you can see, the convenience of the pixel cache sometimes comes with a trade-off in storage (e.g. storing a 1-bit monochrome image as 16-bit RGBA is wasteful) and speed (i.e. storing the entire image in memory is generally slower than accessing one scanline of pixels at a time). In most cases, the benefits of the pixel cache typically outweigh any disadvantages.

- -

Access the Pixel Cache

- -

Once the pixel cache is associated with an image, you typically want to get, update, or put pixels into it. We refer to pixels inside the image region as authentic pixels and outside the region as virtual pixels. Use these methods to access the pixels in the cache:

- - -

Here is a typical MagickCore code snippet for manipulating pixels in the pixel cache. In our example, we copy pixels from the input image to the output image and decrease the intensity by 10%:

- -
const PixelPacket
-  *p;
-
-PixelPacket
-  *q;
-
-ssize_t
-  x,
-  y;
-
-destination=CloneImage(source,source->columns,source->rows,MagickTrue,
-  exception);
-if (destination == (Image *) NULL)
-  { /* an exception was thrown */ }
-for (y=0; y < (ssize_t) source->rows; y++)
-{
-  p=GetVirtualPixels(source,0,y,source->columns,1,exception);
-  q=GetAuthenticPixels(destination,0,y,destination->columns,1,exception);
-  if ((p == (const PixelPacket *) NULL) || (q == (PixelPacket *) NULL)
-    break;
-  for (x=0; x < (ssize_t) source->columns; x++)
-  {
-    SetPixelRed(q,90*p->red/100);
-    SetPixelGreen(q,90*p->green/100);
-    SetPixelBlue(q,90*p->blue/100);
-    SetPixelOpacity(q,90*p->opacity/100);
-    p++;
-    q++;
-  }
-  if (SyncAuthenticPixels(destination,exception) == MagickFalse)
-    break;
-}
-if (y < (ssize_t) source->rows)
-  { /* an exception was thrown */ }
-
- -

When we first create the destination image by cloning the source image, the pixel cache pixels are not copied. They are only copied when you signal your intentions to modify or set the pixel cache by calling GetAuthenticPixels() or QueueAuthenticPixels(). Use QueueAuthenticPixels() if you want to set new pixel values rather than update existing ones. You could use GetAuthenticPixels() to set pixel values but it is slightly more efficient to use QueueAuthenticPixels() instead. Finally, use SyncAuthenticPixels() to ensure any updated pixels are pushed to the pixel cache.

- -

Recall how we mentioned that the indexes of a colormapped image or the black channel of a CMYK image are stored separately. Use GetVirtualIndexQueue() (to read the indexes) or GetAuthenticIndexQueue() (to update the indexes) to gain access to this channel. For example, to print the colormap indexes, use:

- -
const IndexPacket
-  *indexes;
-
-for (y=0; y < (ssize_t) source->rows; y++)
-{
-  p=GetVirtualPixels(source,0,y,source->columns,1);
-  if (p == (const PixelPacket *) NULL)
-    break;
-  indexes=GetVirtualIndexQueue(source);
-  for (x=0; x < (ssize_t) source->columns; x++)
-    (void) printf("%d\n",GetPixelIndex(indexes+x));
-}
-if (y < (ssize_t) source->rows)
-  /* an exception was thrown */
-
- -

The pixel cache manager decides whether to give you direct or indirect access to the image pixels. In some cases the pixels are staged to an intermediate buffer-- and that is why you must call SyncAuthenticPixels() to ensure this buffer is pushed out to the pixel cache to guarantee the corresponding pixels in the cache are updated. For this reason we recommend that you only read or update a scanline or a few scanlines of pixels at a time. However, you can get any rectangular region of pixels you want. GetAuthenticPixels() requires that the region you request is within the bounds of the image area. For a 640 by 480 image, you can get a scanline of 640 pixels at row 479 but if you ask for a scanline at row 480, an exception is returned (rows are numbered starting at 0). GetVirtualPixels() does not have this constraint. For example,

- -
p=GetVirtualPixels(source,-3,-3,source->columns+3,6,exception);
-
- -

gives you the pixels you asked for without complaint, even though some are not within the confines of the image region.

- -

Virtual Pixels

- -

There are a plethora of image processing algorithms that require a neighborhood of pixels about a pixel of interest. The algorithm typically includes a caveat concerning how to handle pixels around the image boundaries, known as edge pixels. With virtual pixels, you do not need to concern yourself about special edge processing other than choosing which virtual pixel method is most appropriate for your algorithm.

-

Access to the virtual pixels are controlled by the SetImageVirtualPixelMethod() method from the MagickCore API or the ‑virtual‑pixel option from the command line. The methods include:

- -
-
background
-
the area surrounding the image is the background color
-
black
-
the area surrounding the image is black
-
checker-tile
-
alternate squares with image and background color
-
dither
-
non-random 32x32 dithered pattern
-
edge
-
extend the edge pixel toward infinity (default)
-
gray
-
the area surrounding the image is gray
-
horizontal-tile
-
horizontally tile the image, background color above/below
-
horizontal-tile-edge
-
horizontally tile the image and replicate the side edge pixels
-
mirror
-
mirror tile the image
-
random
-
choose a random pixel from the image
-
tile
-
tile the image
-
transparent
-
the area surrounding the image is transparent blackness
-
vertical-tile
-
vertically tile the image, sides are background color
-
vertical-tile-edge
-
vertically tile the image and replicate the side edge pixels
-
white
-
the area surrounding the image is white
-
- - -

Cache Storage and Resource Requirements

- -

Recall that this simple and elegant design of the ImageMagick pixel cache comes at a cost in terms of storage and processing speed. The pixel cache storage requirements scales with the area of the image and the bit depth of the pixel components. For example, if we have a 640 by 480 image and we are using the Q16 version of ImageMagick, the pixel cache consumes image width * height * bit-depth / 8 * channels bytes or approximately 2.3 mebibytes (i.e. 640 * 480 * 2 * 4). Not too bad, but what if your image is 25000 by 25000 pixels? The pixel cache requires approximately 4.7 gibibytes of storage. Ouch. ImageMagick accounts for possible huge storage requirements by caching large images to disk rather than memory. Typically the pixel cache is stored in memory using heap memory. If heap memory is exhausted, pixels are stored in in an anonymous map; if the anonymous memory map is exhausted, we create the pixel cache on disk and attempt to memory-map it; and if memory-map memory is exhausted, we simply use standard disk I/O. Disk storage is cheap but it is also very slow, upwards of 1000 times slower than memory. We can get some speed improvements, up to 5 times, if we use memory mapping to the disk-based cache. These decisions about storage are made automagically by the pixel cache manager negotiating with the operating system. However, you can influence how the pixel cache manager allocates the pixel cache with cache resource limits. The limits include:

- -
-
width
-
maximum width of an image. Exceed this limit and an exception is thrown and processing stops.
-
height
-
maximum height of an image. Exceed this limit and an exception is thrown and processing stops.
-
area
-
maximum area in bytes of any one image that can reside in the pixel cache memory. If this limit is exceeded, the image is automagically cached to disk and optionally memory-mapped.
-
memory
-
maximum amount of memory in bytes to allocate for the pixel cache from the anonymous mapped memory or the heap.
-
map
-
maximum amount of memory map in bytes to allocate for the pixel cache.
-
disk
-
maximum amount of disk space in bytes permitted for use by the pixel cache. If this limit is exceeded, the pixel cache is not created and a fatal exception is thrown.
-
files
-
maximum number of open pixel cache files. When this limit is exceeded, any subsequent pixels cached to disk are closed and reopened on demand. This behavior permits a large number of images to be accessed simultaneously on disk, but without a speed penalty due to repeated open/close calls.
-
thread
-
maximum number of threads that are permitted to run in parallel.
-
time
-
maximum number of seconds that the process is permitted to execute. Exceed this limit and an exception is thrown and processing stops.
-
- -

To determine the current setting of these limits, use this command:

- -
--> identify -list resource
-Resource limits:
-  Width: 100MP
-  Height: 100MP
-  Area: 25.181GB
-  Memory: 11.726GiB
-  Map: 23.452GiB
-  Disk: unlimited
-  File: 768
-  Thread: 12
-  Throttle: 0
-  Time: unlimited
-
- -

You can set these limits either as a policy (see policy.xml), with an environment variable, with the -limit command line option, or with the SetMagickResourceLimit() MagickCore API method. As an example, our online web interface to ImageMagick, ImageMagick Studio, includes these policy limits to help prevent a denial-of-service:

-
-<policymap>
-  <policy domain="resource" name="temporary-path" value="/tmp"/>
-  <policy domain="resource" name="memory" value="256MiB"/>
-  <policy domain="resource" name="map" value="512MiB"/>
-  <policy domain="resource" name="width" value="8KP"/>
-  <policy domain="resource" name="height" value="8KP"/>
-  <policy domain="resource" name="area" value="128MB"/>
-  <policy domain="resource" name="disk" value="1GiB"/>
-  <policy domain="resource" name="file" value="768"/>
-  <policy domain="resource" name="thread" value="2"/>
-  <policy domain="resource" name="throttle" value="0"/>
-  <policy domain="resource" name="time" value="120"/>
-  <policy domain="system" name="precision" value="6"/>
-  <policy domain="cache" name="shared-secret" value="replace with your secret phrase"/>
-</policymap>
-
-

Since we process multiple simultaneous sessions, we don't want any one session consuming all the available memory. Instead large images are cached to disk. If the image is too large and exceeds the pixel cache disk limit, the program exits. In addition, we place a time limit to prevent any run-away processing tasks.

- -

Note, the cache limits are global to each invocation of ImageMagick, meaning if you create several images, the combined resource requirements are compared to the limit to determine the pixel cache storage disposition.

- -

To determine which type and how much resources are consumed by the pixel cache, add the -debug cache option to the command-line:

-
-> convert -debug cache logo: -sharpen 3x2 null:
-2013-12-17T13:33:42-05:00 0:00.000 0.000u 7.0.0 Cache convert: cache.c/DestroyPixelCache/1275/Cache
-  destroy 
-2013-12-17T13:33:42-05:00 0:00.000 0.000u 7.0.0 Cache convert: cache.c/OpenPixelCache/3834/Cache
-  open LOGO[0] (Heap Memory, 640x480x4 4.688MiB)
-2013-12-17T13:33:42-05:00 0:00.010 0.000u 7.0.0 Cache convert: cache.c/OpenPixelCache/3834/Cache
-  open LOGO[0] (Heap Memory, 640x480x3 3.516MiB)
-2013-12-17T13:33:42-05:00 0:00.010 0.000u 7.0.0 Cache convert: cache.c/ClonePixelCachePixels/1044/Cache
-  Memory => Memory
-2013-12-17T13:33:42-05:00 0:00.020 0.010u 7.0.0 Cache convert: cache.c/ClonePixelCachePixels/1044/Cache
-  Memory => Memory
-2013-12-17T13:33:42-05:00 0:00.020 0.010u 7.0.0 Cache convert: cache.c/OpenPixelCache/3834/Cache
-  open LOGO[0] (Heap Memory, 640x480x3 3.516MiB)
-2013-12-17T13:33:42-05:00 0:00.050 0.100u 7.0.0 Cache convert: cache.c/DestroyPixelCache/1275/Cache
-  destroy LOGO[0]
-2013-12-17T13:33:42-05:00 0:00.050 0.100u 7.0.0 Cache convert: cache.c/DestroyPixelCache/1275/Cache
-  destroy LOGO[0]
-
-

This command utilizes a pixel cache in memory. The logo consumed 4.688MiB and after it was sharpened, 3.516MiB.

- - -

Distributed Pixel Cache

-

A distributed pixel cache is an extension of the traditional pixel cache available on a single host. The distributed pixel cache may span multiple servers so that it can grow in size and transactional capacity to support very large images. Start up the pixel cache server on one or more machines. When you read or operate on an image and the local pixel cache resources are exhausted, ImageMagick contacts one or more of these remote pixel servers to store or retrieve pixels. The distributed pixel cache relies on network bandwidth to marshal pixels to and from the remote server. As such, it will likely be significantly slower than a pixel cache utilizing local storage (e.g. memory, disk, etc.).

- -

Cache Views

- -

GetVirtualPixels(), GetAuthenticPixels(), QueueAuthenticPixels(), and SyncAuthenticPixels(), from the MagickCore API, can only deal with one pixel cache area per image at a time. Suppose you want to access the first and last scanline from the same image at the same time? The solution is to use a cache view. A cache view permits you to access as many areas simultaneously in the pixel cache as you require. The cache view methods are analogous to the previous methods except you must first open a view and close it when you are finished with it. Here is a snippet of MagickCore code that permits us to access the first and last pixel row of the image simultaneously:

- -
CacheView
-  *view_1,
-  *view_2;
-
-view_1=AcquireVirtualCacheView(source,exception);
-view_2=AcquireVirtualCacheView(source,exception);
-for (y=0; y < (ssize_t) source->rows; y++)
-{
-  u=GetCacheViewVirtualPixels(view_1,0,y,source->columns,1,exception);
-  v=GetCacheViewVirtualPixels(view_2,0,source->rows-y-1,source->columns,1,exception);
-  if ((u == (const PixelPacket *) NULL) || (v == (const PixelPacket *) NULL))
-    break;
-  for (x=0; x < (ssize_t) source->columns; x++)
-  {
-    /* do something with u & v here */
-  }
-}
-view_2=DestroyCacheView(view_2);
-view_1=DestroyCacheView(view_1);
-if (y < (ssize_t) source->rows)
-  { /* an exception was thrown */ }
-
- -

Magick Persistent Cache Format

- -

Recall that each image format is decoded by ImageMagick and the pixels are deposited in the pixel cache. If you write an image, the pixels are read from the pixel cache and encoded as required by the format you are writing (e.g. GIF, PNG, etc.). The Magick Persistent Cache (MPC) format is designed to eliminate the overhead of decoding and encoding pixels to and from an image format. MPC writes two files. One, with the extension .mpc, retains all the properties associated with the image or image sequence (e.g. width, height, colorspace, etc.) and the second, with the extension .cache, is the pixel cache in the native raw format. When reading an MPC image file, ImageMagick reads the image properties and memory maps the pixel cache on disk eliminating the need for decoding the image pixels. The tradeoff is in disk space. MPC is generally larger in file size than most other image formats.

-

The most efficient use of MPC image files is a write-once, read-many-times pattern. For example, your workflow requires extracting random blocks of pixels from the source image. Rather than re-reading and possibly decompressing the source image each time, we use MPC and map the image directly to memory.

- -

Best Practices

- -

Although you can request any pixel from the pixel cache, any block of pixels, any scanline, multiple scanlines, any row, or multiple rows with the GetVirtualPixels(), GetAuthenticPixels(), QueueAuthenticPixels, GetCacheViewVirtualPixels(), GetCacheViewAuthenticPixels(), and QueueCacheViewAuthenticPixels() methods, ImageMagick is optimized to return a few pixels or a few pixels rows at time. There are additional optimizations if you request a single scanline or a few scanlines at a time. These methods also permit random access to the pixel cache, however, ImageMagick is optimized for sequential access. Although you can access scanlines of pixels sequentially from the last row of the image to the first, you may get a performance boost if you access scanlines from the first row of the image to the last, in sequential order.

- -

You can get, modify, or set pixels in row or column order. However, it is more efficient to access the pixels by row rather than by column.

- -

If you update pixels returned from GetAuthenticPixels() or GetCacheViewAuthenticPixels(), don't forget to call SyncAuthenticPixels() or SyncCacheViewAuthenticPixels() respectively to ensure your changes are synchronized with the pixel cache.

- -

Use QueueAuthenticPixels() or QueueCacheViewAuthenticPixels() if you are setting an initial pixel value. The GetAuthenticPixels() or GetCacheViewAuthenticPixels() method reads pixels from the cache and if you are setting an initial pixel value, this read is unnecessary. Don't forget to call SyncAuthenticPixels() or SyncCacheViewAuthenticPixels() respectively to push any pixel changes to the pixel cache.

- -

GetVirtualPixels(), GetAuthenticPixels(), QueueAuthenticPixels(), and SyncAuthenticPixels() are slightly more efficient than their cache view counter-parts. However, cache views are required if you need access to more than one region of the image simultaneously or if more than one thread of execution is accessing the image.

- -

You can request pixels outside the bounds of the image with GetVirtualPixels() or GetCacheViewVirtualPixels(), however, it is more efficient to request pixels within the confines of the image region.

- -

Although you can force the pixel cache to disk using appropriate resource limits, disk access can be upwards of 1000 times slower than memory access. For fast, efficient, access to the pixel cache, try to keep the pixel cache in heap memory or anonymous mapped memory.

- -

The ImageMagick Q16 version of ImageMagick permits you to read and write 16 bit images without scaling but the pixel cache consumes twice as many resources as the Q8 version. If your system has constrained memory or disk resources, consider the Q8 version of ImageMagick. In addition, the Q8 version typically executes faster than the Q16 version.

- -

A great majority of image formats and algorithms restrict themselves to a fixed range of pixel values from 0 to some maximum value, for example, the Q16 version of ImageMagick permit intensities from 0 to 65535. High dynamic-range imaging (HDRI), however, permits a far greater dynamic range of exposures (i.e. a large difference between light and dark areas) than standard digital imaging techniques. HDRI accurately represents the wide range of intensity levels found in real scenes ranging from the brightest direct sunlight to the deepest darkest shadows. Enable HDRI at ImageMagick build time to deal with high dynamic-range images, but be mindful that each pixel component is a 32-bit floating point value. In addition, pixel values are not clamped by default so some algorithms may may have unexpected results due to out-of-band pixel values than the non-HDRI version.

- -

If you are dealing with large images, make sure the pixel cache is written to a disk area with plenty of free space. Under Unix, this is typically /tmp and for Windows, c:/temp. You can tell ImageMagick to write the pixel cache to an alternate location and conserve memory with these options:

- -
-convert -limit memory 2GB -limit map 4GB -define registry:temporary-path=/data/tmp ...
-
- -

Set global resource limits for your environment in the policy.xml configuration file.

- -

If you plan on processing the same image many times, consider the MPC format. Reading a MPC image has near-zero overhead because its in the native pixel cache format eliminating the need for decoding the image pixels. Here is an example:

- -
-convert image.tif image.mpc
-convert image.mpc -crop 100x100+0+0 +repage 1.png
-convert image.mpc -crop 100x100+100+0 +repage 2.png
-convert image.mpc -crop 100x100+200+0 +repage 3.png
-
- -

MPC is ideal for web sites. It reduces the overhead of reading and writing an image. We use it exclusively at our online image studio.

- -

Streaming Pixels

- -

ImageMagick provides for streaming pixels as they are read from or written to an image. This has several advantages over the pixel cache. The time and resources consumed by the pixel cache scale with the area of an image, whereas the pixel stream resources scale with the width of an image. The disadvantage is the pixels must be consumed as they are streamed so there is no persistence.

- -

Use ReadStream() or WriteStream() with an appropriate callback method in your MagickCore program to consume the pixels as they are streaming. Here's an abbreviated example of using ReadStream:

- -
static size_t StreamPixels(const Image *image,const void *pixels,const size_t columns)
-{
-  register const PixelPacket
-    *p;
-
-  MyData
-    *my_data;
-
-  my_data=(MyData *) image->client_data;
-  p=(PixelPacket *) pixels;
-  if (p != (const PixelPacket *) NULL)
-    {
-      /* process pixels here */
-    }
-  return(columns);
-}
-
-...
-
-/* invoke the pixel stream here */
-image_info->client_data=(void *) MyData;
-image=ReadStream(image_info,&StreamPixels,exception);
-
- -

We also provide a lightweight tool, stream, to stream one or more pixel components of the image or portion of the image to your choice of storage formats. It writes the pixel components as they are read from the input image a row at a time making stream desirable when working with large images or when you require raw pixel components. A majority of the image formats stream pixels (red, green, and blue) from left to right and top to bottom. However, a few formats do not support this common ordering (e.g. the PSD format).

- -

Image Properties and Profiles

- -

Images have metadata associated with them in the form of properties (e.g. width, height, description, etc.) and profiles (e.g. EXIF, IPTC, color management). ImageMagick provides convenient methods to get, set, or update image properties and get, set, update, or apply profiles. Some of the more popular image properties are associated with the Image structure in the MagickCore API. For example:

- -
(void) printf("image width: %lu, height: %lu\n",image->columns,image->rows);
-
- -

For a great majority of image properties, such as an image comment or description, we use the GetImageProperty() and SetImageProperty() methods. Here we set a property and fetch it right back:

- -
const char
-  *comment;
-
-(void) SetImageProperty(image,"comment","This space for rent");
-comment=GetImageProperty(image,"comment");
-if (comment == (const char *) NULL)
-  (void) printf("Image comment: %s\n",comment);
-
- -

ImageMagick supports artifacts with the GetImageArtifact() and SetImageArtifact() methods. Artifacts are stealth properties that are not exported to image formats (e.g. PNG).

- -

Image profiles are handled with GetImageProfile(), SetImageProfile(), and ProfileImage() methods. Here we set a profile and fetch it right back:

- -
StringInfo
-  *profile;
-
-profile=AcquireStringInfo(length);
-SetStringInfoDatum(profile,my_exif_profile);
-(void) SetImageProfile(image,"EXIF",profile);
-DestroyStringInfo(profile);
-profile=GetImageProfile(image,"EXIF");
-if (profile != (StringInfo *) NULL)
-  (void) PrintStringInfo(stdout,"EXIF",profile);
-
- -

Large Image Support

-

ImageMagick can read, process, or write mega-, giga-, or tera-pixel image sizes. An image width or height can range from 1 to 2 giga-pixels on a 32 bit OS and up to 9 exa-pixels on a 64-bit OS. Note, that some image formats have restrictions on image size. For example, Photoshop images are limited to 300,000 pixels for width or height. Here we resize an image to a quarter million pixels square:

- -
-convert logo: -resize 250000x250000 logo.miff
-
- -

For large images, ImageMagick will likely create a pixel cache on disk. Make sure you have plenty of temporary disk space. If your default temporary disk partition is too small, tell ImageMagick to use another partition with plenty of free space. For example:

- -
-convert -define registry:temporary-path=/data/tmp logo:  \ 
-resize 250000x250000 logo.miff -
- -

To ensure large images do not consume all the memory on your system, force the image pixels to memory-mapped disk with resource limits:

- -
-convert -define registry:temporary-path=/data/tmp -limit memory 16mb \
-  logo: -resize 250000x250000 logo.miff
-
- -

Here we force all image pixels to disk:

- -
-convert -define registry:temporary-path=/data/tmp -limit area 0 \
-  logo: -resize 250000x250000 logo.miff
-
- -

Caching pixels to disk is about 1000 times slower than memory. Expect long run times when processing large images on disk with ImageMagick. You can monitor progress with this command:

- -
convert -monitor -limit memory 2GiB -limit map 4GiB -define registry:temporary-path=/data/tmp \
-  logo: -resize 250000x250000 logo.miff
-
- -

For really large images, or if there is limited resources on your host, you can utilize a distributed pixel cache on one or more remote hosts:

-
-convert -distribute-cache 6668 &  // start on 192.168.100.50
-convert -distribute-cache 6668 &  // start on 192.168.100.51
-convert -limit memory 2mb -limit map 2mb -limit disk 2gb \
-  -define registry:cache:hosts=192.168.100.50:6668,192.168.100.51:6668 \
-  myhugeimage.jpg -sharpen 5x2 myhugeimage.png
-
- -

Threads of Execution

- -

Many of ImageMagick's internal algorithms are threaded to take advantage of speed-ups offered by the multicore processor chips. However, you are welcome to use ImageMagick algorithms in your threads of execution with the exception of the MagickCore's GetVirtualPixels(), GetAuthenticPixels(), QueueAuthenticPixels(), or SyncAuthenticPixels() pixel cache methods. These methods are intended for one thread of execution only with the exception of an OpenMP parallel section. To access the pixel cache with more than one thread of execution, use a cache view. We do this for the CompositeImage() method, for example. Suppose we want to composite a single image over a different image in each thread of execution. If we use GetVirtualPixels(), the results are unpredictable because multiple threads would likely be asking for different areas of the pixel cache simultaneously. Instead we use GetCacheViewVirtualPixels() which creates a unique view for each thread of execution ensuring our program behaves properly regardless of how many threads are invoked. The other program interfaces, such as the MagickWand API, are completely thread safe so there are no special precautions for threads of execution.

- -

Here is an MagickCore code snippet that takes advantage of threads of execution with the OpenMP programming paradigm:

- -
CacheView
-  *image_view;
-
-MagickBooleanType
-  status;
-
-ssize_t
-  y;
-
-status=MagickTrue;
-image_view=AcquireVirtualCacheView(image,exception);
-#pragma omp parallel for schedule(dynamic,4) shared(status)
-for (y=0; y < (ssize_t) image->rows; y++)
-{
-  register IndexPacket
-    *indexes;
-
-  register PixelPacket
-    *q;
-
-  register ssize_t
-    x;
-
-  if (status == MagickFalse)
-    continue;
-  q=GetCacheViewAuthenticPixels(image_view,0,y,image->columns,1,exception);
-  if (q == (PixelPacket *) NULL)
-    {
-      status=MagickFalse;
-      continue;
-    }
-  indexes=GetCacheViewAuthenticIndexQueue(image_view);
-  for (x=0; x < (ssize_t) image->columns; x++)
-  {
-    SetPixelRed(q,...);
-    SetPixelGreen(q,...);
-    SetPixelBlue(q,...);
-    SetPixelOpacity(q,...);
-    if (indexes != (IndexPacket *) NULL)
-      SetPixelIndex(indexes+x,...);
-    q++;
-  }
-  if (SyncCacheViewAuthenticPixels(image_view,exception) == MagickFalse)
-    status=MagickFalse;
-}
-image_view=DestroyCacheView(image_view);
-if (status == MagickFalse)
-  perror("something went wrong");
-
- -

This code snippet converts an uncompressed Windows bitmap to a Magick++ image:

- -
#include "Magick++.h"
-#include <assert.h>
-#include "omp.h"
-
-void ConvertBMPToImage(const BITMAPINFOHEADER *bmp_info,
-  const unsigned char *restrict pixels,Magick::Image *image)
-{
-  /*
-    Prepare the image so that we can modify the pixels directly.
-  */
-  assert(bmp_info->biCompression == BI_RGB);
-  assert(bmp_info->biWidth == image->columns());
-  assert(abs(bmp_info->biHeight) == image->rows());
-  image->modifyImage();
-  if (bmp_info->biBitCount == 24)
-    image->type(MagickCore::TrueColorType);
-  else
-    image->type(MagickCore::TrueColorMatteType);
-  register unsigned int bytes_per_row=bmp_info->biWidth*bmp_info->biBitCount/8;
-  if (bytes_per_row % 4 != 0) {
-    bytes_per_row=bytes_per_row+(4-bytes_per_row % 4);  // divisible by 4.
-  }
-  /*
-    Copy all pixel data, row by row.
-  */
-  #pragma omp parallel for
-  for (int y=0; y < int(image->rows()); y++)
-  {
-    int
-      row;
-
-    register const unsigned char
-      *restrict p;
-
-    register MagickCore::PixelPacket
-      *restrict q;
-
-    row=(bmp_info->biHeight > 0) ? (image->rows()-y-1) : y;
-    p=pixels+row*bytes_per_row;
-    q=image->setPixels(0,y,image->columns(),1);
-    for (int x=0; x < int(image->columns()); x++)
-    {
-      SetPixelBlue(q,p[0]);
-      SetPixelGreen(q,p[1]);
-      SetPixelRed(q,p[2]);
-      if (bmp_info->biBitCount == 32) {
-        SetPixelOpacity(q,p[3]);
-      }
-      q++;
-      p+=bmp_info->biBitCount/8;
-    }
-    image->syncPixels();  // sync pixels to pixel cache.
-  }
-  return;
-}
- -

If you call the ImageMagick API from your OpenMP-enabled application and you intend to dynamically increase the number of threads available in subsequent parallel regions, be sure to perform the increase before you call the API otherwise ImageMagick may fault.

- -

MagickWand supports wand views. A view iterates over the entire, or portion, of the image in parallel and for each row of pixels, it invokes a callback method you provide. This limits most of your parallel programming activity to just that one module. There are similar methods in MagickCore. For an example, see the same sigmoidal contrast algorithm implemented in both MagickWand and MagickCore.

- -

In most circumstances, the default number of threads is set to the number of processor cores on your system for optimal performance. However, if your system is hyperthreaded or if you are running on a virtual host and only a subset of the processors are available to your server instance, you might get an increase in performance by setting the thread policy or the MAGICK_THREAD_LIMIT environment variable. For example, your virtual host has 8 processors but only 2 are assigned to your server instance. The default of 8 threads can cause severe performance problems. One solution is to limit the number of threads to the available processors in your policy.xml configuration file:

- -
-<policy domain="resource" name="thread" value="2"/>
-
- -

Or suppose your 12 core hyperthreaded computer defaults to 24 threads. Set the MAGICK_THREAD_LIMIT environment variable and you will likely get improved performance:

- -
-export MAGICK_THREAD_LIMIT=12
-
- -

The OpenMP committee has not defined the behavior of mixing OpenMP with other threading models such as Posix threads. However, using modern releases of Linux, OpenMP and Posix threads appear to interoperate without complaint. If you want to use Posix threads from a program module that calls one of the ImageMagick application programming interfaces (e.g. MagickCore, MagickWand, Magick++, etc.) from Mac OS X or an older Linux release, you may need to disable OpenMP support within ImageMagick. Add the --disable-openmp option to the configure script command line and rebuild and reinstall ImageMagick.

- -

Threading Performance

-

It can be difficult to predict behavior in a parallel environment. Performance might depend on a number of factors including the compiler, the version of the OpenMP library, the processor type, the number of cores, the amount of memory, whether hyperthreading is enabled, the mix of applications that are executing concurrently with ImageMagick, or the particular image-processing algorithm you utilize. The only way to be certain of optimal performance, in terms of the number of threads, is to benchmark. ImageMagick includes progressive threading when benchmarking a command and returns the elapsed time and efficiency for one or more threads. This can help you identify how many threads is the most efficient in your environment. For this benchmark we sharpen a 1920x1080 image of a model 10 times with 1 to 12 threads:

-
-convert -bench 10 model.png -sharpen 5x2 null:
-Performance[1]: 10i 1.135ips 1.000e 8.760u 0:08.810
-Performance[2]: 10i 2.020ips 0.640e 9.190u 0:04.950
-Performance[3]: 10i 2.786ips 0.710e 9.400u 0:03.590
-Performance[4]: 10i 3.378ips 0.749e 9.580u 0:02.960
-Performance[5]: 10i 4.032ips 0.780e 9.580u 0:02.480
-Performance[6]: 10i 4.566ips 0.801e 9.640u 0:02.190
-Performance[7]: 10i 3.788ips 0.769e 10.980u 0:02.640
-Performance[8]: 10i 4.115ips 0.784e 12.030u 0:02.430
-Performance[9]: 10i 4.484ips 0.798e 12.860u 0:02.230
-Performance[10]: 10i 4.274ips 0.790e 14.830u 0:02.340
-Performance[11]: 10i 4.348ips 0.793e 16.500u 0:02.300
-Performance[12]: 10i 4.525ips 0.799e 18.320u 0:02.210
-
-

The sweet spot for this example is 6 threads. This makes sense since there are 6 physical cores. The other 6 are hyperthreads. It appears that sharpening does not benefit from hyperthreading.

-

In certain cases, it might be optimal to set the number of threads to 1 or to disable OpenMP completely with the MAGICK_THREAD_LIMIT environment variable, -limit command line option, or the policy.xml configuration file.

- -

Heterogeneous Distributed Processing

-

ImageMagick includes support for heterogeneous distributed processing with the OpenCL framework. OpenCL kernels within ImageMagick permit image processing algorithms to execute across heterogeneous platforms consisting of CPUs, GPUs, and other processors. Depending on your platform, speed-ups can be an order of magnitude faster than the traditional single CPU.

- -

First verify that your version of ImageMagick includes support for the OpenCL feature:

- -
-identify -version
-Features: DPC Cipher Modules OpenCL OpenMP
-
- -

If so, run this command to realize a significant speed-up for image convolution:

- -
-convert image.png -convolve '-1, -1, -1, -1, 9, -1, -1, -1, -1' convolve.png
-
- -

If an accelerator is not available or if the accelerator fails to respond, ImageMagick reverts to the non-accelerated convolution algorithm.

- -

Here is an example OpenCL kernel that convolves an image:

- -
static inline long ClampToCanvas(const long offset,const ulong range)
-{
-  if (offset < 0L)
-    return(0L);
-  if (offset >= range)
-    return((long) (range-1L));
-  return(offset);
-}
-
-static inline CLQuantum ClampToQuantum(const float value)
-{
-  if (value < 0.0)
-    return((CLQuantum) 0);
-  if (value >= (float) QuantumRange)
-    return((CLQuantum) QuantumRange);
-  return((CLQuantum) (value+0.5));
-}
-
-__kernel void Convolve(const __global CLPixelType *source,__constant float *filter,
-  const ulong width,const ulong height,__global CLPixelType *destination)
-{
-  const ulong columns = get_global_size(0);
-  const ulong rows = get_global_size(1);
-
-  const long x = get_global_id(0);
-  const long y = get_global_id(1);
-
-  const float scale = (1.0/QuantumRange);
-  const long mid_width = (width-1)/2;
-  const long mid_height = (height-1)/2;
-  float4 sum = { 0.0, 0.0, 0.0, 0.0 };
-  float gamma = 0.0;
-  register ulong i = 0;
-
-  for (long v=(-mid_height); v <= mid_height; v++)
-  {
-    for (long u=(-mid_width); u <= mid_width; u++)
-    {
-      register const ulong index=ClampToCanvas(y+v,rows)*columns+ClampToCanvas(x+u,
-        columns);
-      const float alpha=scale*(QuantumRange-source[index].w);
-      sum.x+=alpha*filter[i]*source[index].x;
-      sum.y+=alpha*filter[i]*source[index].y;
-      sum.z+=alpha*filter[i]*source[index].z;
-      sum.w+=filter[i]*source[index].w;
-      gamma+=alpha*filter[i];
-      i++;
-    }
-  }
-
-  gamma=1.0/(fabs(gamma) <= MagickEpsilon ? 1.0 : gamma);
-  const ulong index=y*columns+x;
-  destination[index].x=ClampToQuantum(gamma*sum.x);
-  destination[index].y=ClampToQuantum(gamma*sum.y);
-  destination[index].z=ClampToQuantum(gamma*sum.z);
-  destination[index].w=ClampToQuantum(sum.w);
-};
- -

See magick/accelerate.c for a complete implementation of image convolution with an OpenCL kernel.

- -

Note, that under Windows, you might have an issue with TDR (Timeout Detection and Recovery of GPUs). Its purpose is to detect runaway tasks hanging the GPU by using an execution time threshold. For some older low-end GPUs running the OpenCL filters in ImageMagick, longer execution times might trigger the TDR mechanism and pre-empt the GPU image filter. When this happens, ImageMagick automatically falls back to the CPU code path and returns the expected results. To avoid pre-emption, increase the TdrDelay registry key.

- -

Custom Image Coders

- -

An image coder (i.e. encoder / decoder) is responsible for registering, optionally classifying, optionally reading, optionally writing, and unregistering one image format (e.g. PNG, GIF, JPEG, etc.). Registering an image coder alerts ImageMagick a particular format is available to read or write. While unregistering tells ImageMagick the format is no longer available. The classifying method looks at the first few bytes of an image and determines if the image is in the expected format. The reader sets the image size, colorspace, and other properties and loads the pixel cache with the pixels. The reader returns a single image or an image sequence (if the format supports multiple images per file), or if an error occurs, an exception and a null image. The writer does the reverse. It takes the image properties and unloads the pixel cache and writes them as required by the image format.

- -

Here is a listing of a sample custom coder. It reads and writes images in the MGK image format which is simply an ID followed by the image width and height followed by the RGB pixel values.

- -
/*
-  Include declarations.
-*/
-#include "magick/studio.h"
-#include "magick/blob.h"
-#include "magick/blob-private.h"
-#include "magick/colorspace.h"
-#include "magick/exception.h"
-#include "magick/exception-private.h"
-#include "magick/image.h"
-#include "magick/image-private.h"
-#include "magick/list.h"
-#include "magick/magick.h"
-#include "magick/memory_.h"
-#include "magick/monitor.h"
-#include "magick/monitor-private.h"
-#include "magick/quantum-private.h"
-#include "magick/static.h"
-#include "magick/string_.h"
-#include "magick/module.h"
-
-/*
-  Forward declarations.
-*/
-static MagickBooleanType
-  WriteMGKImage(const ImageInfo *,Image *);
-
-/*
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%   I s M G K                                                                 %
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%
-%  IsMGK() returns MagickTrue if the image format type, identified by the
-%  magick string, is MGK.
-%
-%  The format of the IsMGK method is:
-%
-%      MagickBooleanType IsMGK(const unsigned char *magick,const size_t length)
-%
-%  A description of each parameter follows:
-%
-%    o magick: This string is generally the first few bytes of an image file
-%      or blob.
-%
-%    o length: Specifies the length of the magick string.
-%
-*/
-static MagickBooleanType IsMGK(const unsigned char *magick,const size_t length)
-{
-  if (length < 7)
-    return(MagickFalse);
-  if (LocaleNCompare((char *) magick,"id=mgk",7) == 0)
-    return(MagickTrue);
-  return(MagickFalse);
-}
-
-/*
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%   R e a d M G K I m a g e                                                   %
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%
-%  ReadMGKImage() reads a MGK image file and returns it.  It allocates
-%  the memory necessary for the new Image structure and returns a pointer to
-%  the new image.
-%
-%  The format of the ReadMGKImage method is:
-%
-%      Image *ReadMGKImage(const ImageInfo *image_info,ExceptionInfo *exception)
-%
-%  A description of each parameter follows:
-%
-%    o image_info: the image info.
-%
-%    o exception: return any errors or warnings in this structure.
-%
-*/
-static Image *ReadMGKImage(const ImageInfo *image_info,
-  ExceptionInfo *exception)
-{
-  char
-    buffer[MaxTextExtent];
-
-  Image
-    *image;
-
-  MagickBooleanType
-    status;
-
-  register PixelPacket
-    *q;
-
-  register size_t
-    x;
-
-  register unsigned char
-    *p;
-
-  ssize_t
-    count,
-    y;
-
-  unsigned char
-    *pixels;
-
-  unsigned long
-    columns,
-    rows;
-
-  /*
-    Open image file.
-  */
-  assert(image_info != (const ImageInfo *) NULL);
-  assert(image_info->signature == MagickSignature);
-  if (image_info->debug != MagickFalse)
-    (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image_info->filename);
-  assert(exception != (ExceptionInfo *) NULL);
-  assert(exception->signature == MagickSignature);
-  image=AcquireImage(image_info);
-  status=OpenBlob(image_info,image,ReadBinaryBlobMode,exception);
-  if (status == MagickFalse)
-    {
-      image=DestroyImageList(image);
-      return((Image *) NULL);
-    }
-  /*
-    Read MGK image.
-  */
-  (void) ReadBlobString(image,buffer);  /* read magic number */
-  if (IsMGK(buffer,7) == MagickFalse)
-    ThrowReaderException(CorruptImageError,"ImproperImageHeader");
-  (void) ReadBlobString(image,buffer);
-  count=(ssize_t) sscanf(buffer,"%lu %lu\n",&columns,&rows);
-  if (count <= 0)
-    ThrowReaderException(CorruptImageError,"ImproperImageHeader");
-  do
-  {
-    /*
-      Initialize image structure.
-    */
-    image->columns=columns;
-    image->rows=rows;
-    image->depth=8;
-    if ((image_info->ping != MagickFalse) && (image_info->number_scenes != 0))
-      if (image->scene >= (image_info->scene+image_info->number_scenes-1))
-        break;
-    /*
-      Convert MGK raster image to pixel packets.
-    */
-    if (SetImageExtent(image,0,0) == MagickFalse)
-      {
-        InheritException(exception,&image->exception);
-        return(DestroyImageList(image));
-      }
-    pixels=(unsigned char *) AcquireQuantumMemory((size_t) image->columns,3UL*sizeof(*pixels));
-    if (pixels == (unsigned char *) NULL)
-      ThrowReaderException(ResourceLimitError,"MemoryAllocationFailed");
-    for (y=0; y < (ssize_t) image->rows; y++)
-    {
-      count=(ssize_t) ReadBlob(image,(size_t) (3*image->columns),pixels);
-      if (count != (ssize_t) (3*image->columns))
-        ThrowReaderException(CorruptImageError,"UnableToReadImageData");
-      p=pixels;
-      q=QueueAuthenticPixels(image,0,y,image->columns,1,exception);
-      if (q == (PixelPacket *) NULL)
-        break;
-      for (x=0; x < (ssize_t) image->columns; x++)
-      {
-        SetPixelRed(q,ScaleCharToQuantum(*p++));
-        SetPixelGreen(q,ScaleCharToQuantum(*p++));
-        SetPixelBlue(q,ScaleCharToQuantum(*p++));
-        q++;
-      }
-      if (SyncAuthenticPixels(image,exception) == MagickFalse)
-        break;
-      if ((image->previous == (Image *) NULL) &&
-          (SetImageProgress(image,LoadImageTag,y,image>>rows) == MagickFalse))
-        break;
-    }
-    pixels=(unsigned char *) RelinquishMagickMemory(pixels);
-    if (EOFBlob(image) != MagickFalse)
-      {
-        ThrowFileException(exception,CorruptImageError,"UnexpectedEndOfFile",image->filename);
-        break;
-      }
-    /*
-      Proceed to next image.
-    */
-    if (image_info->number_scenes != 0)
-      if (image->scene >= (image_info->scene+image_info->number_scenes-1))
-        break;
-    *buffer='\0';
-    (void) ReadBlobString(image,buffer);
-    count=(ssize_t) sscanf(buffer,"%lu %lu\n",&columns,&rows);
-    if (count != 0)
-      {
-        /*
-          Allocate next image structure.
-        */
-        AcquireNextImage(image_info,image);
-        if (GetNextImageInList(image) == (Image *) NULL)
-          {
-            image=DestroyImageList(image);
-            return((Image *) NULL);
-          }
-        image=SyncNextImageInList(image);
-        status=SetImageProgress(image,LoadImageTag,TellBlob(image),GetBlobSize(image));
-        if (status == MagickFalse)
-          break;
-      }
-  } while (count != 0);
-  (void) CloseBlob(image);
-  return(GetFirstImageInList(image));
-}
-
-/*
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%   R e g i s t e r M G K I m a g e                                           %
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%
-%  RegisterMGKImage() adds attributes for the MGK image format to
-%  the list of supported formats.  The attributes include the image format
-%  tag, a method to read and/or write the format, whether the format
-%  supports the saving of more than one frame to the same file or blob,
-%  whether the format supports native in-memory I/O, and a brief
-%  description of the format.
-%
-%  The format of the RegisterMGKImage method is:
-%
-%      unsigned long RegisterMGKImage(void)
-%
-*/
-ModuleExport unsigned long RegisterMGKImage(void)
-{
-  MagickInfo
-    *entry;
-
-  entry=SetMagickInfo("MGK");
-  entry->decoder=(DecodeImageHandler *) ReadMGKImage;
-  entry->encoder=(EncodeImageHandler *) WriteMGKImage;
-  entry->magick=(IsImageFormatHandler *) IsMGK;
-  entry->description=ConstantString("MGK");
-  entry->module=ConstantString("MGK");
-  (void) RegisterMagickInfo(entry);
-  return(MagickImageCoderSignature);
-}
-
-/*
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%   U n r e g i s t e r M G K I m a g e                                       %
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%
-%  UnregisterMGKImage() removes format registrations made by the
-%  MGK module from the list of supported formats.
-%
-%  The format of the UnregisterMGKImage method is:
-%
-%      UnregisterMGKImage(void)
-%
-*/
-ModuleExport void UnregisterMGKImage(void)
-{
-  (void) UnregisterMagickInfo("MGK");
-}
-
-/*
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%   W r i t e M G K I m a g e                                                 %
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%
-%  WriteMGKImage() writes an image to a file in red, green, and blue
-%  MGK rasterfile format.
-%
-%  The format of the WriteMGKImage method is:
-%
-%      MagickBooleanType WriteMGKImage(const ImageInfo *image_info,Image *image)
-%
-%  A description of each parameter follows.
-%
-%    o image_info: the image info.
-%
-%    o image:  The image.
-%
-*/
-static MagickBooleanType WriteMGKImage(const ImageInfo *image_info,Image *image)
-{
-  char
-    buffer[MaxTextExtent];
-
-  MagickBooleanType
-    status;
-
-  MagickOffsetType
-    scene;
-
-  register const PixelPacket
-    *p;
-
-  register ssize_t
-    x;
-
-  register unsigned char
-    *q;
-
-  ssize_t
-    y;
-
-  unsigned char
-    *pixels;
-
-  /*
-    Open output image file.
-  */
-  assert(image_info != (const ImageInfo *) NULL);
-  assert(image_info->signature == MagickSignature);
-  assert(image != (Image *) NULL);
-  assert(image->signature == MagickSignature);
-  if (image->debug != MagickFalse)
-    (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename);
-  status=OpenBlob(image_info,image,WriteBinaryBlobMode,&image->exception);
-  if (status == MagickFalse)
-    return(status);
-  scene=0;
-  do
-  {
-    /*
-      Allocate memory for pixels.
-    */
-    if (image->colorspace != RGBColorspace)
-      (void) SetImageColorspace(image,RGBColorspace);
-    pixels=(unsigned char *) AcquireQuantumMemory((size_t) image->columns,
-      3UL*sizeof(*pixels));
-    if (pixels == (unsigned char *) NULL)
-      ThrowWriterException(ResourceLimitError,"MemoryAllocationFailed");
-    /*
-      Initialize raster file header.
-    */
-    (void) WriteBlobString(image,"id=mgk\n");
-    (void) FormatLocaleString(buffer,MaxTextExtent,"%lu %lu\n",
-      image->columns,image->rows);
-    (void) WriteBlobString(image,buffer);
-    for (y=0; y < (ssize_t) image->rows; y++)
-    {
-      p=GetVirtualPixels(image,0,y,image->columns,1,&image->exception);
-      if (p == (const PixelPacket *) NULL)
-        break;
-      q=pixels;
-      for (x=0; x < (ssize_t) image->columns; x++)
-      {
-        *q++=ScaleQuantumToChar(GetPixelRed(p));
-        *q++=ScaleQuantumToChar(GetPixelGreen(p));
-        *q++=ScaleQuantumToChar(GetPixelBlue(p));
-        p++;
-      }
-      (void) WriteBlob(image,(size_t) (q-pixels),pixels);
-      if ((image->previous == (Image *) NULL) &&
-          (SetImageProgress(image,SaveImageTag,y,image->rows) == MagickFalse))
-        break;
-    }
-    pixels=(unsigned char *) RelinquishMagickMemory(pixels);
-    if (GetNextImageInList(image) == (Image *) NULL)
-      break;
-    image=SyncNextImageInList(image);
-    status=SetImageProgress(image,SaveImagesTag,scene,
-      GetImageListLength(image));
-    if (status == MagickFalse)
-      break;
-    scene++;
-  } while (image_info->adjoin != MagickFalse);
-  (void) CloseBlob(image);
-  return(MagickTrue);
-}
- -

To invoke the custom coder from the command line, use these commands:

- -
convert logo: logo.mgk
-display logo.mgk
-
- -

We provide the Magick Coder Kit to help you get started writing your own custom coder.

- -

Custom Image Filters

- -

ImageMagick provides a convenient mechanism for adding your own custom image processing algorithms. We call these image filters and they are invoked from the command line with the -process option or from the MagickCore API method ExecuteModuleProcess().

- -

Here is a listing of a sample custom image filter. It computes a few statistics such as the pixel brightness and saturation mean and standard-deviation.

- -
#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <time.h>
-#include <assert.h>
-#include <math.h>
-#include "magick/MagickCore.h"
-
-/*
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%   a n a l y z e I m a g e                                                   %
-%                                                                             %
-%                                                                             %
-%                                                                             %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%
-%  analyzeImage() computes the brightness and saturation mean,  standard
-%  deviation, kurtosis and skewness and stores these values as attributes
-%  of the image.
-%
-%  The format of the analyzeImage method is:
-%
-%      size_t analyzeImage(Image *images,const int argc,char **argv,
-%        ExceptionInfo *exception)
-%
-%  A description of each parameter follows:
-%
-%    o image: the address of a structure of type Image.
-%
-%    o argc: Specifies a pointer to an integer describing the number of
-%      elements in the argument vector.
-%
-%    o argv: Specifies a pointer to a text array containing the command line
-%      arguments.
-%
-%    o exception: return any errors or warnings in this structure.
-%
-*/
-ModuleExport size_t analyzeImage(Image **images,const int argc,const char **argv,
-  ExceptionInfo *exception)
-{
-  char
-    text[MaxTextExtent];
-
-  double
-    area,
-    brightness,
-    brightness_mean,
-    brightness_standard_deviation,
-    brightness_kurtosis,
-    brightness_skewness,
-    brightness_sum_x,
-    brightness_sum_x2,
-    brightness_sum_x3,
-    brightness_sum_x4,
-    hue,
-    saturation,
-    saturation_mean,
-    saturation_standard_deviation,
-    saturation_kurtosis,
-    saturation_skewness,
-    saturation_sum_x,
-    saturation_sum_x2,
-    saturation_sum_x3,
-    saturation_sum_x4;
-
-  Image
-    *image;
-
-  assert(images != (Image **) NULL);
-  assert(*images != (Image *) NULL);
-  assert((*images)->signature == MagickSignature);
-  (void) argc;
-  (void) argv;
-  image=(*images);
-  for ( ; image != (Image *) NULL; image=GetNextImageInList(image))
-  {
-    CacheView
-      *image_view;
-
-    MagickBooleanType
-      status;
-
-    ssize_t
-      y;
-
-    brightness_sum_x=0.0;
-    brightness_sum_x2=0.0;
-    brightness_sum_x3=0.0;
-    brightness_sum_x4=0.0;
-    brightness_mean=0.0;
-    brightness_standard_deviation=0.0;
-    brightness_kurtosis=0.0;
-    brightness_skewness=0.0;
-    saturation_sum_x=0.0;
-    saturation_sum_x2=0.0;
-    saturation_sum_x3=0.0;
-    saturation_sum_x4=0.0;
-    saturation_mean=0.0;
-    saturation_standard_deviation=0.0;
-    saturation_kurtosis=0.0;
-    saturation_skewness=0.0;
-    area=0.0;
-    status=MagickTrue;
-    image_view=AcquireVirtualCacheView(image,exception);
-#if defined(MAGICKCORE_OPENMP_SUPPORT)
-    #pragma omp parallel for schedule(dynamic,4) shared(status)
-#endif
-    for (y=0; y < (ssize_t) image->rows; y++)
-    {
-      register const PixelPacket
-        *p;
-
-      register ssize_t
-        x;
-
-      if (status == MagickFalse)
-        continue;
-      p=GetCacheViewVirtualPixels(image_view,0,y,image->columns,1,exception);
-      if (p == (const PixelPacket *) NULL)
-        {
-          status=MagickFalse;
-          continue;
-        }
-      for (x=0; x < (ssize_t) image->columns; x++)
-      {
-        ConvertRGBToHSB(GetPixelRed(p),GetPixelGreen(p),GetPixelBue(p),&hue,&saturation,&brightness);
-        brightness*=QuantumRange;
-        brightness_sum_x+=brightness;
-        brightness_sum_x2+=brightness*brightness;
-        brightness_sum_x3+=brightness*brightness*brightness;
-        brightness_sum_x4+=brightness*brightness*brightness*brightness;
-        saturation*=QuantumRange;
-        saturation_sum_x+=saturation;
-        saturation_sum_x2+=saturation*saturation;
-        saturation_sum_x3+=saturation*saturation*saturation;
-        saturation_sum_x4+=saturation*saturation*saturation*saturation;
-        area++;
-        p++;
-      }
-    }
-    image_view=DestroyCacheView(image_view);
-    if (area <= 0.0)
-      break;
-    brightness_mean=brightness_sum_x/area;
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",brightness_mean);
-    (void) SetImageProperty(image,"filter:brightness:mean",text);
-    brightness_standard_deviation=sqrt(brightness_sum_x2/area-(brightness_sum_x/
-      area*brightness_sum_x/area));
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",
-      brightness_standard_deviation);
-    (void) SetImageProperty(image,"filter:brightness:standard-deviation",text);
-    if (brightness_standard_deviation != 0)
-      brightness_kurtosis=(brightness_sum_x4/area-4.0*brightness_mean*
-        brightness_sum_x3/area+6.0*brightness_mean*brightness_mean*
-        brightness_sum_x2/area-3.0*brightness_mean*brightness_mean*
-        brightness_mean*brightness_mean)/(brightness_standard_deviation*
-        brightness_standard_deviation*brightness_standard_deviation*
-        brightness_standard_deviation)-3.0;
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",brightness_kurtosis);
-    (void) SetImageProperty(image,"filter:brightness:kurtosis",text);
-    if (brightness_standard_deviation != 0)
-      brightness_skewness=(brightness_sum_x3/area-3.0*brightness_mean*
-        brightness_sum_x2/area+2.0*brightness_mean*brightness_mean*
-        brightness_mean)/(brightness_standard_deviation*
-        brightness_standard_deviation*brightness_standard_deviation);
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",brightness_skewness);
-    (void) SetImageProperty(image,"filter:brightness:skewness",text);
-    saturation_mean=saturation_sum_x/area;
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",saturation_mean);
-    (void) SetImageProperty(image,"filter:saturation:mean",text);
-    saturation_standard_deviation=sqrt(saturation_sum_x2/area-(saturation_sum_x/
-      area*saturation_sum_x/area));
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",
-      saturation_standard_deviation);
-    (void) SetImageProperty(image,"filter:saturation:standard-deviation",text);
-    if (saturation_standard_deviation != 0)
-      saturation_kurtosis=(saturation_sum_x4/area-4.0*saturation_mean*
-        saturation_sum_x3/area+6.0*saturation_mean*saturation_mean*
-        saturation_sum_x2/area-3.0*saturation_mean*saturation_mean*
-        saturation_mean*saturation_mean)/(saturation_standard_deviation*
-        saturation_standard_deviation*saturation_standard_deviation*
-        saturation_standard_deviation)-3.0;
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",saturation_kurtosis);
-    (void) SetImageProperty(image,"filter:saturation:kurtosis",text);
-    if (saturation_standard_deviation != 0)
-      saturation_skewness=(saturation_sum_x3/area-3.0*saturation_mean*
-        saturation_sum_x2/area+2.0*saturation_mean*saturation_mean*
-        saturation_mean)/(saturation_standard_deviation*
-        saturation_standard_deviation*saturation_standard_deviation);
-    (void) FormatLocaleString(text,MaxTextExtent,"%g",saturation_skewness);
-    (void) SetImageProperty(image,"filter:saturation:skewness",text);
-  }
-  return(MagickImageFilterSignature);
-}
- -

To invoke the custom filter from the command line, use this command:

- -
convert logo: -process \"analyze\" -verbose info:
-  Image: logo:
-    Format: LOGO (ImageMagick Logo)
-    Class: PseudoClass
-    Geometry: 640x480
-    ...
-    filter:brightness:kurtosis: 8.17947
-    filter:brightness:mean: 60632.1
-    filter:brightness:skewness: -2.97118
-    filter:brightness:standard-deviation: 13742.1
-    filter:saturation:kurtosis: 4.33554
-    filter:saturation:mean: 5951.55
-    filter:saturation:skewness: 2.42848
-    filter:saturation:standard-deviation: 15575.9
-
- - -

We provide the Magick Filter Kit to help you get started writing your own custom image filter.

- -
- -
- - - -
- - diff --git a/ImageMagick-7.0.0-0/www/binary-releases.html b/ImageMagick-7.0.0-0/www/binary-releases.html deleted file mode 100644 index 029b6221b..000000000 --- a/ImageMagick-7.0.0-0/www/binary-releases.html +++ /dev/null @@ -1,459 +0,0 @@ - - - - - - - - - ImageMagick: Install from Binary Distribution - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
-

Unix Binary Release • Mac OS X Binary Release • iOS Binary Release • Windows Binary Release

- -

You can install ImageMagick from source. However, if don't have a proper development environment or if you're anxious to get started, download a ready-to-run Unix or Windows executable. Before you download, you may want to review recent changes to the ImageMagick distribution.

- -

Unix Binary Release

- -

These are the Unix variations that we support. If your system is not on the list, try installing from source. Although ImageMagick runs fine on a single core computer, it automagically runs in parallel on dual and quad-core systems reducing run times considerably.

- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
VersionHTTPFTPDescription
ImageMagick-7.0.0-0.x86_64.rpmdownloaddownloadRedhat / CentOS 7.1 x86_64 RPM
ImageMagick-7.0.0-0.i386.rpmdownloaddownloadRedhat / CentOS 5.11 i386 RPM
ImageMagick RPM'sdownloaddownloadDevelopment, Perl, C++, and documentation RPM's.
ImageMagick-sparc-sun-solaris2.10.tar.gzdownloaddownloadSolaris Sparc 2.10
ImageMagick-i686-pc-cygwin.tar.gzdownloaddownloadCygwin
ImageMagick-i686-pc-mingw32.tar.gzdownloaddownloadMinGW
- -

Verify its message digest.

- -

ImageMagick RPM's are self-installing. Simply type the following command and you're ready to start using ImageMagick:

- -
 rpm -Uvh ImageMagick-7.0.0-0.i386.rpm
-

For other systems, create (or choose) a directory to install the package into and change to that directory, for example:

- -
-cd $HOME
-
- -

Next, extract the contents of the package. For example:

- -
-tar xvzf ImageMagick.tar.gz
-
- -

Set the MAGICK_HOME environment variable to the path where you extracted the ImageMagick files. For example:

- -
 export MAGICK_HOME="$HOME/ImageMagick-7.0.0"
-

If the bin subdirectory of the extracted package is not already in your executable search path, add it to your PATH environment variable. For example:

- -
-export PATH="$MAGICK_HOME/bin:$PATH
-
- - -

On Linux and Solaris machines add $MAGICK_HOME/lib to the LD_LIBRARY_PATH environment variable:

- -
-LD_LIBRARY_PATH="${LD_LIBRARY_PATH:+$LD_LIBRARY_PATH:}$MAGICK_HOME/lib
-export LD_LIBRARY_PATH
-
- -

Finally, to verify ImageMagick is working properly, type the following on the command line:

- -
-convert logo: logo.gif
-identify logo.gif
-display logo.gif
-
- -

Congratulations, you have a working ImageMagick distribution under Unix or Linux and you are ready to use ImageMagick to convert, compose, or edit your images or perhaps you'll want to use one of the Application Program Interfaces for C, C++, Perl, and others.

- -

Mac OS X Binary Release

- -

We recommend MacPorts which custom builds ImageMagick in your environment (some users prefer Homebrew). Download MacPorts and type:

- -
-sudo port install ImageMagick
-
- -

The port command downloads ImageMagick and many of its delegate libraries (e.g. JPEG, PNG, Freetype, etc.) and configures, builds, and installs ImageMagick automagically. Alternatively, you can download the ImageMagick Mac OS X distribution we provide:

- -
- - - - - - - - - - - - - - - -
VersionHTTPFTPDescription
ImageMagick-x86_64-apple-darwin15.0.0.tar.gzdownloaddownloadMac OS X El Capitan
- -

Verify its message digest.

- -

Create (or choose) a directory to install the package into and change to that directory, for example:

- -
-cd $HOME
-
- -

Next, extract the contents of the package. For example:

- -
-tar xvzf ImageMagick-x86_64-apple-darwin15.0.0.tar.gz
-
- -

Set the MAGICK_HOME environment variable to the path where you extracted the ImageMagick files. For example:

- -
 export MAGICK_HOME="$HOME/ImageMagick-7.0.0"
-

If the bin subdirectory of the extracted package is not already in your executable search path, add it to your PATH environment variable. For example:

- -
-export PATH="$MAGICK_HOME/bin:$PATH"
-
- - -

Set the DYLD_LIBRARY_PATH environment variable:

- -
-export DYLD_LIBRARY_PATH="$MAGICK_HOME/lib/"
-
- -

Finally, to verify ImageMagick is working properly, type the following on the command line:

- -
-convert logo: logo.gif
-identify logo.gif
-display logo.gif
-
- -

Note, the display program requires the X11 server available on your Mac OS X installation DVD. Once that is installed, you will also need to export DISPLAY=:0.

- -

The best way to deal with all the exports is to put them at the end of your .profile file

- -

Congratulations, you have a working ImageMagick distribution under Mac OS X and you are ready to use ImageMagick to convert, compose, or edit your images or perhaps you'll want to use one of the Application Program Interfaces for C, C++, Perl, and others.

- -

iOS Binary Release

- -

~Claudio provides iOS builds of ImageMagick.

- -

Download iOS Distribution

- -

You can download the iOS distribution directly from ImageMagick's repository.

- -

There are always 2 packages for the compiled ImageMagick:

- -
    -
  • iOSMagick-VERSION-libs.zip
  • -
  • iOSMagick-VERSION.zip
  • -
- -

The first one includes headers and compiled libraries that have been used to compile ImageMagick. Most users would need this one.

- -

ImageMagick compiling script for iOS OS and iOS Simulator

- -

To run the script:

-
-./imagemagick_compile.sh VERSION
-
-

where VERSION is the version of ImageMagick you want to compile (i.e.: 7.0.0-0, svn, ...)

- -

This script compiles ImageMagick as a static library to be included in iOS projects and adds support for

-
    -
  • png
  • -
  • jpeg
  • -
  • tiff
  • -
- -

Upon successful compilation a folder called IMPORT_ME is created on your ~/Desktop. You can import it into your XCode project.

- -
XCode project settings
- -

After including everything into XCode please also make sure to have these settings (Build tab of the project information):

-
    -
  • Other Linker Flags: -lMagickCore-Q16 -lMagickWand-Q16 -ljpeg -lpng -lbz2 -lz
  • -
  • Header Search Paths: $(SRCROOT) - make it Recursive
  • -
  • Library Search Paths: $(SRCROOT) - make it Recursive
  • -
- -

On the lower left click on the small-wheel and select: Add User-Defined Setting

-
    -
  • Key: OTHER_CFLAGS
  • -
  • Value: -Dmacintosh=1
  • -
- -
Sample project
- -

A sample project is available for download. It is not updated too often, but it does give an idea of all the settings and some ways to play around with ImageMagick in an iOS application.

- -

Windows Binary Release

- -

ImageMagick runs on Windows 8 (x86 & x64), Windows 7 (x86 & x64), Windows Server 2012, Windows XP (x86) with Service Pack 3, Windows Vista (x86 & x64) with Service Pack 2, Windows Server 2003 (x86 & x64) with Service Pack 2 (verify MSXML6 is present), Windows Server 2003 R2 (x86 & x64), Windows Server 2008 (x86 & x64) with Service Pack 2, and Windows Server 2008 R2 (x64).

- -

The amount of memory can be an important factor, especially if you intend to work on large images. A minimum of 512 MB of RAM is recommended, but the more RAM the better. Although ImageMagick runs well on a single core computer, it automagically runs in parallel on multi-core systems reducing run times considerably.

- -

The Windows version of ImageMagick is self-installing. Simply click on the appropriate version below and it will launch itself and ask you a few installation questions. Versions with Q8 in the name are 8 bits-per-pixel component (e.g. 8-bit red, 8-bit green, etc.), whereas, Q16 in the filename are 16 bits-per-pixel component. A Q16 version permits you to read or write 16-bit images without losing precision but requires twice as much resources as the Q8 version. Versions with dll in the filename include ImageMagick libraries as dynamic link libraries. Unless you have a Windows 32-bit OS, we recommend this version of ImageMagick for 64-bit Windows:

- -
- - - - - - - - - - - - - - - -
VersionHTTPFTPDescription
ImageMagick-7.0.0-0-Q16-x64-dll.exedownloaddownloadWin64 dynamic at 16 bits-per-pixel
- -

Or choose from these alternate Windows binary distributions:

- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
VersionHTTPFTPDescription
ImageMagick-7.0.0-0-Q16-x64-static.exedownloaddownloadWin64 static at 16 bits-per-pixel
ImageMagick-7.0.0-0-Q8-x64-dll.exedownloaddownloadWin64 dynamic at 8 bits-per-pixel
ImageMagick-7.0.0-0-Q8-x64-static.exedownloaddownloadWin64 static at 8 bits-per-pixel
ImageMagick-7.0.0-0-Q16-HDRI-x64-dll.exedownloaddownloadWin64 dynamic at 16 bits-per-pixel with high dynamic-range imaging enabled
ImageMagick-7.0.0-0-Q16-HDRI-x64-static.exedownloaddownloadWin64 static at 16 bits-per-pixel with high dynamic-range imaging enabled
ImageMagick-7.0.0-0-Q16-x86-dll.exedownloaddownloadWin32 dynamic at 16 bits-per-pixel
ImageMagick-7.0.0-0-Q16-x86-static.exedownloaddownloadWin32 static at 16 bits-per-pixel
ImageMagick-7.0.0-0-Q8-x86-dll.exedownloaddownloadWin32 dynamic at 8 bits-per-pixel
ImageMagick-7.0.0-0-Q8-x86-static.exedownloaddownloadWin32 static at 8 bits-per-pixel
ImageMagick-7.0.0-0-Q16-HDRI-x86-dll.exedownloaddownloadWin32 dynamic at 16 bits-per-pixel with high dynamic-range imaging enabled
ImageMagick-7.0.0-0-Q16-HDRI-x86-static.exedownloaddownloadWin32 static at 16 bits-per-pixel with high dynamic-range imaging enabled
ImageMagick-7.0.0-0-portable-Q16-x86.zipdownloaddownloadPortable Win32 static at 16 bits-per-pixel. Just copy to your host and run (no installer, no Windows registry entries).
ImageMagick-7.0.0-0-portable-Q16-x64.zipdownloaddownloadPortable Win64 static at 16 bits-per-pixel. Just copy to your host and run (no installer, no Windows registry entries).
- -

Verify its message digest.

- -

To verify ImageMagick is working properly, type the following in an Command Prompt window:

- -
-convert logo: logo.gif
-identify logo.gif
-imdisplay
-
- -

If you have any problems, you likely need vcomp120.dll. To install it, download Visual C++ 2013 Redistributable Package.

- -

Note, use a double quote (") rather than a single quote (') for the ImageMagick command line under Windows:

- -
-convert "e:/myimages/image.png" "e:/myimages/image.jpg"
-
-

Use two double quotes for VBScript scripts:

-
-Set objShell = wscript.createobject("wscript.shell")
-objShell.Exec("convert ""e:/myimages/image.png"" ""e:/myimages/image.jpg""")
-
- -

Congratulations, you have a working ImageMagick distribution under Windows and you are ready to use ImageMagick to convert, compose, or edit your images or perhaps you'll want to use one of the Application Program Interfaces for C, C++, Perl, and others.

- -
- - -
- - - -
- - diff --git a/ImageMagick-7.0.0-0/www/changelog.html b/ImageMagick-7.0.0-0/www/changelog.html deleted file mode 100644 index b0c81cf28..000000000 --- a/ImageMagick-7.0.0-0/www/changelog.html +++ /dev/null @@ -1,89 +0,0 @@ - - - - - - - - - ImageMagick: Changelog - - - - - - - - - - - - - - - - - - - - -
-
-
- - - -
-
-
-
2012-04-27 7.0.0-0 Anthony thyssen <A.Thyssen@griffith...>
-
  • Allow the use of set and escapes when no images in memory (unless you attempt to access per-image meta-data) Currently does not include %[fx:...] and %[pixel:...]
  • -
    2012-10-05 7.0.0-0 Anthony thyssen <A.Thyssen@griffith...>
    -
  • Rather than replicate 'options' into 'artifacts' make a link from image to image_info and lookup a global option if no artifact is defined.
  • -
    2012-09-11 7.0.0-0 Nicolas Robidoux <nicolas.robidoux@gmail...>
    -
  • sigmoidal-contrast:
  • -
  • Remove unnecessary initial ClampToQuantum.
  • -
    2012-09-10 7.0.0-0 Nicolas Robidoux <nicolas.robidoux@gmail...>
    -
  • sigmoidal-contrast:
  • -
  • Direct computation, without LUT;
  • -
  • Fix re-declaration of i (at the top, and inside a conditional).
  • -
    2012-09-04 7.0.0-0 Nicolas Robidoux <nicolas.robidoux@gmail...>
    -
  • Add tanh/atanh clone of legacy sigmoidal map (faster & more accurate).
  • -
    2012-08-08 7.0.0-0 Nicolas Robidoux <nicolas.robidoux@gmail...>
    -
  • Add final ClampToQuantum in sigmoidal colormap loop.
  • -
  • Remove OpenMP calls from colormap update loops.
  • -
    2011-08-01 7.0.0-0 Cristy <quetzlzacatenango@image...>
    -
  • New version 7.0.0-0.
  • -
    -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/cipher.html b/ImageMagick-7.0.0-0/www/cipher.html deleted file mode 100644 index de65f7f17..000000000 --- a/ImageMagick-7.0.0-0/www/cipher.html +++ /dev/null @@ -1,136 +0,0 @@ - - - - - - - - - ImageMagick: Encipher or Decipher an Image - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Encipher an Image • Decipher an Image • Encipher and Decipher Caveats

    - -

    Most images, by design, are made to be viewed often and by many people. Web images, for example, may be viewed hundreds of times a day by a multitude of vistors. However, in some cases, you may want to keep a particular image private so that only you or perhaps a select group of your friends or web visitors can view it. ImageMagick permits you to scramble your images such that unless someone knows your passphrase, they will be unable to view the original content.

    - -

    You could use an enciphering utility to scramble your image but they typically scramble the entire file making it unrecognizable as an image format. With ImageMagick, only the pixels are scrambled. The scrambled image continues to be recognized as an image and will even display in your web page. However, the content appears as gibberish, nothing like the original content.

    - -

    Encipher an Image

    - -

    Use the -encipher option to scramble your image so that it is unrecognizable. The option requires a filename that contains your passphrase. In this example we scramble an image and save it in the PNG format:

    - -
    -convert rose.jpg -encipher passphrase.txt rose.png
    -
    - -

    Here we encipher an image using another image as the passphrase:

    - -
    -convert rose.jpg -encipher smiley.gif rose.png
    -
    - -

    Decipher an Image

    - -

    Use the -decipher option to unscramble your image so that it is recognizable once again. The option requires a filename that contains your passphrase. In this example we unscramble an image and save it in the JPEG format:

    - -
    -convert rose.png -decipher passphrase.txt rose.jpg
    -
    - -

    Encipher and Decipher Caveats

    - -

    Some formats do not support enciphered pixels-- the JPEG or GIF format, for -example. To ensure your image format is supported, encipher a test image and -verify you can restore its original content before you encipher any -additional images in that format.

    - -

    The image format may only support 8-bit and RGB (TrueColor). As such you may -like to include the options "-depth 8 -type TrueColor" before the output -filename.

    - -

    The passphrase can be any combinations of letters and symbols. It should -be a minimum of 12 character combinations to help ensure your image remains -private. Also make sure your passphrase file permissions prevent others from -reading it otherwise unintended users may be able to view the original image -content.

    - -

    You can only restore the original image content if you know your -passphrase. If you lose or forget it, your original image content is lost -forever.

    - -

    ImageMagick only scrambles the image pixels. The image metadata remains -untouched and readable by anyone with access to the image file.

    - -

    ImageMagick uses the AES -cipher in Counter mode. We use the the first half of your passphrase to derive the nonce. The second half is the cipher key. When used correctly, AES-CTR provides a high level of confidentiality. To avoid information leaks, you must use a fresh passphrase for each image your encrypt.

    - -

    Currently only ImageMagick can restore your enciphered image content. We -use a standard cipher and mode so other vendors are could support enciphered image content.

    - -

    Some small practical examples of image enciphering can be found in IM -Examples Encrypting Image Data.

    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/color-management.html b/ImageMagick-7.0.0-0/www/color-management.html deleted file mode 100644 index 485b7f8c7..000000000 --- a/ImageMagick-7.0.0-0/www/color-management.html +++ /dev/null @@ -1,146 +0,0 @@ - - - - - - - - - ImageMagick: Color Management - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    Color management has changed significantly between ImageMagick version 6.7.5-5 and 6.8.0-3 in order to better conform to color and grayscale standards.

    - -

    The first major change was to swap -colorspace RGB and -colorspace sRGB. In earlier versions, RGB really meant non-linear sRGB. With the completion of the changes, RGB now means linear color and sRGB means non-linear color in terms of their respective colorspaces.

    - -

    ImageMagick supports color profiles, however, for images without a profile or a declaration of colorspace, ImageMagick assumes non-linear sRGB. Most image processing algorithms assume a linear colorspace, therefore it might be prudent to convert to linear color or remove the gamma function before certain image processing algorithms are applied. For example,

    - -
    -convert myimage.jpg -colorspace RGB -resize 200% -colorspace sRGB mybigimage.jpg
    -
    - -

    To declare that an image is linear RGB rather than sRGB, you can use the set option:

    - -
    -convert myimage.png -set colorspace RGB myRGBimage.png
    -
    - -

    Afterwards, the verbose information for the output file lists the colorspace as RGB. This only works on image types containing meta data that distinguishes between linear RGB and non-linear sRGB, such as PNG and GIF. Therefore, if the above command is run with a JPG or TIF output format, the verbose information for the colorspace still shows sRGB. In order to properly have the JPG output know that it is linear RGB, include an appropriate color profile.

    - - -

    The second major change treats any grayscale image as linear rather than non-linear, as it was previously. This change is appropriate, since many types of processing requires a linear colorspace. This means that the conversion of a color image to grayscale via -colorspace gray looks darker relative to previous versions of ImageMagick (note that desaturating to convert to grayscale does not convert the image to linear grayscale). If you prefer to keep the conversion to non-linear grayscale, set the colorspace of the input to linear RGB so that -colorspace gray does not apply the gamma correction during the conversion process. For example, the following produces a non-linear grayscale result.

    - -
    -convert myimage.png -set colorspace RGB -colorspace gray myRGBimage.png
    -
    - -

    The same concept is needed when separating channels. Normally, the conversion to separate each channel of an sRGB color image produces separate linear grayscale images. However the same concept can be applied, if it is desired to keep the separate channels as non-linear grayscale. For example, the following produces non-linear grayscale channels.

    - -
    -convert myimage.png -set colorspace RGB -separate myimage_channels_%d.png
    -
    - -

    When separating and recombining channels, with potential intermediate processing, it is important to identify the colorspace used, especially during the recombination. For example,

    - -
    -convert myimage.png -separate myimage_channels_%d.png
    -convert myimage_channels_*.png -combine myimage2.png
    -
    - -

    In the above example, the result is darker than the original, because the channels were separate as linear gray and subsequently combined as linear color. In order to return the channels back to sRGB, one must change the colorspace from RGB back to sRGB after the -combine step.

    - -
    -convert myimage.png -separate myimage_channels_%d.png
    -convert myimage_channels_*.png -combine -colorspace sRGB myimage2.png
    -
    - -

    If one desires to separate to non-linear grayscale channels, recombine them later, perhaps after some processing, then use the same concept as above for maintaining non-linear grayscale:

    - -
    -convert myimage.png -set colorspace RGB -separate myimage_channels_%d.png
    -convert myimage_channels_*.png -combine -colorspace RGB -set colorspace sRGB myimage2.png
    -
    - -

    When converting to another colorspace and back, such as between sRGB and HSL, the following two commands handle the first case of linear channels and the second case of non-linear channels:

    - -
    -convert myimage.png -colorspace HSL -separate myimage_channels_%d.png
    -convert myimage_channels_*.png -set colorspace HSL -combine -colorspace sRGB myimage2.png
    -
    - -
    -convert myimage.png -set colorspace RGB -colorspace HSL -separate myimage_channels_%d.png
    -convert myimage_channels_*.png -set colorspace HSL -combine -colorspace RGB -set colorspace sRGB myimage2.png
    -
    - -

    A majority of the image formats assume an sRGB colorspace (e.g. JPEG, PNG, etc.). A few support only linear RGB (e.g. EXR, DPX, CIN, HDR) or only linear GRAY (e.g. PGM). A few formats support CMYK. For example JPG does, but PNG does not. Then there is the occasional format that also supports LAB (that is CieLAB) (e.g. TIFF, PSD, JPG, JP2). For additional information, see the Colorspace and Supported Formats pages.

    - -

    When specifying individual colors as rgb(...) or hex, these colors will still be interpreted as non-linear, that is, as sRGB colors. However if one wants to create linear colors, use icc-color(rgb,r,g,b)", where r, g, and b are in the range 0 to 1. See the Color page.

    - -

    There are now also distinctions between linear and non-linear shades of gray. Any named shade of gray, such as black, white or numbered grays like gray50 are non-linear gray. However, gray(...) is now linear gray. Hex grayscale values are non-linear.

    - -

    This means that you need to be careful when you create grayscale gradients. For example, gradient:, gradient:"white-black", gradient:"gray100-gray0" generates non-linear gradients, however gradient:"gray(255)-gray(0)" or gradient:"gray(100%)-gray(0%)" generates linear gradients.

    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/color.html b/ImageMagick-7.0.0-0/www/color.html deleted file mode 100644 index 31e9c3956..000000000 --- a/ImageMagick-7.0.0-0/www/color.html +++ /dev/null @@ -1,4947 +0,0 @@ - - - - - - - - - ImageMagick: Color Names - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Color Model Specification • List of Color Names

    - -

    A number of ImageMagick options and methods take a color as an argument. The color can then be given as a color name (there is a limited but large set of these; see below) or it can be given as a set of numbers (in decimal or hexadecimal), each corresponding to a channel in an RGB or RGBA color model. HSL, HSLA, HSB, HSBA, CMYK, or CMYKA color models may also be specified. These topics are briefly described in the sections below.

    - -

    Use the Color Converter to supply any valid ImageMagick color specification as described below to see a color swatch of that color and to convert to all the other color models.

    - -

    Example Usage

    - -

    Each of the following commands produces the same lime border around the image. (Use "double quotes" for Windows.)

    - -
    -convert -bordercolor lime -border 10 image.jpg image.png
    -convert -bordercolor '#0f0' -border 10 image.jpg image.png
    -convert -bordercolor '#00ff00' -border 10 image.jpg image.png
    -convert -bordercolor 'rgb(0,255,0)' -border 10 image.jpg image.png
    -convert -bordercolor 'rgb(0,100%,0)' -border 10 image.jpg image.png
    -
    - -

    The list of recognized color names (for example, aqua, black, blue, fuchsia, gray, green, lime, maroon, navy, olive, purple, red, silver, teal, white, yellow, and others) is shown in a table further below.

    - -

    Color Model Specification

    - -

    The sRGB, CMYK, HSL and HSB color models are used in numerical color specifications. These examples all specify the same red sRGB color:

    - -
    -#f00                      #rgb
    -#ff0000                   #rrggbb
    -#ff0000ff                 #rrggbbaa
    -#ffff00000000             #rrrrggggbbbb
    -#ffff00000000ffff         #rrrrggggbbbbaaaa
    -rgb(255, 0, 0)            an integer in the range 0—255 for each component
    -rgb(100.0%, 0.0%, 0.0%)   a float in the range 0—100% for each component
    -
    - -

    The format of an sRGB value in hexadecimal notation is a '#' immediately followed by either three, six, or twelve hexadecimal characters. The three-digit sRGB notation (#rgb) is converted into six-digit form (#rrggbb) by replicating digits, not by adding zeros. For example, #fb0 expands to #ffbb00. This ensures that white (#ffffff) can be specified with the short notation (#fff) and removes any dependencies on the color depth of the image. Use the hexadecimal notation whenever performance is an issue. ImageMagick does not need to load the expansive color table to interpret a hexadecimal color, e.g., #000000, but it does if black is used instead.

    - -

    The format of an sRGB value in the functional notation is 'rgb(r,g,b)', where r, g, and b are either three integer or float values in the range 0—255 or three integer or float percentage values in the range 0—100%. The value 255 corresponds to 100%, and to #F or #FF in the hexadecimal notation: rgb(255, 255, 255) = rgb(100%, 100%, 100%) = #FFF = #FFFFFF.

    - -

    White space characters are allowed around the numerical values, at least if the entire color argument is enclosed in quotes ('single quotes' for Unix-like systems, "double quotes" for Windows).

    - -

    The sRGB color model is extended in this specification to include alpha to allow specification of the transparency of a color. These examples all specify the same color:

    - -
    -rgb(255, 0, 0)                 range 0 - 255
    -rgba(255, 0, 0, 1.0)           the same, with an explicit alpha value
    -rgb(100%, 0%, 0%)              range 0.0% - 100.0%
    -rgba(100%, 0%, 0%, 1.0)        the same, with an explicit alpha value
    -
    - -

    The format of an RGBA value in the functional notation is 'rgba(r,g,b,a)', where r, g, and b are as described above for the RGB functional notation, and where the alpha value a ranges from 0.0 (fully transparent) to 1.0 (fully opaque).

    - -

    There is also a color called 'none' that is fully transparent. This color is shorthand for rgba(0, 0, 0, 0.0).

    - -

    Gray values are conveniently defined with a single intensity value or an intensity value and an alpha value:

    - -
    -gray(50%)        mid gray
    -graya(50%, 0.5)  semi-transparent mid gray
    -
    - -

    The ImageMagick color model also supports hue-saturation-lightness (HSL) and hue-saturation-brightness (HSB) colors as a complement to numerical sRGB colors. HSL colors are encoding as a triple (hue, saturation, lightness). Likewise HSB colors are encoding as a triple (hue, saturation, brightness). HSL or HSB triples are either direct values (hue 0—360, saturation 0—255, ligthness or brightness 0—255) or as percentage values relative to these ranges.

    - -

    The HSB color system is geometrically represented as a cone with its apex pointing downward. Hue is measured around the perimeter. Saturation is measured from the axis outward. Brightness is measured from the apex upward.

    - -

    The HSL color system is geometrically represented as a stacked double cone with one apex pointing downward and the other pointing upward. The widest ends of both cones are stacked together one on top of the other. Hue is measured around the perimeter. Saturation is measured from the axis outward. Lightness is measured from the bottom apex upward.

    - -

    See http://en.wikipedia.org/wiki/HSL_and_HSV for more details on HSL and HSB color systems.

    - -

    Hue is represented as an angle of the color around the circular perimeter of the cone(s) (i.e. the rainbow represented in a circle). Hue values are either integer or floats in the range 0—360 or integer or float percentage values in the range 0—100%. By definition red=0=360 (or 0%=100%), and the other colors are spread around the circle, so green=120 (or 33.3333%), blue=240 (or (66.6667%), etc. As an angle, it implicitly wraps around such that -120=240 and 480=120, for instance. (Students of trigonometry would say that "coterminal angles are equivalent" here; an angle θ can be standardized by computing the equivalent angle, θ mod 360.)

    - -

    Saturation is measure outward from the central axis of the cone(s) toward the perimeter of the cone(s). Saturation may be expressed as an integer or float in the range 0—255 or as an integer or float percentage in the range 0—100. Saturation may be thought of as the absence of any "white" mixed with the base color. Thus 255 or 100% is full saturation and corresponds to a point on the outside surface of the cone (HSB) or double cone (HSL). It will be the most "colorful" region. 0 or 0% is no saturation which results in some shade of gray. It occurs along the central axis of the cone or double cone with black at the bottom apex and white at the top.

    - -

    Brightness and Lightness also may be represented as integers or floats in the range 0—255 or as integer or float percentages in the range 0—100%. Brightness and Lightness are measured from the bottom apex upward to the top of the cone or double cone along the cone(s) central axis. 0 or 0% corresponds to the bottom apex and 255 or 100% corresponds to the top center of the cone for Brightness and to the top apex of the double cone for Lightness.

    - -

    The HSB color system is a little easier to understand than the HSL color system. In the HSB color system, black is at the bottom apex and white is at the top center of the cone on the central axis. The most colorful or saturated colors will then be at the outer edge of the top of the cone at the widest part. Thus at Saturation=100% and Brightness=100%

    - -
    -hsb(0%, 100%,  100%)          or    hsb(0, 255,  255)          full red
    -hsb(33.3333%, 100%,  100%)    or    hsb(120, 255,   255)       full green
    -hsb(33.3333%, 100%,  75%)     or    hsb(120, 255,   191.25)    medium green
    -hsb(33.3333%, 100%,  50%)     or    hsb(120, 255,   127.5)     dark green
    -hsb(33.3333%, 100%,  25%)     or    hsb(120, 255,   63.75)     very dark green
    -hsb(33.3333%, 50%,   50%)     or    hsb(120, 127.5, 127.5)     pastel green
    -
    - -

    In the HSL color system, black is at the bottom apex and white is at the top apex. However, saturation is largest at the middle of the double cone on its outer perimeter and thus at a lightness value of 50%. The most colorful or saturated colors will then be at the outer edge of the double cone at its widest part. Thus at Saturation=100% and Brightness=50%

    - -
    -hsl(0%, 100%,  50%)           or    hsl(0, 255,  127.5)        full red
    -hsl(33.3333%, 100%,  100%)    or    hsl(120, 255,   255)       white
    -hsl(33.3333%, 100%,  75%)     or    hsl(120, 255,   191.25)    pastel green
    -hsl(33.3333%, 100%,  50%)     or    hsl(120, 255,   127.5)     full green
    -hsl(33.3333%, 100%,  25%)     or    hsl(120, 255,   63.75)     dark green
    -hsl(33.3333%, 50%,   50%)     or    hsl(120, 127.5, 127.5)     medium green
    -
    - -

    One advantage of HSB or HSL over RGB is that it can be more intuitive: you can guess at the colors you want, and then tweak. It is also easier to create sets of matching colors (by keeping the hue the same and varying the brightness or lightness and saturation, for example).

    - -

    Just as the 'rgb()' functional notation has the 'rgba()' alpha counterpart, the 'hsl()' and 'hsb()' functional notations have their 'hsla()' 'hsba()' alpha counterparts. These examples specify the same color:

    - -
    -hsb(33.3333%, 100%,  100%)         full green in hsb
    -hsba(33.3333%, 100%,  100%,  1.0)  the same, with an alpha value of 1.0
    -hsb(120, 255,  255)                full green in hsb
    -hsba(120, 255,  255,  1.0)         the same, with an alpha value of 1.0
    -
    -hsl(33.3333%, 100%,  50%)          full green in hsl
    -hsla(33.3333%, 100%,  50%,  1.0)   the same, with an alpha value of 1.0
    -hsl(120, 255,  127.5)              full green in hsl
    -hsla(120, 255,  127.5,  1.0)       the same, with an alpha value of 1.0
    -
    - -

    Prior to ImageMagick 6.5.6-6, HSL (HSB) could only be specified with Hue in range 0—360, but Saturation and Lightness (Brightness) as percent in range 0—100%.

    - -

    Specify the Lab colors like this:

    -
    -cielab(62.253188, 23.950124, 48.410653)
    -
    -

    Note, the a and b components of any Lab color you specify are biased internally by 50% to ensure it fits in the quantum range (typically 0 to 65535). The bias is retained when writing to the TIFF and MIFF image formats. However, the TXT format supports negative pixel values so the bias is removed when writing to this format:

    -
    --> convert xc:cyan -colorspace LAB txt:
    -# ImageMagick pixel enumeration: 1,1,65535,cielab
    -0,0: (91.1131%,-18.8571%,-5.5436%)  #E93F00000000  cielab(91.1131%,-18.8571%,-5.5436%)
    -
    --> convert -size 100x100 xc:"cielab(91.1131%,-18.8571%,-5.5436%)" -colorspace sRGB cyan.png
    -
    - -

    Or specify colors generically with the icc-color keyword, for example:

    -
    -icc-color(cmyk, 0.11, 0.48, 0.83, 0.00)
    -icc-color(rgb, white)
    -
    - -

    Or specify uncalibrated device colors with the device- keyword, for example:

    -
    -device-gray(0.5)
    -device-rgb(0.5, 1.0, 0.0)
    -device-cmyk(0.11, 0.48, 0.83, 0.00)
    -
    - -

    List of Color Names

    - -

    The table below provides a list of named colors recognized by ImageMagick:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameColorRGBHex
    snowsnowrgb(255, 250, 250)#FFFAFA
    snow1snow1rgb(255, 250, 250)#FFFAFA
    snow2snow2rgb(238, 233, 233)#EEE9E9
    RosyBrown1RosyBrown1rgb(255, 193, 193)#FFC1C1
    RosyBrown2RosyBrown2rgb(238, 180, 180)#EEB4B4
    snow3snow3rgb(205, 201, 201)#CDC9C9
    LightCoralLightCoralrgb(240, 128, 128)#F08080
    IndianRed1IndianRed1rgb(255, 106, 106)#FF6A6A
    RosyBrown3RosyBrown3rgb(205, 155, 155)#CD9B9B
    IndianRed2IndianRed2rgb(238, 99, 99)#EE6363
    RosyBrownRosyBrownrgb(188, 143, 143)#BC8F8F
    brown1brown1rgb(255, 64, 64)#FF4040
    firebrick1firebrick1rgb(255, 48, 48)#FF3030
    brown2brown2rgb(238, 59, 59)#EE3B3B
    IndianRedIndianRedrgb(205, 92, 92)#CD5C5C
    IndianRed3IndianRed3rgb(205, 85, 85)#CD5555
    firebrick2firebrick2rgb(238, 44, 44)#EE2C2C
    snow4snow4rgb(139, 137, 137)#8B8989
    brown3brown3rgb(205, 51, 51)#CD3333
    redredrgb(255, 0, 0)#FF0000
    red1red1rgb(255, 0, 0)#FF0000
    RosyBrown4RosyBrown4rgb(139, 105, 105)#8B6969
    firebrick3firebrick3rgb(205, 38, 38)#CD2626
    red2red2rgb(238, 0, 0)#EE0000
    firebrickfirebrickrgb(178, 34, 34)#B22222
    brownbrownrgb(165, 42, 42)#A52A2A
    red3red3rgb(205, 0, 0)#CD0000
    IndianRed4IndianRed4rgb(139, 58, 58)#8B3A3A
    brown4brown4rgb(139, 35, 35)#8B2323
    firebrick4firebrick4rgb(139, 26, 26)#8B1A1A
    DarkRedDarkRedrgb(139, 0, 0)#8B0000
    red4red4rgb(139, 0, 0)#8B0000
    maroonmaroon (SVG compliance)rgb(128, 0, 0)#800000
    LightPink1LightPink1rgb(255, 174, 185)#FFAEB9
    LightPink3LightPink3rgb(205, 140, 149)#CD8C95
    LightPink4LightPink4rgb(139, 95, 101)#8B5F65
    LightPink2LightPink2rgb(238, 162, 173)#EEA2AD
    LightPinkLightPinkrgb(255, 182, 193)#FFB6C1
    pinkpinkrgb(255, 192, 203)#FFC0CB
    crimsoncrimsonrgb(220, 20, 60)#DC143C
    pink1pink1rgb(255, 181, 197)#FFB5C5
    pink2pink2rgb(238, 169, 184)#EEA9B8
    pink3pink3rgb(205, 145, 158)#CD919E
    pink4pink4rgb(139, 99, 108)#8B636C
    PaleVioletRed4PaleVioletRed4rgb(139, 71, 93)#8B475D
    PaleVioletRedPaleVioletRedrgb(219, 112, 147)#DB7093
    PaleVioletRed2PaleVioletRed2rgb(238, 121, 159)#EE799F
    PaleVioletRed1PaleVioletRed1rgb(255, 130, 171)#FF82AB
    PaleVioletRed3PaleVioletRed3rgb(205, 104, 137)#CD6889
    LavenderBlushLavenderBlushrgb(255, 240, 245)#FFF0F5
    LavenderBlush1LavenderBlush1rgb(255, 240, 245)#FFF0F5
    LavenderBlush3LavenderBlush3rgb(205, 193, 197)#CDC1C5
    LavenderBlush2LavenderBlush2rgb(238, 224, 229)#EEE0E5
    LavenderBlush4LavenderBlush4rgb(139, 131, 134)#8B8386
    maroonmaroon (X11 compliance)rgb(176, 48, 96)#B03060
    HotPink3HotPink3rgb(205, 96, 144)#CD6090
    VioletRed3VioletRed3rgb(205, 50, 120)#CD3278
    VioletRed1VioletRed1rgb(255, 62, 150)#FF3E96
    VioletRed2VioletRed2rgb(238, 58, 140)#EE3A8C
    VioletRed4VioletRed4rgb(139, 34, 82)#8B2252
    HotPink2HotPink2rgb(238, 106, 167)#EE6AA7
    HotPink1HotPink1rgb(255, 110, 180)#FF6EB4
    HotPink4HotPink4rgb(139, 58, 98)#8B3A62
    HotPinkHotPinkrgb(255, 105, 180)#FF69B4
    DeepPinkDeepPinkrgb(255, 20, 147)#FF1493
    DeepPink1DeepPink1rgb(255, 20, 147)#FF1493
    DeepPink2DeepPink2rgb(238, 18, 137)#EE1289
    DeepPink3DeepPink3rgb(205, 16, 118)#CD1076
    DeepPink4DeepPink4rgb(139, 10, 80)#8B0A50
    maroon1maroon1rgb(255, 52, 179)#FF34B3
    maroon2maroon2rgb(238, 48, 167)#EE30A7
    maroon3maroon3rgb(205, 41, 144)#CD2990
    maroon4maroon4rgb(139, 28, 98)#8B1C62
    MediumVioletRedMediumVioletRedrgb(199, 21, 133)#C71585
    VioletRedVioletRedrgb(208, 32, 144)#D02090
    orchid2orchid2rgb(238, 122, 233)#EE7AE9
    orchidorchidrgb(218, 112, 214)#DA70D6
    orchid1orchid1rgb(255, 131, 250)#FF83FA
    orchid3orchid3rgb(205, 105, 201)#CD69C9
    orchid4orchid4rgb(139, 71, 137)#8B4789
    thistle1thistle1rgb(255, 225, 255)#FFE1FF
    thistle2thistle2rgb(238, 210, 238)#EED2EE
    plum1plum1rgb(255, 187, 255)#FFBBFF
    plum2plum2rgb(238, 174, 238)#EEAEEE
    thistlethistlergb(216, 191, 216)#D8BFD8
    thistle3thistle3rgb(205, 181, 205)#CDB5CD
    plumplumrgb(221, 160, 221)#DDA0DD
    violetvioletrgb(238, 130, 238)#EE82EE
    plum3plum3rgb(205, 150, 205)#CD96CD
    thistle4thistle4rgb(139, 123, 139)#8B7B8B
    fuchsiafuchsiargb(255, 0, 255)#FF00FF
    magentamagentargb(255, 0, 255)#FF00FF
    magenta1magenta1rgb(255, 0, 255)#FF00FF
    plum4plum4rgb(139, 102, 139)#8B668B
    magenta2magenta2rgb(238, 0, 238)#EE00EE
    magenta3magenta3rgb(205, 0, 205)#CD00CD
    DarkMagentaDarkMagentargb(139, 0, 139)#8B008B
    magenta4magenta4rgb(139, 0, 139)#8B008B
    purplepurple (SVG compliance)rgb(128, 0, 128)#800080
    MediumOrchidMediumOrchidrgb(186, 85, 211)#BA55D3
    MediumOrchid1MediumOrchid1rgb(224, 102, 255)#E066FF
    MediumOrchid2MediumOrchid2rgb(209, 95, 238)#D15FEE
    MediumOrchid3MediumOrchid3rgb(180, 82, 205)#B452CD
    MediumOrchid4MediumOrchid4rgb(122, 55, 139)#7A378B
    DarkVioletDarkVioletrgb(148, 0, 211)#9400D3
    DarkOrchidDarkOrchidrgb(153, 50, 204)#9932CC
    DarkOrchid1DarkOrchid1rgb(191, 62, 255)#BF3EFF
    DarkOrchid3DarkOrchid3rgb(154, 50, 205)#9A32CD
    DarkOrchid2DarkOrchid2rgb(178, 58, 238)#B23AEE
    DarkOrchid4DarkOrchid4rgb(104, 34, 139)#68228B
    purplepurple (X11 compliance)rgb(160, 32, 240)#A020F0
    indigoindigorgb( 75, 0, 130)#4B0082
    BlueVioletBlueVioletrgb(138, 43, 226)#8A2BE2
    purple2purple2rgb(145, 44, 238)#912CEE
    purple3purple3rgb(125, 38, 205)#7D26CD
    purple4purple4rgb( 85, 26, 139)#551A8B
    purple1purple1rgb(155, 48, 255)#9B30FF
    MediumPurpleMediumPurplergb(147, 112, 219)#9370DB
    MediumPurple1MediumPurple1rgb(171, 130, 255)#AB82FF
    MediumPurple2MediumPurple2rgb(159, 121, 238)#9F79EE
    MediumPurple3MediumPurple3rgb(137, 104, 205)#8968CD
    MediumPurple4MediumPurple4rgb( 93, 71, 139)#5D478B
    DarkSlateBlueDarkSlateBluergb( 72, 61, 139)#483D8B
    LightSlateBlueLightSlateBluergb(132, 112, 255)#8470FF
    MediumSlateBlueMediumSlateBluergb(123, 104, 238)#7B68EE
    SlateBlueSlateBluergb(106, 90, 205)#6A5ACD
    SlateBlue1SlateBlue1rgb(131, 111, 255)#836FFF
    SlateBlue2SlateBlue2rgb(122, 103, 238)#7A67EE
    SlateBlue3SlateBlue3rgb(105, 89, 205)#6959CD
    SlateBlue4SlateBlue4rgb( 71, 60, 139)#473C8B
    GhostWhiteGhostWhitergb(248, 248, 255)#F8F8FF
    lavenderlavenderrgb(230, 230, 250)#E6E6FA
    bluebluergb( 0, 0, 255)#0000FF
    blue1blue1rgb( 0, 0, 255)#0000FF
    blue2blue2rgb( 0, 0, 238)#0000EE
    blue3blue3rgb( 0, 0, 205)#0000CD
    MediumBlueMediumBluergb( 0, 0, 205)#0000CD
    blue4blue4rgb( 0, 0, 139)#00008B
    DarkBlueDarkBluergb( 0, 0, 139)#00008B
    MidnightBlueMidnightBluergb( 25, 25, 112)#191970
    navynavyrgb( 0, 0, 128)#000080
    NavyBlueNavyBluergb( 0, 0, 128)#000080
    RoyalBlueRoyalBluergb( 65, 105, 225)#4169E1
    RoyalBlue1RoyalBlue1rgb( 72, 118, 255)#4876FF
    RoyalBlue2RoyalBlue2rgb( 67, 110, 238)#436EEE
    RoyalBlue3RoyalBlue3rgb( 58, 95, 205)#3A5FCD
    RoyalBlue4RoyalBlue4rgb( 39, 64, 139)#27408B
    CornflowerBlueCornflowerBluergb(100, 149, 237)#6495ED
    LightSteelBlueLightSteelBluergb(176, 196, 222)#B0C4DE
    LightSteelBlue1LightSteelBlue1rgb(202, 225, 255)#CAE1FF
    LightSteelBlue2LightSteelBlue2rgb(188, 210, 238)#BCD2EE
    LightSteelBlue3LightSteelBlue3rgb(162, 181, 205)#A2B5CD
    LightSteelBlue4LightSteelBlue4rgb(110, 123, 139)#6E7B8B
    SlateGray4SlateGray4rgb(108, 123, 139)#6C7B8B
    SlateGray1SlateGray1rgb(198, 226, 255)#C6E2FF
    SlateGray2SlateGray2rgb(185, 211, 238)#B9D3EE
    SlateGray3SlateGray3rgb(159, 182, 205)#9FB6CD
    LightSlateGrayLightSlateGrayrgb(119, 136, 153)#778899
    LightSlateGreyLightSlateGreyrgb(119, 136, 153)#778899
    SlateGraySlateGrayrgb(112, 128, 144)#708090
    SlateGreySlateGreyrgb(112, 128, 144)#708090
    DodgerBlueDodgerBluergb( 30, 144, 255)#1E90FF
    DodgerBlue1DodgerBlue1rgb( 30, 144, 255)#1E90FF
    DodgerBlue2DodgerBlue2rgb( 28, 134, 238)#1C86EE
    DodgerBlue4DodgerBlue4rgb( 16, 78, 139)#104E8B
    DodgerBlue3DodgerBlue3rgb( 24, 116, 205)#1874CD
    AliceBlueAliceBluergb(240, 248, 255)#F0F8FF
    SteelBlue4SteelBlue4rgb( 54, 100, 139)#36648B
    SteelBlueSteelBluergb( 70, 130, 180)#4682B4
    SteelBlue1SteelBlue1rgb( 99, 184, 255)#63B8FF
    SteelBlue2SteelBlue2rgb( 92, 172, 238)#5CACEE
    SteelBlue3SteelBlue3rgb( 79, 148, 205)#4F94CD
    SkyBlue4SkyBlue4rgb( 74, 112, 139)#4A708B
    SkyBlue1SkyBlue1rgb(135, 206, 255)#87CEFF
    SkyBlue2SkyBlue2rgb(126, 192, 238)#7EC0EE
    SkyBlue3SkyBlue3rgb(108, 166, 205)#6CA6CD
    LightSkyBlueLightSkyBluergb(135, 206, 250)#87CEFA
    LightSkyBlue4LightSkyBlue4rgb( 96, 123, 139)#607B8B
    LightSkyBlue1LightSkyBlue1rgb(176, 226, 255)#B0E2FF
    LightSkyBlue2LightSkyBlue2rgb(164, 211, 238)#A4D3EE
    LightSkyBlue3LightSkyBlue3rgb(141, 182, 205)#8DB6CD
    SkyBlueSkyBluergb(135, 206, 235)#87CEEB
    LightBlue3LightBlue3rgb(154, 192, 205)#9AC0CD
    DeepSkyBlueDeepSkyBluergb( 0, 191, 255)#00BFFF
    DeepSkyBlue1DeepSkyBlue1rgb( 0, 191, 255)#00BFFF
    DeepSkyBlue2DeepSkyBlue2rgb( 0, 178, 238)#00B2EE
    DeepSkyBlue4DeepSkyBlue4rgb( 0, 104, 139)#00688B
    DeepSkyBlue3DeepSkyBlue3rgb( 0, 154, 205)#009ACD
    LightBlue1LightBlue1rgb(191, 239, 255)#BFEFFF
    LightBlue2LightBlue2rgb(178, 223, 238)#B2DFEE
    LightBlueLightBluergb(173, 216, 230)#ADD8E6
    LightBlue4LightBlue4rgb(104, 131, 139)#68838B
    PowderBluePowderBluergb(176, 224, 230)#B0E0E6
    CadetBlue1CadetBlue1rgb(152, 245, 255)#98F5FF
    CadetBlue2CadetBlue2rgb(142, 229, 238)#8EE5EE
    CadetBlue3CadetBlue3rgb(122, 197, 205)#7AC5CD
    CadetBlue4CadetBlue4rgb( 83, 134, 139)#53868B
    turquoise1turquoise1rgb( 0, 245, 255)#00F5FF
    turquoise2turquoise2rgb( 0, 229, 238)#00E5EE
    turquoise3turquoise3rgb( 0, 197, 205)#00C5CD
    turquoise4turquoise4rgb( 0, 134, 139)#00868B
    cadet bluecadet bluergb( 95, 158, 160)#5F9EA0
    CadetBlueCadetBluergb( 95, 158, 160)#5F9EA0
    DarkTurquoiseDarkTurquoisergb( 0, 206, 209)#00CED1
    azureazurergb(240, 255, 255)#F0FFFF
    azure1azure1rgb(240, 255, 255)#F0FFFF
    LightCyanLightCyanrgb(224, 255, 255)#E0FFFF
    LightCyan1LightCyan1rgb(224, 255, 255)#E0FFFF
    azure2azure2rgb(224, 238, 238)#E0EEEE
    LightCyan2LightCyan2rgb(209, 238, 238)#D1EEEE
    PaleTurquoise1PaleTurquoise1rgb(187, 255, 255)#BBFFFF
    PaleTurquoisePaleTurquoisergb(175, 238, 238)#AFEEEE
    PaleTurquoise2PaleTurquoise2rgb(174, 238, 238)#AEEEEE
    DarkSlateGray1DarkSlateGray1rgb(151, 255, 255)#97FFFF
    azure3azure3rgb(193, 205, 205)#C1CDCD
    LightCyan3LightCyan3rgb(180, 205, 205)#B4CDCD
    DarkSlateGray2DarkSlateGray2rgb(141, 238, 238)#8DEEEE
    PaleTurquoise3PaleTurquoise3rgb(150, 205, 205)#96CDCD
    DarkSlateGray3DarkSlateGray3rgb(121, 205, 205)#79CDCD
    azure4azure4rgb(131, 139, 139)#838B8B
    LightCyan4LightCyan4rgb(122, 139, 139)#7A8B8B
    aquaaquargb( 0, 255, 255)#00FFFF
    cyancyanrgb( 0, 255, 255)#00FFFF
    cyan1cyan1rgb( 0, 255, 255)#00FFFF
    PaleTurquoise4PaleTurquoise4rgb(102, 139, 139)#668B8B
    cyan2cyan2rgb( 0, 238, 238)#00EEEE
    DarkSlateGray4DarkSlateGray4rgb( 82, 139, 139)#528B8B
    cyan3cyan3rgb( 0, 205, 205)#00CDCD
    cyan4cyan4rgb( 0, 139, 139)#008B8B
    DarkCyanDarkCyanrgb( 0, 139, 139)#008B8B
    tealtealrgb( 0, 128, 128)#008080
    DarkSlateGrayDarkSlateGrayrgb( 47, 79, 79)#2F4F4F
    DarkSlateGreyDarkSlateGreyrgb( 47, 79, 79)#2F4F4F
    MediumTurquoiseMediumTurquoisergb( 72, 209, 204)#48D1CC
    LightSeaGreenLightSeaGreenrgb( 32, 178, 170)#20B2AA
    turquoiseturquoisergb( 64, 224, 208)#40E0D0
    aquamarine4aquamarine4rgb( 69, 139, 116)#458B74
    aquamarineaquamarinergb(127, 255, 212)#7FFFD4
    aquamarine1aquamarine1rgb(127, 255, 212)#7FFFD4
    aquamarine2aquamarine2rgb(118, 238, 198)#76EEC6
    aquamarine3aquamarine3rgb(102, 205, 170)#66CDAA
    MediumAquamarineMediumAquamarinergb(102, 205, 170)#66CDAA
    MediumSpringGreenMediumSpringGreenrgb( 0, 250, 154)#00FA9A
    MintCreamMintCreamrgb(245, 255, 250)#F5FFFA
    SpringGreenSpringGreenrgb( 0, 255, 127)#00FF7F
    SpringGreen1SpringGreen1rgb( 0, 255, 127)#00FF7F
    SpringGreen2SpringGreen2rgb( 0, 238, 118)#00EE76
    SpringGreen3SpringGreen3rgb( 0, 205, 102)#00CD66
    SpringGreen4SpringGreen4rgb( 0, 139, 69)#008B45
    MediumSeaGreenMediumSeaGreenrgb( 60, 179, 113)#3CB371
    SeaGreenSeaGreenrgb( 46, 139, 87)#2E8B57
    SeaGreen3SeaGreen3rgb( 67, 205, 128)#43CD80
    SeaGreen1SeaGreen1rgb( 84, 255, 159)#54FF9F
    SeaGreen4SeaGreen4rgb( 46, 139, 87)#2E8B57
    SeaGreen2SeaGreen2rgb( 78, 238, 148)#4EEE94
    MediumForestGreenMediumForestGreenrgb( 50, 129, 75)#32814B
    honeydewhoneydewrgb(240, 255, 240)#F0FFF0
    honeydew1honeydew1rgb(240, 255, 240)#F0FFF0
    honeydew2honeydew2rgb(224, 238, 224)#E0EEE0
    DarkSeaGreen1DarkSeaGreen1rgb(193, 255, 193)#C1FFC1
    DarkSeaGreen2DarkSeaGreen2rgb(180, 238, 180)#B4EEB4
    PaleGreen1PaleGreen1rgb(154, 255, 154)#9AFF9A
    PaleGreenPaleGreenrgb(152, 251, 152)#98FB98
    honeydew3honeydew3rgb(193, 205, 193)#C1CDC1
    LightGreenLightGreenrgb(144, 238, 144)#90EE90
    PaleGreen2PaleGreen2rgb(144, 238, 144)#90EE90
    DarkSeaGreen3DarkSeaGreen3rgb(155, 205, 155)#9BCD9B
    DarkSeaGreenDarkSeaGreenrgb(143, 188, 143)#8FBC8F
    PaleGreen3PaleGreen3rgb(124, 205, 124)#7CCD7C
    honeydew4honeydew4rgb(131, 139, 131)#838B83
    green1green1rgb( 0, 255, 0)#00FF00
    limelimergb( 0, 255, 0)#00FF00
    LimeGreenLimeGreenrgb( 50, 205, 50)#32CD32
    DarkSeaGreen4DarkSeaGreen4rgb(105, 139, 105)#698B69
    green2green2rgb( 0, 238, 0)#00EE00
    PaleGreen4PaleGreen4rgb( 84, 139, 84)#548B54
    green3green3rgb( 0, 205, 0)#00CD00
    ForestGreenForestGreenrgb( 34, 139, 34)#228B22
    green4green4rgb( 0, 139, 0)#008B00
    greengreenrgb( 0, 128, 0)#008000
    DarkGreenDarkGreenrgb( 0, 100, 0)#006400
    LawnGreenLawnGreenrgb(124, 252, 0)#7CFC00
    chartreusechartreusergb(127, 255, 0)#7FFF00
    chartreuse1chartreuse1rgb(127, 255, 0)#7FFF00
    chartreuse2chartreuse2rgb(118, 238, 0)#76EE00
    chartreuse3chartreuse3rgb(102, 205, 0)#66CD00
    chartreuse4chartreuse4rgb( 69, 139, 0)#458B00
    GreenYellowGreenYellowrgb(173, 255, 47)#ADFF2F
    DarkOliveGreen3DarkOliveGreen3rgb(162, 205, 90)#A2CD5A
    DarkOliveGreen1DarkOliveGreen1rgb(202, 255, 112)#CAFF70
    DarkOliveGreen2DarkOliveGreen2rgb(188, 238, 104)#BCEE68
    DarkOliveGreen4DarkOliveGreen4rgb(110, 139, 61)#6E8B3D
    DarkOliveGreenDarkOliveGreenrgb( 85, 107, 47)#556B2F
    OliveDrabOliveDrabrgb(107, 142, 35)#6B8E23
    OliveDrab1OliveDrab1rgb(192, 255, 62)#C0FF3E
    OliveDrab2OliveDrab2rgb(179, 238, 58)#B3EE3A
    OliveDrab3OliveDrab3rgb(154, 205, 50)#9ACD32
    YellowGreenYellowGreenrgb(154, 205, 50)#9ACD32
    OliveDrab4OliveDrab4rgb(105, 139, 34)#698B22
    ivoryivoryrgb(255, 255, 240)#FFFFF0
    ivory1ivory1rgb(255, 255, 240)#FFFFF0
    LightYellowLightYellowrgb(255, 255, 224)#FFFFE0
    LightYellow1LightYellow1rgb(255, 255, 224)#FFFFE0
    beigebeigergb(245, 245, 220)#F5F5DC
    ivory2ivory2rgb(238, 238, 224)#EEEEE0
    LightGoldenrodYellowLightGoldenrodYellowrgb(250, 250, 210)#FAFAD2
    LightYellow2LightYellow2rgb(238, 238, 209)#EEEED1
    ivory3ivory3rgb(205, 205, 193)#CDCDC1
    LightYellow3LightYellow3rgb(205, 205, 180)#CDCDB4
    ivory4ivory4rgb(139, 139, 131)#8B8B83
    LightYellow4LightYellow4rgb(139, 139, 122)#8B8B7A
    yellowyellowrgb(255, 255, 0)#FFFF00
    yellow1yellow1rgb(255, 255, 0)#FFFF00
    yellow2yellow2rgb(238, 238, 0)#EEEE00
    yellow3yellow3rgb(205, 205, 0)#CDCD00
    yellow4yellow4rgb(139, 139, 0)#8B8B00
    oliveolivergb(128, 128, 0)#808000
    DarkKhakiDarkKhakirgb(189, 183, 107)#BDB76B
    khaki2khaki2rgb(238, 230, 133)#EEE685
    LemonChiffon4LemonChiffon4rgb(139, 137, 112)#8B8970
    khaki1khaki1rgb(255, 246, 143)#FFF68F
    khaki3khaki3rgb(205, 198, 115)#CDC673
    khaki4khaki4rgb(139, 134, 78)#8B864E
    PaleGoldenrodPaleGoldenrodrgb(238, 232, 170)#EEE8AA
    LemonChiffonLemonChiffonrgb(255, 250, 205)#FFFACD
    LemonChiffon1LemonChiffon1rgb(255, 250, 205)#FFFACD
    khakikhakirgb(240, 230, 140)#F0E68C
    LemonChiffon3LemonChiffon3rgb(205, 201, 165)#CDC9A5
    LemonChiffon2LemonChiffon2rgb(238, 233, 191)#EEE9BF
    MediumGoldenRodMediumGoldenRodrgb(209, 193, 102)#D1C166
    cornsilk4cornsilk4rgb(139, 136, 120)#8B8878
    goldgoldrgb(255, 215, 0)#FFD700
    gold1gold1rgb(255, 215, 0)#FFD700
    gold2gold2rgb(238, 201, 0)#EEC900
    gold3gold3rgb(205, 173, 0)#CDAD00
    gold4gold4rgb(139, 117, 0)#8B7500
    LightGoldenrodLightGoldenrodrgb(238, 221, 130)#EEDD82
    LightGoldenrod4LightGoldenrod4rgb(139, 129, 76)#8B814C
    LightGoldenrod1LightGoldenrod1rgb(255, 236, 139)#FFEC8B
    LightGoldenrod3LightGoldenrod3rgb(205, 190, 112)#CDBE70
    LightGoldenrod2LightGoldenrod2rgb(238, 220, 130)#EEDC82
    cornsilk3cornsilk3rgb(205, 200, 177)#CDC8B1
    cornsilk2cornsilk2rgb(238, 232, 205)#EEE8CD
    cornsilkcornsilkrgb(255, 248, 220)#FFF8DC
    cornsilk1cornsilk1rgb(255, 248, 220)#FFF8DC
    goldenrodgoldenrodrgb(218, 165, 32)#DAA520
    goldenrod1goldenrod1rgb(255, 193, 37)#FFC125
    goldenrod2goldenrod2rgb(238, 180, 34)#EEB422
    goldenrod3goldenrod3rgb(205, 155, 29)#CD9B1D
    goldenrod4goldenrod4rgb(139, 105, 20)#8B6914
    DarkGoldenrodDarkGoldenrodrgb(184, 134, 11)#B8860B
    DarkGoldenrod1DarkGoldenrod1rgb(255, 185, 15)#FFB90F
    DarkGoldenrod2DarkGoldenrod2rgb(238, 173, 14)#EEAD0E
    DarkGoldenrod3DarkGoldenrod3rgb(205, 149, 12)#CD950C
    DarkGoldenrod4DarkGoldenrod4rgb(139, 101, 8)#8B6508
    FloralWhiteFloralWhitergb(255, 250, 240)#FFFAF0
    wheat2wheat2rgb(238, 216, 174)#EED8AE
    OldLaceOldLacergb(253, 245, 230)#FDF5E6
    wheatwheatrgb(245, 222, 179)#F5DEB3
    wheat1wheat1rgb(255, 231, 186)#FFE7BA
    wheat3wheat3rgb(205, 186, 150)#CDBA96
    orangeorangergb(255, 165, 0)#FFA500
    orange1orange1rgb(255, 165, 0)#FFA500
    orange2orange2rgb(238, 154, 0)#EE9A00
    orange3orange3rgb(205, 133, 0)#CD8500
    orange4orange4rgb(139, 90, 0)#8B5A00
    wheat4wheat4rgb(139, 126, 102)#8B7E66
    moccasinmoccasinrgb(255, 228, 181)#FFE4B5
    PapayaWhipPapayaWhiprgb(255, 239, 213)#FFEFD5
    NavajoWhite3NavajoWhite3rgb(205, 179, 139)#CDB38B
    BlanchedAlmondBlanchedAlmondrgb(255, 235, 205)#FFEBCD
    NavajoWhiteNavajoWhitergb(255, 222, 173)#FFDEAD
    NavajoWhite1NavajoWhite1rgb(255, 222, 173)#FFDEAD
    NavajoWhite2NavajoWhite2rgb(238, 207, 161)#EECFA1
    NavajoWhite4NavajoWhite4rgb(139, 121, 94)#8B795E
    AntiqueWhite4AntiqueWhite4rgb(139, 131, 120)#8B8378
    AntiqueWhiteAntiqueWhitergb(250, 235, 215)#FAEBD7
    tantanrgb(210, 180, 140)#D2B48C
    bisque4bisque4rgb(139, 125, 107)#8B7D6B
    burlywoodburlywoodrgb(222, 184, 135)#DEB887
    AntiqueWhite2AntiqueWhite2rgb(238, 223, 204)#EEDFCC
    burlywood1burlywood1rgb(255, 211, 155)#FFD39B
    burlywood3burlywood3rgb(205, 170, 125)#CDAA7D
    burlywood2burlywood2rgb(238, 197, 145)#EEC591
    AntiqueWhite1AntiqueWhite1rgb(255, 239, 219)#FFEFDB
    burlywood4burlywood4rgb(139, 115, 85)#8B7355
    AntiqueWhite3AntiqueWhite3rgb(205, 192, 176)#CDC0B0
    DarkOrangeDarkOrangergb(255, 140, 0)#FF8C00
    bisque2bisque2rgb(238, 213, 183)#EED5B7
    bisquebisquergb(255, 228, 196)#FFE4C4
    bisque1bisque1rgb(255, 228, 196)#FFE4C4
    bisque3bisque3rgb(205, 183, 158)#CDB79E
    DarkOrange1DarkOrange1rgb(255, 127, 0)#FF7F00
    linenlinenrgb(250, 240, 230)#FAF0E6
    DarkOrange2DarkOrange2rgb(238, 118, 0)#EE7600
    DarkOrange3DarkOrange3rgb(205, 102, 0)#CD6600
    DarkOrange4DarkOrange4rgb(139, 69, 0)#8B4500
    peruperurgb(205, 133, 63)#CD853F
    tan1tan1rgb(255, 165, 79)#FFA54F
    tan2tan2rgb(238, 154, 73)#EE9A49
    tan3tan3rgb(205, 133, 63)#CD853F
    tan4tan4rgb(139, 90, 43)#8B5A2B
    PeachPuffPeachPuffrgb(255, 218, 185)#FFDAB9
    PeachPuff1PeachPuff1rgb(255, 218, 185)#FFDAB9
    PeachPuff4PeachPuff4rgb(139, 119, 101)#8B7765
    PeachPuff2PeachPuff2rgb(238, 203, 173)#EECBAD
    PeachPuff3PeachPuff3rgb(205, 175, 149)#CDAF95
    SandyBrownSandyBrownrgb(244, 164, 96)#F4A460
    seashell4seashell4rgb(139, 134, 130)#8B8682
    seashell2seashell2rgb(238, 229, 222)#EEE5DE
    seashell3seashell3rgb(205, 197, 191)#CDC5BF
    chocolatechocolatergb(210, 105, 30)#D2691E
    chocolate1chocolate1rgb(255, 127, 36)#FF7F24
    chocolate2chocolate2rgb(238, 118, 33)#EE7621
    chocolate3chocolate3rgb(205, 102, 29)#CD661D
    chocolate4chocolate4rgb(139, 69, 19)#8B4513
    SaddleBrownSaddleBrownrgb(139, 69, 19)#8B4513
    seashellseashellrgb(255, 245, 238)#FFF5EE
    seashell1seashell1rgb(255, 245, 238)#FFF5EE
    sienna4sienna4rgb(139, 71, 38)#8B4726
    siennasiennargb(160, 82, 45)#A0522D
    sienna1sienna1rgb(255, 130, 71)#FF8247
    sienna2sienna2rgb(238, 121, 66)#EE7942
    sienna3sienna3rgb(205, 104, 57)#CD6839
    LightSalmon3LightSalmon3rgb(205, 129, 98)#CD8162
    LightSalmonLightSalmonrgb(255, 160, 122)#FFA07A
    LightSalmon1LightSalmon1rgb(255, 160, 122)#FFA07A
    LightSalmon4LightSalmon4rgb(139, 87, 66)#8B5742
    LightSalmon2LightSalmon2rgb(238, 149, 114)#EE9572
    coralcoralrgb(255, 127, 80)#FF7F50
    OrangeRedOrangeRedrgb(255, 69, 0)#FF4500
    OrangeRed1OrangeRed1rgb(255, 69, 0)#FF4500
    OrangeRed2OrangeRed2rgb(238, 64, 0)#EE4000
    OrangeRed3OrangeRed3rgb(205, 55, 0)#CD3700
    OrangeRed4OrangeRed4rgb(139, 37, 0)#8B2500
    DarkSalmonDarkSalmonrgb(233, 150, 122)#E9967A
    salmon1salmon1rgb(255, 140, 105)#FF8C69
    salmon2salmon2rgb(238, 130, 98)#EE8262
    salmon3salmon3rgb(205, 112, 84)#CD7054
    salmon4salmon4rgb(139, 76, 57)#8B4C39
    coral1coral1rgb(255, 114, 86)#FF7256
    coral2coral2rgb(238, 106, 80)#EE6A50
    coral3coral3rgb(205, 91, 69)#CD5B45
    coral4coral4rgb(139, 62, 47)#8B3E2F
    tomato4tomato4rgb(139, 54, 38)#8B3626
    tomatotomatorgb(255, 99, 71)#FF6347
    tomato1tomato1rgb(255, 99, 71)#FF6347
    tomato2tomato2rgb(238, 92, 66)#EE5C42
    tomato3tomato3rgb(205, 79, 57)#CD4F39
    MistyRose4MistyRose4rgb(139, 125, 123)#8B7D7B
    MistyRose2MistyRose2rgb(238, 213, 210)#EED5D2
    MistyRoseMistyRosergb(255, 228, 225)#FFE4E1
    MistyRose1MistyRose1rgb(255, 228, 225)#FFE4E1
    salmonsalmonrgb(250, 128, 114)#FA8072
    MistyRose3MistyRose3rgb(205, 183, 181)#CDB7B5
    whitewhitergb(255, 255, 255)#FFFFFF
    gray100gray100rgb(255, 255, 255)#FFFFFF
    grey100grey100rgb(255, 255, 255)#FFFFFF
    grey100grey100rgb(255, 255, 255)#FFFFFF
    gray99gray99rgb(252, 252, 252)#FCFCFC
    grey99grey99rgb(252, 252, 252)#FCFCFC
    gray98gray98rgb(250, 250, 250)#FAFAFA
    grey98grey98rgb(250, 250, 250)#FAFAFA
    gray97gray97rgb(247, 247, 247)#F7F7F7
    grey97grey97rgb(247, 247, 247)#F7F7F7
    gray96gray96rgb(245, 245, 245)#F5F5F5
    grey96grey96rgb(245, 245, 245)#F5F5F5
    WhiteSmokeWhiteSmokergb(245, 245, 245)#F5F5F5
    gray95gray95rgb(242, 242, 242)#F2F2F2
    grey95grey95rgb(242, 242, 242)#F2F2F2
    gray94gray94rgb(240, 240, 240)#F0F0F0
    grey94grey94rgb(240, 240, 240)#F0F0F0
    gray93gray93rgb(237, 237, 237)#EDEDED
    grey93grey93rgb(237, 237, 237)#EDEDED
    gray92gray92rgb(235, 235, 235)#EBEBEB
    grey92grey92rgb(235, 235, 235)#EBEBEB
    gray91gray91rgb(232, 232, 232)#E8E8E8
    grey91grey91rgb(232, 232, 232)#E8E8E8
    gray90gray90rgb(229, 229, 229)#E5E5E5
    grey90grey90rgb(229, 229, 229)#E5E5E5
    gray89gray89rgb(227, 227, 227)#E3E3E3
    grey89grey89rgb(227, 227, 227)#E3E3E3
    gray88gray88rgb(224, 224, 224)#E0E0E0
    grey88grey88rgb(224, 224, 224)#E0E0E0
    gray87gray87rgb(222, 222, 222)#DEDEDE
    grey87grey87rgb(222, 222, 222)#DEDEDE
    gainsborogainsbororgb(220, 220, 220)#DCDCDC
    gray86gray86rgb(219, 219, 219)#DBDBDB
    grey86grey86rgb(219, 219, 219)#DBDBDB
    gray85gray85rgb(217, 217, 217)#D9D9D9
    grey85grey85rgb(217, 217, 217)#D9D9D9
    gray84gray84rgb(214, 214, 214)#D6D6D6
    grey84grey84rgb(214, 214, 214)#D6D6D6
    gray83gray83rgb(212, 212, 212)#D4D4D4
    grey83grey83rgb(212, 212, 212)#D4D4D4
    LightGrayLightGrayrgb(211, 211, 211)#D3D3D3
    LightGreyLightGreyrgb(211, 211, 211)#D3D3D3
    gray82gray82rgb(209, 209, 209)#D1D1D1
    grey82grey82rgb(209, 209, 209)#D1D1D1
    gray81gray81rgb(207, 207, 207)#CFCFCF
    grey81grey81rgb(207, 207, 207)#CFCFCF
    gray80gray80rgb(204, 204, 204)#CCCCCC
    grey80grey80rgb(204, 204, 204)#CCCCCC
    gray79gray79rgb(201, 201, 201)#C9C9C9
    grey79grey79rgb(201, 201, 201)#C9C9C9
    gray78gray78rgb(199, 199, 199)#C7C7C7
    grey78grey78rgb(199, 199, 199)#C7C7C7
    gray77gray77rgb(196, 196, 196)#C4C4C4
    grey77grey77rgb(196, 196, 196)#C4C4C4
    gray76gray76rgb(194, 194, 194)#C2C2C2
    grey76grey76rgb(194, 194, 194)#C2C2C2
    silversilverrgb(192, 192, 192)#C0C0C0
    gray75gray75rgb(191, 191, 191)#BFBFBF
    grey75grey75rgb(191, 191, 191)#BFBFBF
    gray74gray74rgb(189, 189, 189)#BDBDBD
    grey74grey74rgb(189, 189, 189)#BDBDBD
    gray73gray73rgb(186, 186, 186)#BABABA
    grey73grey73rgb(186, 186, 186)#BABABA
    gray72gray72rgb(184, 184, 184)#B8B8B8
    grey72grey72rgb(184, 184, 184)#B8B8B8
    gray71gray71rgb(181, 181, 181)#B5B5B5
    grey71grey71rgb(181, 181, 181)#B5B5B5
    gray70gray70rgb(179, 179, 179)#B3B3B3
    grey70grey70rgb(179, 179, 179)#B3B3B3
    gray69gray69rgb(176, 176, 176)#B0B0B0
    grey69grey69rgb(176, 176, 176)#B0B0B0
    gray68gray68rgb(173, 173, 173)#ADADAD
    grey68grey68rgb(173, 173, 173)#ADADAD
    gray67gray67rgb(171, 171, 171)#ABABAB
    grey67grey67rgb(171, 171, 171)#ABABAB
    DarkGrayDarkGrayrgb(169, 169, 169)#A9A9A9
    DarkGreyDarkGreyrgb(169, 169, 169)#A9A9A9
    gray66gray66rgb(168, 168, 168)#A8A8A8
    grey66grey66rgb(168, 168, 168)#A8A8A8
    gray65gray65rgb(166, 166, 166)#A6A6A6
    grey65grey65rgb(166, 166, 166)#A6A6A6
    gray64gray64rgb(163, 163, 163)#A3A3A3
    grey64grey64rgb(163, 163, 163)#A3A3A3
    gray63gray63rgb(161, 161, 161)#A1A1A1
    grey63grey63rgb(161, 161, 161)#A1A1A1
    gray62gray62rgb(158, 158, 158)#9E9E9E
    grey62grey62rgb(158, 158, 158)#9E9E9E
    gray61gray61rgb(156, 156, 156)#9C9C9C
    grey61grey61rgb(156, 156, 156)#9C9C9C
    gray60gray60rgb(153, 153, 153)#999999
    grey60grey60rgb(153, 153, 153)#999999
    gray59gray59rgb(150, 150, 150)#969696
    grey59grey59rgb(150, 150, 150)#969696
    gray58gray58rgb(148, 148, 148)#949494
    grey58grey58rgb(148, 148, 148)#949494
    gray57gray57rgb(145, 145, 145)#919191
    grey57grey57rgb(145, 145, 145)#919191
    gray56gray56rgb(143, 143, 143)#8F8F8F
    grey56grey56rgb(143, 143, 143)#8F8F8F
    gray55gray55rgb(140, 140, 140)#8C8C8C
    grey55grey55rgb(140, 140, 140)#8C8C8C
    gray54gray54rgb(138, 138, 138)#8A8A8A
    grey54grey54rgb(138, 138, 138)#8A8A8A
    gray53gray53rgb(135, 135, 135)#878787
    grey53grey53rgb(135, 135, 135)#878787
    gray52gray52rgb(133, 133, 133)#858585
    grey52grey52rgb(133, 133, 133)#858585
    gray51gray51rgb(130, 130, 130)#828282
    grey51grey51rgb(130, 130, 130)#828282
    fractalfractalrgb(128, 128, 128)#808080
    gray50gray50rgb(127, 127, 127)#7F7F7F
    grey50grey50rgb(127, 127, 127)#7F7F7F
    graygrayrgb(126, 126, 126)#7E7E7E
    gray49gray49rgb(125, 125, 125)#7D7D7D
    grey49grey49rgb(125, 125, 125)#7D7D7D
    gray48gray48rgb(122, 122, 122)#7A7A7A
    grey48grey48rgb(122, 122, 122)#7A7A7A
    gray47gray47rgb(120, 120, 120)#787878
    grey47grey47rgb(120, 120, 120)#787878
    gray46gray46rgb(117, 117, 117)#757575
    grey46grey46rgb(117, 117, 117)#757575
    gray45gray45rgb(115, 115, 115)#737373
    grey45grey45rgb(115, 115, 115)#737373
    gray44gray44rgb(112, 112, 112)#707070
    grey44grey44rgb(112, 112, 112)#707070
    gray43gray43rgb(110, 110, 110)#6E6E6E
    grey43grey43rgb(110, 110, 110)#6E6E6E
    gray42gray42rgb(107, 107, 107)#6B6B6B
    grey42grey42rgb(107, 107, 107)#6B6B6B
    DimGrayDimGrayrgb(105, 105, 105)#696969
    DimGreyDimGreyrgb(105, 105, 105)#696969
    gray41gray41rgb(105, 105, 105)#696969
    grey41grey41rgb(105, 105, 105)#696969
    gray40gray40rgb(102, 102, 102)#666666
    grey40grey40rgb(102, 102, 102)#666666
    gray39gray39rgb( 99, 99, 99)#636363
    grey39grey39rgb( 99, 99, 99)#636363
    gray38gray38rgb( 97, 97, 97)#616161
    grey38grey38rgb( 97, 97, 97)#616161
    gray37gray37rgb( 94, 94, 94)#5E5E5E
    grey37grey37rgb( 94, 94, 94)#5E5E5E
    gray36gray36rgb( 92, 92, 92)#5C5C5C
    grey36grey36rgb( 92, 92, 92)#5C5C5C
    gray35gray35rgb( 89, 89, 89)#595959
    grey35grey35rgb( 89, 89, 89)#595959
    gray34gray34rgb( 87, 87, 87)#575757
    grey34grey34rgb( 87, 87, 87)#575757
    gray33gray33rgb( 84, 84, 84)#545454
    grey33grey33rgb( 84, 84, 84)#545454
    gray32gray32rgb( 82, 82, 82)#525252
    grey32grey32rgb( 82, 82, 82)#525252
    gray31gray31rgb( 79, 79, 79)#4F4F4F
    grey31grey31rgb( 79, 79, 79)#4F4F4F
    gray30gray30rgb( 77, 77, 77)#4D4D4D
    grey30grey30rgb( 77, 77, 77)#4D4D4D
    gray29gray29rgb( 74, 74, 74)#4A4A4A
    grey29grey29rgb( 74, 74, 74)#4A4A4A
    gray28gray28rgb( 71, 71, 71)#474747
    grey28grey28rgb( 71, 71, 71)#474747
    gray27gray27rgb( 69, 69, 69)#454545
    grey27grey27rgb( 69, 69, 69)#454545
    gray26gray26rgb( 66, 66, 66)#424242
    grey26grey26rgb( 66, 66, 66)#424242
    gray25gray25rgb( 64, 64, 64)#404040
    grey25grey25rgb( 64, 64, 64)#404040
    gray24gray24rgb( 61, 61, 61)#3D3D3D
    grey24grey24rgb( 61, 61, 61)#3D3D3D
    gray23gray23rgb( 59, 59, 59)#3B3B3B
    grey23grey23rgb( 59, 59, 59)#3B3B3B
    gray22gray22rgb( 56, 56, 56)#383838
    grey22grey22rgb( 56, 56, 56)#383838
    gray21gray21rgb( 54, 54, 54)#363636
    grey21grey21rgb( 54, 54, 54)#363636
    gray20gray20rgb( 51, 51, 51)#333333
    grey20grey20rgb( 51, 51, 51)#333333
    gray19gray19rgb( 48, 48, 48)#303030
    grey19grey19rgb( 48, 48, 48)#303030
    gray18gray18rgb( 46, 46, 46)#2E2E2E
    grey18grey18rgb( 46, 46, 46)#2E2E2E
    gray17gray17rgb( 43, 43, 43)#2B2B2B
    grey17grey17rgb( 43, 43, 43)#2B2B2B
    gray16gray16rgb( 41, 41, 41)#292929
    grey16grey16rgb( 41, 41, 41)#292929
    gray15gray15rgb( 38, 38, 38)#262626
    grey15grey15rgb( 38, 38, 38)#262626
    gray14gray14rgb( 36, 36, 36)#242424
    grey14grey14rgb( 36, 36, 36)#242424
    gray13gray13rgb( 33, 33, 33)#212121
    grey13grey13rgb( 33, 33, 33)#212121
    gray12gray12rgb( 31, 31, 31)#1F1F1F
    grey12grey12rgb( 31, 31, 31)#1F1F1F
    gray11gray11rgb( 28, 28, 28)#1C1C1C
    grey11grey11rgb( 28, 28, 28)#1C1C1C
    gray10gray10rgb( 26, 26, 26)#1A1A1A
    grey10grey10rgb( 26, 26, 26)#1A1A1A
    gray9gray9rgb( 23, 23, 23)#171717
    grey9grey9rgb( 23, 23, 23)#171717
    gray8gray8rgb( 20, 20, 20)#141414
    grey8grey8rgb( 20, 20, 20)#141414
    gray7gray7rgb( 18, 18, 18)#121212
    grey7grey7rgb( 18, 18, 18)#121212
    gray6gray6rgb( 15, 15, 15)#0F0F0F
    grey6grey6rgb( 15, 15, 15)#0F0F0F
    gray5gray5rgb( 13, 13, 13)#0D0D0D
    grey5grey5rgb( 13, 13, 13)#0D0D0D
    gray4gray4rgb( 10, 10, 10)#0A0A0A
    grey4grey4rgb( 10, 10, 10)#0A0A0A
    gray3gray3rgb( 8, 8, 8)#080808
    grey3grey3rgb( 8, 8, 8)#080808
    gray2gray2rgb( 5, 5, 5)#050505
    grey2grey2rgb( 5, 5, 5)#050505
    gray1gray1rgb( 3, 3, 3)#030303
    grey1grey1rgb( 3, 3, 3)#030303
    blackblackrgb( 0, 0, 0)#000000
    gray0gray0rgb( 0, 0, 0)#000000
    grey0grey0rgb( 0, 0, 0)#000000
    opaqueopaquergb( 0, 0, 0)#000000
    nonenonergba( 0, 0, 0, 0.0)#00000000
    transparenttransparentrgba( 0, 0, 0, 0.0)#00000000
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/command-line-options.html b/ImageMagick-7.0.0-0/www/command-line-options.html deleted file mode 100644 index 8e6619c88..000000000 --- a/ImageMagick-7.0.0-0/www/command-line-options.html +++ /dev/null @@ -1,7928 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Options - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    ‑adaptive‑blur • ‑adaptive‑resize • ‑adaptive‑sharpen • ‑adjoin • ‑affine • ‑alpha • ‑annotate • ‑antialias • ‑append • ‑attenuate • ‑authenticate • ‑auto‑gamma • ‑auto‑level • ‑auto‑orient • ‑backdrop • ‑background • ‑bench • ‑bias • ‑black‑point‑compensation • ‑black‑threshold • ‑blend • ‑blue‑primary • ‑blue‑shift • ‑blur • ‑border • ‑bordercolor • ‑borderwidth • ‑brightness‑contrast • ‑cache • ‑canny • ‑caption • ‑cdl • ‑channel • ‑charcoal • ‑chop • ‑clamp • ‑clip • ‑clip‑mask • ‑clip‑path • ‑clone • ‑clut • ‑coalesce • ‑colorize • ‑colormap • ‑color‑matrix • ‑colors • ‑colorspace • ‑combine • ‑comment • ‑compare • ‑complex • ‑compose • ‑composite • ‑compress • ‑connected‑components • ‑contrast • ‑contrast‑stretch • ‑convolve • ‑copy • ‑crop • ‑cycle • ‑debug • ‑decipher • ‑deconstruct • ‑define • ‑delay • ‑delete • ‑density • ‑depth • ‑descend • ‑deskew • ‑despeckle • ‑direction • ‑displace • ‑display • ‑dispose • ‑dissimilarity‑threshold • ‑dissolve • ‑distort • ‑distribute‑cache • ‑dither • ‑draw • ‑duplicate • ‑edge • ‑emboss • ‑encipher • ‑encoding • ‑endian • ‑enhance • ‑equalize • ‑evaluate • ‑evaluate‑sequence • ‑extent • ‑extract • ‑family • ‑features • ‑fft • ‑fill • ‑filter • ‑flatten • ‑flip • ‑floodfill • ‑flop • ‑font • ‑foreground • ‑format • ‑format[identify] • ‑frame • ‑frame[import] • ‑function • ‑fuzz • ‑fx • ‑gamma • ‑gaussian‑blur • ‑geometry • ‑gravity • ‑grayscale • ‑green‑primary • ‑hald‑clut • ‑help • ‑highlight‑color • ‑hough‑lines • ‑iconGeometry • ‑iconic • ‑identify • ‑ift • ‑immutable • ‑implode • ‑insert • ‑intensity • ‑intent • ‑interlace • ‑interpolate • ‑interline‑spacing • ‑interword‑spacing • ‑kerning • ‑kuwahara • ‑label • ‑lat • ‑layers • ‑level • ‑level‑colors • ‑limit • ‑linear‑stretch • ‑linewidth • ‑liquid‑rescale • ‑list • ‑log • ‑loop • ‑lowlight‑color • ‑magnify • ‑map • ‑map[stream] • ‑mask • ‑mattecolor • ‑median • ‑mean‑shift • ‑metric • ‑mode • ‑modulate • ‑moments • ‑monitor • ‑monochrome • ‑morph • ‑morphology • ‑mosaic • ‑motion‑blur • ‑name • ‑negate • ‑noise • ‑normalize • ‑opaque • ‑ordered‑dither • ‑orient • ‑page • ‑paint • ‑path • ‑pause[animate] • ‑pause[import] • ‑perceptible • ‑ping • ‑pointsize • ‑polaroid • ‑poly • ‑posterize • ‑precision • ‑preview • ‑print • ‑process • ‑profile • ‑quality • ‑quantize • ‑quiet • ‑radial‑blur • ‑raise • ‑random‑threshold • ‑red‑primary • ‑regard‑warnings • ‑region • ‑remap • ‑remote • ‑render • ‑repage • ‑resample • ‑resize • ‑respect‑parentheses • ‑reverse • ‑roll • ‑rotate • ‑sample • ‑sampling‑factor • ‑scale • ‑scene • ‑screen • ‑seed • ‑segment • ‑selective‑blur • ‑separate • ‑sepia‑tone • ‑set • ‑shade • ‑shadow • ‑shared‑memory • ‑sharpen • ‑shave • ‑shear • ‑sigmoidal‑contrast • ‑silent • ‑similarity‑threshold • ‑size • ‑sketch • ‑smush • ‑snaps • ‑solarize • ‑sparse‑color • ‑splice • ‑spread • ‑statistic • ‑stegano • ‑stereo • ‑storage‑type • ‑stretch • ‑strip • ‑stroke • ‑strokewidth • ‑style • ‑subimage‑search • ‑swap • ‑swirl • ‑synchronize • ‑taint • ‑text‑font • ‑texture • ‑threshold • ‑thumbnail • ‑tile • ‑tile‑offset • ‑tint • ‑title • ‑transform • ‑transparent • ‑transparent‑color • ‑transpose • ‑transverse • ‑treedepth • ‑trim • ‑type • ‑undercolor • ‑unique‑colors • ‑units • ‑unsharp • ‑update • ‑verbose • ‑version • ‑view • ‑vignette • ‑virtual‑pixel • ‑visual • ‑watermark • ‑wave • ‑weight • ‑white‑point • ‑white‑threshold • ‑window • ‑window‑group • ‑write

    - -

    Below is list of command-line options recognized by the ImageMagick command-line tools. If you want a description of a particular option, click on the option name in the navigation bar above and you will go right to it. Unless otherwise noted, each option is recognized by the commands: convert and mogrify.

    - -
    -

    -adaptive-blur radius[xsigma]

    -
    - -

    Adaptively blur pixels, with decreasing effect near edges.

    - -

    A Gaussian operator of the given radius and standard deviation (sigma) is used. If sigma is not given it -defaults to 1.

    - -
    -

    -adaptive-resize geometry

    -
    - -

    Resize the image using data-dependent triangulation.

    - -

    See Image Geometry for complete details about the geometry argument. The -adaptive-resize -option defaults to data-dependent triangulation. Use the -filter to choose a different resampling algorithm. -Offsets, if present in the geometry string, are ignored, and the -gravity option has no effect.

    - -
    -

    -adaptive-sharpen radius[xsigma]

    -
    - -

    Adaptively sharpen pixels, with increasing effect near edges.

    - -

    A Gaussian operator of the given radius and standard deviation -(sigma) is used. If sigma is not given it -defaults to 1.

    - -
    -

    -adjoin

    -
    - -

    Join images into a single multi-image file.

    - -

    This option is enabled by default. An attempt is made to save all images of -an image sequence into the given output file. However, some formats, such as -JPEG and PNG, do not support more than one image per file, and in that case -ImageMagick is forced to write each image as a separate file. As such, if -more than one image needs to be written, the filename given is modified by -adding a -scene number before the suffix, in order to -make distinct names for each image.

    - -

    Use +adjoin to force each image to be written to -separate files, whether or not the file format allows multiple images per file -(for example, GIF, MIFF, and TIFF).

    - -

    Including a C-style integer format string in the output filename will -automagically enable +adjoin and are used to specify -where the -scene number is placed in the filenames. These -strings, such as '%d' or '%03d', are familiar to those -who have used the standard printf()' C-library function. As an -example, the command

    - -
    -convert logo: rose: -morph 15 my%02dmorph.jpg
    -
    - -

    will create a sequence of 17 images (the two given plus 15 more created by --morph), named: my00morph.jpg, my01morph.jpg, -my02morph.jpg, ..., my16morph.jpg.

    - -

    In summary, ImageMagick tries to write all images to one file, but will -save to multiple files, if any of the following conditions exist...

    -
      -
    1. the output image's file format does not allow multi-image files,
    2. -
    3. the +adjoin option is given, or
    4. -
    5. a printf() integer format string (eg: "%d") is present in the output - filename.
    6. -
    - - -
    -

    -affine - sx,rx,ry,sy[,tx,ty]

    -
    - -

    Set the drawing transformation matrix for combined rotating and scaling.

    - -

    This option sets a transformation matrix, for use by subsequent -draw or -transform options.

    - -

    The matrix entries are entered as comma-separated numeric values either in -quotes or without spaces.

    - -

    Internally, the transformation matrix has 3x3 elements, but three of them -are omitted from the input because they are constant. The new (transformed) -coordinates (x', y') of a pixel at -position (x, y) in the original -image are calculated using the following matrix equation.

    - -

    affine transformation

    - -

    The size of the resulting image is that of the smallest rectangle that -contains the transformed source image. The parameters -tx and ty -subsequently shift the image pixels so that those that are moved out of the -image area are cut off.

    - -

    The transformation matrix complies with the left-handed pixel coordinate -system: positive x and y directions -are rightward and downward, resp.; positive rotation is clockwise.

    - -

    If the translation coefficients tx and -ty are omitted they default to 0,0. Therefore, -four parameters suffice for rotation and scaling without translation.

    - -

    Scaling by the factors sx and -sy in the x and y directions, -respectively, is accomplished with the following.

    - -

    See -transform, and the -distort method 'Affineprojection for more -information

    - - -
    --affine sx,0,0,sy
    -
    - -

    Translation by a displacement (tx, ty) is accomplished like so:

    - -
    --affine 1,0,0,1,tx,ty
    -
    - -

    Rotate clockwise about the origin (the upper left-hand corner) by an angle -a by letting c = cos(a), s -= sin(a), and using the following.

    - -
    --affine c,s,-s,c
    -
    - -

    The cumulative effect of a sequence of -affine -transformations can be accomplished by instead by a single -affine operation using the matrix equal to the product of the matrices -of the individual transformations.

    - -

    An attempt is made to detect near-singular transformation matrices. If the -matrix determinant has a sufficiently small absolute value it is rejected.

    - -
    -

    -alpha type

    -
    - -

    Gives control of the alpha/matte channel of an image.

    - -

    Used to set a flag on an image indicating whether or not to use existing alpha -channel data, to create an alpha channel, or to perform other operations on the alpha channel. Choose the argument type from the list below.

    - -
    -
    Activate
    -
    - Enable the image's transparency channel. Note normally Set - should be used instead of this, unless you specifically need to - preserve existing (but specifically turned Off) transparency - channel.
    - -
    Associate
    -
    - associate the alpha channel with the image.
    - -
    Deactivate
    -
    - Disables the image's transparency channel. Does not delete or change the - existing data, just turns off the use of that data.
    - -
    Disassociate
    -
    - disassociate the alpha channel from the image.
    - -
    Set
    -
    - Activates the alpha/matte channel. If it was previously turned off - then it also resets the channel to opaque. If the image already had - the alpha channel turned on, it will have no effect.
    - -
    Opaque
    -
    - Enables the alpha/matte channel and forces it to be fully opaque. -
    - -
    Transparent
    -
    - Activates the alpha/matte channel and forces it to be fully - transparent. This effectively creates a fully transparent image the - same size as the original and with all its original RGB data still - intact, but fully transparent.
    - -
    Extract
    -
    - Copies the alpha channel values into all the color channels and turns - 'Off' the the image's transparency, so as to generate - a gray-scale mask of the image's shape. The alpha channel data is left - intact just deactivated. This is the inverse of 'Copy'. -
    - -
    Copy
    -
    - Turns 'On' the alpha/matte channel, then copies the - gray-scale intensity of the image, into the alpha channel, converting - a gray-scale mask into a transparent shaped mask ready to be colored - appropriately. The color channels are not modified.
    - -
    Shape
    -
    - As per 'Copy' but also colors the resulting shape mask with - the current background color. That is the RGB color channels is - replaced, with appropriate alpha shape. -
    - -
    Remove
    -
    - Composite the image over the background color. -
    - -
    Background
    -
    - Set any fully-transparent pixel to the background color, while leaving - it fully-transparent. This can make some image file formats, such as - PNG, smaller as the RGB values of transparent pixels are more uniform, - and thus can compress better. -
    -
    - -

    Note that while the obsolete +matte operation was the -same as "-alpha Off", the ->-matte operation was the same as "-alpha -Set" and not "-alpha On".

    - - -
    -

    - -annotate degrees text
    - -annotate XdegreesxYdegrees text
    -annotate XdegreesxYdegrees {+-}tx{+-}ty text
    -annotate {+-}tx{+-}ty text

    -
    - -

    Annotate an image with text

    - -

    This is a convenience for annotating an image with text. For more precise -control over text annotations, use -draw.

    - - -

    The values Xdegrees and Ydegrees -control the shears applied to the text, while tx and ty are offsets that give the location of the text relative any -gravity setting and defaults to the upper left corner of the image.

    - -

    Using -annotate degrees -or -annotate degreesxdegrees produces an unsheared rotation of the text. The -direction of the rotation is positive, which means a clockwise rotation if degrees is positive. (This conforms to the usual mathematical -convention once it is realized that the positive y–direction is -conventionally considered to be downward for images.)

    - -

    The new (transformed) coordinates (x', y') of a pixel at position (x, y) in the image are calculated using the following matrix -equation.

    - -

    annotate transformation

    - -

    If tx and ty are omitted, they default to 0. This makes the -bottom-left of the text becomes the upper-left corner of the image, which is -probably undesirable. Adding a -gravity option in this -case leads to nice results.

    - -

    Text is any UTF-8 encoded character sequence. If text -is of the form '@mytext.txt', the text is read from the file -mytext.txt. Text in a file is taken literally; no embedded -formatting characters are recognized.

    - -
    -

    -antialias

    -
    - -

    Enable/Disable of the rendering of anti-aliasing pixels when drawing fonts and lines.

    - -

    By default, objects (e.g. text, lines, polygons, etc.) are antialiased when -drawn. Use +antialias to disable the addition of -antialiasing edge pixels. This will then reduce the number of colors added to -an image to just the colors being directly drawn. That is, no mixed colors -are added when drawing such objects.

    - -
    -

    -append

    -
    - -

    Join current images vertically or horizontally.

    - -

    This option creates a single longer image, by joining all the current -images in sequence top-to-bottom. Use +append to -stack images left-to-right.

    - -

    If they are not of the same width, narrower images are padded with the -current -background color setting, and their -position relative to each other can be controlled by the current -gravity setting.

    - - -
    -

    -attenuate value

    -
    - -

    Lessen (or intensify) when adding noise to an image.

    - -

    If unset the value is equivalent to 1.0, or a maximum noise addition

    - -
    -

    -authenticate password

    -
    - -

    Decrypt a PDF with a password.

    - -

    Use this option to supply a password for decrypting -a PDF that has been encrypted using Microsoft Crypto API (MSC API). The -encrypting using the MSC API is not supported.

    - -

    For a different encryption method, see -encipher -and -decipher.

    - - -
    -

    -auto-gamma

    -
    - -

    Automagically adjust gamma level of image.

    - -

    This calculates the mean values of an image, then applies a calculated -gamma adjustment so that is the mean color exists in the -image it will get a have a value of 50%.

    - -

    This means that any solid 'gray' image becomes 50% gray.

    - -

    This works well for real-life images with little or no extreme dark and -light areas, but tend to fail for images with large amounts of bright sky or -dark shadows. It also does not work well for diagrams or cartoon like images. -

    - -

    It uses the -channel setting, (including the -'sync' flag for channel synchronization), to determine which color -values is used and modified. As the default -channel setting is 'RGB,sync', channels are modified -together by the same gamma value, preserving colors.

    - - - -
    -

    -auto-level

    -
    - -

    Automagically adjust color levels of image.

    - -

    This is a 'perfect' image normalization operator. It finds the exact -minimum and maximum color values in the image and then applies a -level operator to stretch the values to the full range of -values.

    - -

    The operator is not typically used for real-life images, image scans, or -JPEG format images, as a single 'out-rider' pixel can set a bad min/max values -for the -level operation. On the other hand it is the -right operator to use for color stretching gradient images being used to -generate Color lookup tables, distortion maps, or other 'mathematically' -defined images.

    - -

    The operator is very similar to the -normalize, -contrast-stretch, and -linear-stretch operators, but without 'histogram binning' or 'clipping' -problems that these operators may have. That is -auto-level is the perfect or ideal version these operators.

    - -

    It uses the -channel setting, (including the -special 'sync' flag for channel synchronization), to determine -which color values are used and modified. As the default +channel setting is 'RGB,sync', the -'sync' ensures that the color channels will are modified -together by the same gamma value, preserving colors, and ignoring -transparency.

    - - -
    -

    -auto-orient

    -
    - -

    adjusts an image so that its orientation is suitable for viewing (i.e. top-left orientation).

    - -

    This operator reads and resets the EXIF image profile setting 'Orientation' -and then performs the appropriate 90 degree rotation on the image to orient -the image, for correct viewing.

    - -

    This EXIF profile setting is usually set using a gravity sensor in digital -camera, however photos taken directly downward or upward may not have an -appropriate value. Also images that have been orientation 'corrected' without -reseting this setting, may be 'corrected' again resulting in a incorrect -result. If the EXIF profile was previously stripped, the -auto-orient operator will do nothing.

    - - -
    -

    -average

    -
    - -

    Average a set of images.

    - -

    An error results if the images are not identically sized.

    - - -
    -

    -backdrop

    -
    - -

    Display the image centered on a backdrop.

    - -

    This backdrop covers the entire workstation screen and is useful for hiding -other X window activity while viewing the image. The color of the backdrop is -specified as the background color. The color is specified using the format -described under the -fill option.

    - -
    -

    -background color

    -
    - -

    Set the background color.

    - -

    The color is specified using the format described under the -fill option. The default background color (if none is -specified or found in the image) is white.

    - -
    -

    -bench iterations

    -
    - -

    Measure performance.

    - -

    Repeat the entire command for the given number of iterations and report the user-time and elapsed time. For instance, -consider the following command and its output. Modify the benchmark with the --duration to run the benchmark for a fixed number of seconds and -concurrent -to run the benchmark in parallel (requires the OpenMP feature).

    - -
    --> convert logo: -resize 1000% -bench 5 logo.png
    -Performance[4]: 5i 0.875657ips 6.880u 0:05.710
    -
    - -

    In this example, 5 iterations were completed at 0.875657 iterations per -second, using 4 threads and 6.88 seconds of the user's allotted time, for -a total elapsed time of 5.71 seconds.

    - -
    -

    -bias value{%}

    -
    - -

    Add bias when convolving an image.

    - -

    This option shifts the output of ‑convolve so that -positive and negative results are relative to the specified bias value.

    - -

    This is important for non-HDRI compilations of ImageMagick when dealing -with convolutions that contain negative as well as positive values. This is -especially the case with convolutions involving high pass filters or edge -detection. Without an output bias, the negative values are clipped at -zero.

    - -

    When using an ImageMagick with the HDRI compile-time setting, ‑bias is not needed, as ImageMagick is able to store/handle any -negative results without clipping to the color value range -(0..QuantumRange).

    - -

    See the discussion on HDRI implementations of ImageMagick on the page High Dynamic-Range Images. For more -about HDRI go the ImageMagick Usage pages or this -Wikipedia -entry.

    - -
    -

    -black-point-compensation

    -
    - -

    Use black point compensation.

    - -
    -

    -black-threshold value{%}

    -
    - -

    Force to black all pixels below the threshold while leaving all pixels at or above the threshold unchanged.

    - -

    The threshold value can be given as a percentage or as an absolute integer -value within [0, QuantumRange] corresponding to the -desired ‑channel value. See ‑thresholdfor more details on thresholds and resulting values.

    - - -
    -

    -blend geometry

    -
    - -

    blend an image into another by the given absolute value or percent.

    - -

    Blend will average the images together ('plus') according to the -percentages given and each pixels transparency. If only a single percentage -value is given it sets the weight of the composite or 'source' image, while -the background image is weighted by the exact opposite amount. That is a --blend 30% merges 30% of the 'source' image with 70% of the -'destination' image. Thus it is equivalent to -blend 30x70%.

    - - -
    -

    -blue-primary x,y

    -
    - -

    Set the blue chromaticity primary point.

    - -
    -

    -blue-shift factor

    -
    - -

    simulate a scene at nighttime in the moonlight. Start with a factor of 1.5

    - -
    - -
    -

    -blur radius
    -blur radiusxsigma

    -
    - -

    Reduce image noise and reduce detail levels.

    - -

    Convolve the image with a Gaussian or normal distribution using the given -Sigma value. The formula is:

    - -

    gaussian distribution

    - -

    The Sigma value is the important argument, and -determines the actual amount of blurring that will take place.

    - -

    The Radius is only used to determine the size of the -array which will hold the calculated Gaussian distribution. It should be an -integer. If not given, or set to zero, IM will calculate the largest possible -radius that will provide meaningful results for the Gaussian distribution. -

    - -

    The larger the Radius the slower the -operation is. However too small a Radius, and sever -aliasing effects may result. As a guideline, Radius -should be at least twice the Sigma value, though three -times will produce a more accurate result.

    - -

    This option differs from -gaussian-blur simply -by taking advantage of the separability properties of the distribution. Here -we apply a single-dimensional Gaussian matrix in the horizontal direction, -then repeat the process in the vertical direction.

    - -

    The -virtual-pixel setting will determine how -pixels which are outside the image proper are blurred into the final result. -

    - - -
    -

    -blur Width[xHeight[+Angle]]

    -
    - -

    Variably blur an image according to the overlay mapping.

    - -

    Each pixel in the overlaid region is replaced with an Elliptical Weighted -Average (EWA) of the source image, scaled according to the grayscale -mapping.

    - -

    The ellipse is weighted with sigma set to the given Width and Height. The Height -defaults to the Width for a normal circular Gaussian -weighting. The Angle will rotate the ellipse from -horizontal clock-wise.

    - -

    The -virtual-pixel setting will determine how -pixels which are outside the image proper are blurred into the final result. -

    - - -
    -

    -border geometry

    -
    - -

    Surround the image with a border of color.

    - -

    Set the width and height using the size portion of the -geometry argument. See Image Geometry for complete details about the geometry argument. Offsets are -ignored.

    - -

    As of IM 6.7.8-8, the geometry arguments behave as follows:

    - -
    -
    value
    -
    value is added to both left/right and top/bottom
    -
    value-xx
    -
    value-x is added only to left/right and top/bottom are unchanged
    -
    xvalue-y
    -
    value-y is added only to top/bottom and left/right are unchanged
    -
    value-xxvalue-y
    -
    value-x is added to left/right and value-y added to top/bottom
    -
    value-xx0
    -
    value-x is added only to left/right and top/bottom are unchanged
    -
    0xvalue-y
    -
    value-y is added only to top/bottom and left/right are unchanged
    -
    value%
    -
    value % of width is added to left/right and value % of height is added to top/bottom
    -
    value-xx%
    -
    value-x % of width is added to left/right and to top/bottom
    -
    xvalue-y%
    -
    value-y % of height is added to top/bottom and to left/right
    -
    value-x%xvalue-y%
    -
    value-x % of width is added to left/right and value-y % of height is added to top/bottom
    -
    value-x%x0%
    -
    value-x % of width is added to left/right and top/bottom are unchanged
    -
    0%xvalue-y%
    -
    value-y % of height is added to top/bottom and left/right are unchanged
    -
    - -

    Set the border color by preceding with the -bordercolor setting.

    - -

    The -border operation is affected by the current -compose setting and assumes that this is using the default -'Over' composition method. It generates an image of the appropriate -size colors by the current -bordercolor before -overlaying the original image in the center of this net image. This means that -with the default compose method of 'Over' any transparent parts may -be replaced by the current -bordercolor setting.

    -

    See also the -frame option, which has more -functionality.

    - -
    -

    -bordercolor color

    -
    - -

    Set the border color.

    - -

    The color is specified using the format described under the -fill option.

    - -

    The default border color is #DFDFDF, this shade of gray.

    - -
    -

    -borderwidth geometry

    -
    - -

    Set the border width.

    - -
    -

    -brightness-contrast brightness
    -brightness-contrast brightness{xcontrast}{%}}

    -
    - -

    Adjust the brightness and/or contrast of the image.

    - -

    Brightness and Contrast values apply changes to the input image. They are -not absolute settings. A brightness or contrast value of zero means no change. -The range of values is -100 to +100 on each. Positive values increase the -brightness or contrast and negative values decrease the brightness or contrast. -To control only contrast, set the brightness=0. To control only brightness, -set contrast=0 or just leave it off.

    - -

    You may also use -channel to control which channels to -apply the brightness and/or contrast change. The default is to apply the same -transformation to all channels.

    - -

    Brightness and Contrast arguments are converted to offset and slope of a -linear transform and applied -using -function polynomial "slope,offset".

    - -

    The slope varies from 0 at contrast=-100 to almost vertical at -contrast=+100. For brightness=0 and contrast=-100, the result are totally -midgray. For brightness=0 and contrast=+100, the result will approach but -not quite reach a threshold at midgray; that is the linear transformation -is a very steep vertical line at mid gray.

    - -

    Negative slopes, i.e. negating the image, are not possible with this -function. All achievable slopes are zero or positive.

    - -

    The offset varies from -0.5 at brightness=-100 to 0 at brightness=0 to +0.5 -at brightness=+100. Thus, when contrast=0 and brightness=100, the result is -totally white. Similarly, when contrast=0 and brightness=-100, the result is -totally black.

    - -

    As the range of values for the arguments are -100 to +100, adding the '%' -symbol is no different than leaving it off.

    - -
    -

    -cache threshold

    -
    - -

    (This option has been replaced by the -limit option).

    - -
    -

    -canny radius
    -canny radiusxsigma{+lower-percent}{+upper-percent}

    -
    - -

    Canny edge detector uses a multi-stage algorithm to detect a wide range of edges in the image.

    - -

    The thresholds range from 0 to 100% (e.g. -canny 0x1+10%+30%) with {+lower-percent} < {+upper-percent}. If {+upper-percent} is increased but {+lower-percent} remains the same, lesser edge components will be detected, but their lengths will be the same. If {+lower-percent} is increased but {+upper-percent} is the same, the same number of edge components will be detected but their lengths will be shorter. The default thresholds are shown. The radiusxsigma controls a gaussian blur applied to the input image to reduce noise and smooth the edges.

    - -
    -

    -caption string

    -
    - -

    Assign a caption to an image.

    - -

    This option sets the caption meta-data of an image read in after this -option has been given. To modify a caption of images already in memory use -"-set caption".

    - -

    The caption can contain special format characters listed in the Format and -Print Image Properties. These attributes are expanded when the caption -is finally assigned to the individual images.

    - -

    If the first character of string is @, the image caption is read from a file titled by the -remaining characters in the string. Comments read in from a file are literal; -no embedded formatting characters are recognized.

    - -

    Caption meta-data is not visible on the image itself. To do that use the --annotate or -draw options -instead.

    - -

    For example,

    - -
    --caption "%m:%f %wx%h"  bird.miff
    -
    - -

    produces an image caption of MIFF:bird.miff 512x480 (assuming -that the image bird.miff has a width of 512 and a height of -480.

    - - -
    -

    -cdl filename

    -
    - -

    color correct with a color decision list.

    - -

    Here is an example color correction collection:

    - -
    -<?xml version="1.0" encoding="UTF-8"?>
    -<ColorCorrectionCollection xmlns="urn:ASC:CDL:v1.2">
    -  <ColorCorrection id="cc06668">
    -    <SOPNode>
    -      <Slope> 0.9 1.2 0.5 </Slope>
    -      <Offset> 0.4 -0.5 0.6 </Offset>
    -      <Power> 1.0 0.8 1.5 </Power>
    -    </SOPNode>
    -    <SATNode>
    -      <Saturation> 0.85 </Saturation>
    -    </SATNode>
    -  </ColorCorrection>
    -</ColorCorrectionCollection>
    -
    - -
    -

    -channel type

    -
    - -

    Specify those image color channels to which subsequent operators are limited.

    - -

    Choose from: Red, Green, Blue, -Alpha, Gray, Cyan, Magenta, -Yellow, Black, Opacity, -Index, RGB, RGBA, CMYK, or -CMYKA.

    - -

    The channels above can also be specified as a comma-separated list or can be -abbreviated as a concatenation of the letters 'R', 'G', -'B', 'A', 'O', 'C', -'M', 'Y', 'K'. - -For example, to only select the Red and Blue channels -you can either use

    -
    --channel Red,Blue
    -
    -

    or you can use the short hand form

    -
    --channel RB
    -
    - -

    All the channels that are present in an image can be specified using the -special channel type All. Not all operators are 'channel capable', -but generally any operators that are generally 'grey-scale' image operators, -will understand this setting. See individual operator documentation.

    - -
    - -

    On top of the normal channel selection an extra flag can be specified, -'Sync'. This is turned on by default and if set means that -operators that understand this flag should perform: cross-channel -synchronization of the channels. If not specified, then most grey-scale -operators will apply their image processing operations to each individual -channel (as specified by the rest of the -channel -setting) completely independently from each other.

    - -

    For example for operators such as -auto-level and --auto-gamma the color channels are modified -together in exactly the same way so that colors will remain in-sync. Without -it being set, then each channel is modified separately and -independently, which may produce color distortion.

    - -

    The -morphology 'Convolve' method -and the -compose mathematical methods, also understands -the 'Sync' flag to modify the behavior of pixel colors according -to the alpha channel (if present). That is to say it will modify the image -processing with the understanding that fully-transparent colors should not -contribute to the final result.

    - -

    Basically, by default, operators work with color channels in synchronous, and -treats transparency as special, unless the -channel -setting is modified so as to remove the effect of the 'Sync' flag. -How each operator does this depends on that operators current implementation. -Not all operators understands this flag at this time, but that is changing. -

    - -

    To print a complete list of channel types, use -list -channel.

    - -

    By default, ImageMagick sets -channel to the value -'RGBK,sync', which specifies that operators act on all color -channels except the transparency channel, and that all the color channels are -to be modified in exactly the same way, with an understanding of transparency -(depending on the operation being applied). The 'plus' form +channel will reset the value back to this default.

    - -

    Options that are affected by the -channel setting -include the following. - --auto-gamma, --auto-level, --black-threshold, --blur, --clamp, --clut, --combine, --composite (Mathematical compose methods only), --convolve, --contrast-stretch, --evaluate, --function, --fx, --gaussian-blur, --hald-clut, --motion-blur, --morphology, --negate, --normalize, --ordered-dither, --radial-blur, --random-threshold, --separate, --threshold, and --white-threshold. -

    - -

    Warning, some operators behave differently when the +channel default setting is in effect, verses ANY user defined -channel setting (including the equivalent of the -default). These operators have yet to be made to understand the newer 'Sync' -flag.

    - -

    For example -threshold will by default gray-scale -the image before thresholding, if no -channel setting -has been defined. This is not 'Sync flag controlled, yet.

    - -

    Also some operators such as -blur, -gaussian-blur, will modify their handling of the -color channels if the 'alpha' channel is also enabled by -channel. Generally this done to ensure that -fully-transparent colors are treated as being fully-transparent, and thus any -underlying 'hidden' color has no effect on the final results. Typically -resulting in 'halo' effects. The newer -morphology -convolution equivalents however does have a understanding of the 'Sync' flag -and will thus handle transparency correctly by default.

    - -

    As a alpha channel is optional within images, some operators will read the -color channels of an image as a greyscale alpha mask, when the image has no -alpha channel present, and the -channel setting tells -the operator to apply the operation using alpha channels. The -clut operator is a good example of this.

    - - - -
    -

    -charcoal factor

    -
    - -

    Simulate a charcoal drawing.

    - -
    -

    -chop geometry

    -
    - -

    Remove pixels from the interior of an image.

    - -

    See Image Geometry for complete details about the geometry argument. The width -and height given in the of the size -portion of the geometry argument give the number of -columns and rows to remove. The offset portion of -the geometry argument is influenced by -a -gravity setting, if present.

    - -

    The -chop option removes entire rows and columns, -and moves the remaining corner blocks leftward and upward to close the gaps.

    - -

    While it can remove internal rows and columns of pixels, it is more -typically used with as -gravity setting and zero -offsets so as to remove a single edge from an image. Compare this to -shave which removes equal numbers of pixels from opposite -sides of the image.

    - -

    Using -chop effectively undoes the results of a -splice that was given the same geometry and -gravity settings.

    - -
    -

    -clamp

    -
    - -

    set each pixel whose value is below zero to zero and any the pixel whose value is above the quantum range to the quantum range (e.g. 65535) otherwise the pixel value remains unchanged.

    - -
    -

    -clip

    -
    - -

    Apply the clipping path if one is present.

    - -

    If a clipping path is present, it is applied to subsequent operations.

    - -

    For example, in the command

    - -
    -convert cockatoo.tif -clip -negate negated.tif
    -
    - -

    only the pixels within the clipping path are negated.

    - -

    The -clip feature requires SVG support. If the SVG -delegate library is not present, the option is ignored.

    - -

    Use +clip to disable clipping for subsequent operations.

    - -
    -

    -clip-mask

    -
    - -

    Clip the image as defined by this mask.

    - -

    Use the alpha channel of the current image as a mask. Any areas that is -white is not modified by any of the 'image processing operators' that follow, -until the mask is removed. Pixels in the black areas of the clip mask are -modified per the requirements of the operator.

    - -

    In some ways this is similar to (though not the same) as defining -a rectangular -region, or using the negative of the -mask (third) image in a three image -composite, -operation.

    - -

    Use +clip-mask to disable clipping for subsequent operations.

    - -
    -

    -clip-path id

    -
    - -

    Clip along a named path from the 8BIM profile.

    - -

    This is identical to -clip except choose a specific clip path in the event the image has more than one path available.

    - -

    Use +clip-path to disable clipping for subsequent operations.

    - -
    -

    -clone index(s)

    -
    - -

    make a clone of an image (or images).

    - -

    Inside parenthesis (where the operator is normally used) it will make a -clone of the images from the last 'pushed' image sequence, and adds them to -the end of the current image sequence. Outside parenthesis -(not recommended) it clones the images from the current image sequence.

    - -

    Specify the image by its index in the sequence. The first image is index -0. Negative indexes are relative to the end of the sequence; for -example, −1 -represents the last image of the sequence. Specify a range of images with a -dash (e.g. 0−4). Separate multiple indexes with commas but no -spaces (e.g. 0,2,5). A value of '0−−1 will -effectively clone all the images.

    - -

    The +clone will simply make a copy of the last image -in the image sequence, and is thus equivalent to using a argument of -'−1'.

    - -
    -

    -clut

    -
    - -

    Replace the channel values in the first image using each corresponding channel in the second image as a color lookup table.

    - -

    The second (LUT) image is ordinarily a gradient image containing the -histogram mapping of how each channel should be modified. Typically it is a -either a single row or column image of replacement color values. If larger -than a single row or column, values are taken from a diagonal line from -top-left to bottom-right corners.

    - -

    The lookup is further controlled by the -interpolate setting, which is especially handy for an -LUT which is not the full length needed by the ImageMagick installed Quality -(Q) level. Good settings for this are the 'bilinear' and -'bicubic' interpolation settings, which give smooth color -gradients, and the 'integer' setting for a direct, unsmoothed -lookup of color values.

    - -

    This operator is especially suited to replacing a grayscale image with a -specific color gradient from the CLUT image.

    - -

    Only the channel values defined by the -channel -setting will have their values replaced. In particular, since the default -channel setting is RGB, this means that -transparency (alpha/matte channel) is not affected, unless the -channel setting is modified. When the alpha channel is -set, it is treated by the -clut operator in the same way -as the other channels, implying that alpha/matte values are replaced using the -alpha/matte values of the original image.

    - -

    If either the image being modified, or the lookup image, contains no -transparency (i.e. -alpha is turned 'off') but the -channel setting includes alpha replacement, then it is -assumed that image represents a gray-scale gradient which is used for the -replacement alpha values. That is you can use a gray-scale CLUT image to -adjust a existing images alpha channel, or you can color a gray-scale image -using colors form CLUT containing the desired colors, including transparency. -

    - -

    See also -hald-clut which replaces colors -according to the lookup of the full color RGB value from a 2D representation -of a 3D color cube.

    - - -
    -

    -coalesce

    -
    - -

    Fully define the look of each frame of an GIF animation sequence, to form a 'film strip' animation.

    - -

    Overlay each image in an image sequence according to -its -dispose meta-data, to reproduce the look of -an animation at each point in the animation sequence. All images should be -the same size, and are assigned appropriate GIF disposal settings for the -animation to continue working as expected as a GIF animation. Such frames -are more easily viewed and processed than the highly optimized GIF overlay -images.

    - -

    The animation can be re-optimized after processing using -the -layers method 'optimize', although -there is no guarantee that the restored GIF animation optimization is -better than the original.

    - - -
    -

    -colorize value

    -
    - -

    Colorize the image by an amount specified by value using the color specified by the most recent -fill setting.

    - -

    Specify the amount of colorization as a percentage. Separate colorization -values can be applied to the red, green, and blue channels of the image with -a comma-delimited list of colorization -values (e.g., -colorize 0,0,50).

    - -
    -

    -colormap type

    -
    - -

    Define the colormap type.

    - -

    The type can be shared or private.

    - -

    This option only applies when the default X server visual -is PseudoColor or GrayScale. Refer -to -visual for more details. By default, -a shared colormap is allocated. The image shares colors with -other X clients. Some image colors could be approximated, -therefore your image may look very different than intended. -If private is chosen, the image colors appear exactly -as they are defined. However, other clients may go technicolor -when the image colormap is installed.

    - -
    -

    -colors value

    -
    - -

    Set the preferred number of colors in the image.

    - -

    The actual number of colors in the image may be less than your request, -but never more. Note that this a color reduction option. Images with fewer -unique colors than specified by value will have any -duplicate or unused colors removed. The ordering of an existing color -palette may be altered. When converting an image from color to grayscale, -it is more efficient to convert the image to the gray colorspace before -reducing the number of colors. Refer to -the -color reduction algorithm for more details.

    - -
    -

    -color-matrix matrix

    -
    - -

    apply color correction to the image.

    - -

    This option permits saturation changes, hue rotation, luminance to alpha, -and various other effects. Although variable-sized transformation matrices -can be used, typically one uses a 5x5 matrix for an RGBA image and a 6x6 -for CMYKA (or RGBA with offsets). The matrix is similar to those used by -Adobe Flash except offsets are in column 6 rather than 5 (in support of -CMYKA images) and offsets are normalized (divide Flash offset by 255).

    - -

    As an example, to add contrast to an image with offsets, try this command:

    - -
    -convert kittens.jpg -color-matrix \
    -  " 1.5 0.0 0.0 0.0, 0.0, -0.157 \
    -    0.0 1.5 0.0 0.0, 0.0, -0.157 \
    -    0.0 0.0 1.5 0.0, 0.0, -0.157 \
    -    0.0 0.0 0.0 1.0, 0.0,  0.0 \
    -    0.0 0.0 0.0 0.0, 1.0,  0.0 \
    -    0.0 0.0 0.0 0.0, 0.0,  1.0" kittens.png
    -
    -
    -

    -colorspace value

    -
    - -

    Set the image colorspace.

    - -

    Choices are:

    - -
    -CMY          CMYK         Gray         HCL
    -HCLp         HSB          HSI          HSL
    -HSV          HWB          Lab          LCHab
    -LCHuv        LMS          Log          Luv
    -OHTA         Rec601YCbCr  Rec709YCbCr  RGB
    -scRGB        sRGB         Transparent  xyY
    -XYZ          YCbCr        YCC          YDbDr
    -YIQ          YPbPr        YUV
    -
    - -

    To print a complete list of colorspaces, use -list colorspace.

    - -

    For a more accurate color conversion to or from the linear RGB, CMYK, or grayscale colorspaces, use the -profile option. Note, ImageMagick assumes the sRGB colorspace if the image format does not indicate otherwise. For colorspace conversion, the gamma function is first removed to produce linear RGB.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Conversion of RGB to Other Color Spaces
    CMY
    C=QuantumRange−R
    M=QuantumRange−G
    Y=QuantumRange−B
    CMYK — starts with CMY from above
    K=min(C,Y,M)
    C=QuantumRange*(C−K)/(QuantumRange−K)
    M=QuantumRange*(M−K)/(QuantumRange−K)
    Y=QuantumRange*(Y−K)/(QuantumRange−K)
    Gray
    Gray = 0.298839*R+0.586811*G+0.114350*B
    HSB — Hue, Saturation, Brightness; like a cone peak downward
    H=angle around perimeter (0 to 360 deg); H=0 is red; increasing angles toward green
    S=distance from axis outward
    B=distance along axis from bottom upward; B=max(R,G,B); intensity-like
    HSL — Hue, Saturation, Lightness; like a double cone end-to-end with peaks at very top and bottom
    H=angle around perimeter (0 to 360 deg); H=0 is red; increasing angles toward green
    S=distance from axis outward
    L=distance along axis from bottom upward; L=0.5*max(R,G,B) + 0.5*min(R,G,B); intensity-like
    HWB — Hue, Whiteness, Blackness
    Hue (complicated equation)
    Whiteness (complicated equation)
    Blackness (complicated equation)
    LAB
    L (complicated equation relating X,Y,Z)
    A (complicated equation relating X,Y,Z)
    B (complicated equation relating X,Y,Z)
    LOG
    I1 (complicated equation involving logarithm of R)
    I2 (complicated equation involving logarithm of G)
    I3 (complicated equation involving logarithm of B)
    OHTA — approximates principal components transformation
    I1=0.33333*R+0.33334*G+0.33333*B; intensity-like
    I2=(0.50000*R+0.00000*G−0.50000*B)*(QuantumRange+1)/2
    I3=(−0.25000*R+0.50000*G−0.25000*B)*(QuantumRange+1)/2
    Rec601Luma
    Gray = 0.298839*R+0.586811*G+0.114350*B
    Rec601YCbCr
    Y=0.2988390*R+0.5868110*G+0.1143500*B; intensity-like
    Cb=(−0.168736*R-0.331264*G+0.500000*B)*(QuantumRange+1)/2
    Cr=(0.500000*R−0.418688*G−0.081312*B)*(QuantumRange+1)/2
    Rec709Luma
    Gray=0.212656*R+0.715158*G+0.072186*B
    Rec709YCbCr
    Y=0.212656*R+0.715158*G+0.072186*B; intensity-like
    Cb=(−0.114572*R−0.385428*G+0.500000*B)+(QuantumRange+1)/2
    Cr=(0.500000*R−0.454153*G−0.045847*B)+(QuantumRange+1)/2
    sRGB
    if R ≤ .0.0031308 then Rs=R/12.92 else Rs=1.055 R ^ (1.0 / 2.4) ? 0.055
    if G ≤ .0.0031308 then Gs=B/12.92 else Gs=1.055 R ^ (1.0 / 2.4) ? 0.055
    if B ≤ .0.0031308 then Bs=B/12.92 else Bs=1.055 R ^ (1.0 / 2.4) ? 0.055
    XYZ
    X=0.4124564*R+0.3575761*G+0.1804375*B
    Y=0.2126729*R+0.7151522*G+0.0721750*B
    Z=0.0193339*R+0.1191920*G+0.9503041*B
    YCC
    Y=(0.298839*R+0.586811*G+0.114350*B) (with complicated scaling); intensity-like
    C1=(−0.298839*R−0.586811*G+0.88600*B) (with complicated scaling)
    C2=(0.70100*R−0.586811*G−0.114350*B) (with complicated scaling)
    YCbCr
    Y=0.2988390*R+0.5868110*G+0.1143500*B; intensity-like
    Cb=(−0.168736*R−0.331264*G+0.500000*B)*(QuantumRange+1)/2
    Cr=(0.500000*R−0.418688*G−0.081312*B)*(QuantumRange+1)/2
    YIQ
    Y=0.298839*R+0.586811*G+0.114350*B; intensity-like
    I=(0.59600*R−0.27400*G−0.32200*B)*(QuantumRange+1)/2
    Q=(0.21100*R−0.52300*G+0.31200*B)*(QuantumRange+1)/2
    YPbPr
    Y=0.2988390*R+0.5868110*G+0.1143500*B; intensity-like
    Pb=(−0.168736*R−0.331264*G+0.500000*B)*(QuantumRange+1)/2
    Pr=(0.500000*R−0.418688*G−0.081312*B)*(QuantumRange+1)/2
    YUV
    Y=0.298839*R+0.586811*G+0.114350*B; intensity-like
    U=(−0.14740*R−0.28950*G+0.43690*B)*(QuantumRange+1)/2
    V=(0.61500*R−0.51500*G−0.10000*B)*(QuantumRange+1)/2
    - -

    Note the scRGB colorspace requires HDRI support otherwise it behaves just like linear RGB.

    - -
    -

    -combine

    -
    - -

    Combine one or more images into a single image.

    - -

    The channels (previously set by -channel) of the -combined image are taken from the grayscale values of each image in the -sequence, in order. For the default -channel setting of RGB, this -means the first image is assigned to the Red channel, the second -to the Green channel, the third to the Blue.

    - -

    This option can be thought of as the inverse to -separate, so long as the channel settings are the same. -Thus, in the following example, the final image should be a copy of the -original.

    - -
    -convert original.png -channel RGB -separate sepimage.png
    -convert sepimage-0.png sepimage-1.png sepimage-2.png -channel RGB \
    -  -combine imagecopy.png
    -
    - -
    -

    -comment string

    -
    - -

    Embed a comment in an image.

    - -

    This option sets the comment meta-data of an image read in after this -option has been given. To modify a comment of images already in memory use -"-set comment".

    - -

    The comment can contain special format characters listed in the Format and -Print Image Properties. These attributes are expanded when the comment -is finally assigned to the individual images.

    - -

    If the first character of string is @, the image comment is read from a file titled by the -remaining characters in the string. Comments read in from a file are literal; -no embedded formatting characters are recognized.

    - -

    Comment meta-data are not visible on the image itself. To do that use the --annotate or -draw options -instead.

    - -

    For example,

    - -
    --comment "%m:%f %wx%h"  bird.miff
    -
    - -

    produces an image comment of MIFF:bird.miff 512x480 (assuming -that the image bird.miff has a width of 512 and a height of -480.

    - -
    -

    -compare

    -
    - -

    mathematically and visually annotate the difference between an image and its reconstruction

    - -

    This is a convert version of "compare" for two same sized images. The syntax is as follows, but other metrics are allowed.

    - -
    -convert image.png reference.png -metric RMSE -compare \ 
    difference.png -
    - -

    To get the metric value use the string format "%[distortion]".

    - -
    -convert image.png reference.png -metric RMSE -compare -format \
    -   "%[distortion]" info:
    -
    - -
    -

    -complex operator

    -
    - -

    perform complex mathematics on an image sequence

    - -Choose from these operators: - -
    -add
    -conjugate
    -divide
    -magnitude-phase
    -multiply
    -real-imaginary
    -subtract
    -
    - -

    Optionally specify the divide operator SNR with -define complex:snr=float.

    - -
    -

    -compose operator

    -
    - -

    Set the type of image composition.

    - -

    See Alpha Compositing for -a detailed discussion of alpha compositing.

    - -

    This setting effects image processing operators that merge two (or more) -images together in some way. This includes the operators, --compare, --composite, --layers composite, --flatten, --mosaic, --layers merge, --border, --frame, -and -extent.

    - -

    It is also one of the primary options for the "composite" -command.

    - - -
    -

    -composite

    -
    - -

    Perform alpha composition on two images and an optional mask

    - -

    Take the first image 'destination' and overlay the second 'source' image -according to the current -compose setting. The location -of the 'source' or 'overlay' image is controlled according to -gravity, and -geometry -settings.

    - -

    If a third image is given this is treated as a gray-scale blending 'mask' image -relative to the first 'destination' image. This mask is blended with the -source image. However for the 'displace' compose method, the -mask is used to provide a separate Y-displacement image instead.

    - -

    If a -compose method requires extra numerical -arguments or flags these can be provided by setting the -set 'option:compose:args' -appropriately for the compose method.

    - -

    Some -compose methods can modify the 'destination' -image outside the overlay area. You can disable this by setting the special -set 'option:compose:outside-overlay' -to 'false'.

    - -

    The SVG compositing specification requires that color and opacity values range between zero and QuantumRange inclusive. You can permit values outside this range with this option: -set 'option:compose:clamp=false

    - - -
    -

    -compress type

    -
    - -

    Use pixel compression specified by type when writing the image.

    - -

    Choices are: None, BZip, Fax, Group4, JPEG, JPEG2000, Lossless, LZW, RLE or Zip.

    - -

    To print a complete list of compression types, use -list -compress.

    - -

    Specify +compress to store the binary image in an -uncompressed format. The default is the compression type of the specified -image file.

    - -

    If LZW compression is specified but LZW compression has not been -enabled, the image data is written in an uncompressed LZW format that can be -read by LZW decoders. This may result in larger-than-expected GIF files.

    - -

    Lossless refers to lossless JPEG, which is only available if the -JPEG library has been patched to support it. Use of lossless JPEG is generally -not recommended.

    - -

    -When writing an ICO file, you may request that the images be encoded in -PNG format, by specifying Zip compression.

    - -

    -When writing a JNG file, specify Zip compression to request that -the alpha channel be encoded in PNG "IDAT" format, or JPEG -to request that it be encoded in JPG "JDAA" format.

    - -

    Use the -quality option to set the compression level -to be used by JPEG, PNG, MIFF, and MPEG encoders. -Use the -sampling-factor option to set the -sampling factor to be used by JPEG, MPEG, and YUV encoders for down-sampling -the chroma channels.

    - -
    -

    -connected-components connectivity

    -
    - -

    connected-components labeling detects connected regions in an image, choose from 4 or 8 way connectivity.

    - -

    Use -define connected-components:verbose=true to output statistics associated with each unique label.

    - -
    -

    -contrast

    -
    - -

    Enhance or reduce the image contrast.

    - -

    This option enhances the intensity differences between the lighter and -darker elements of the image. Use -contrast to enhance -the image or +contrast to reduce the image -contrast.

    - -

    For a more pronounced effect you can repeat the option:

    - -
    -convert rose: -contrast -contrast rose_c2.png
    -
    - -
    -

    -contrast-stretch black-point
    -contrast-stretch black-point{xwhite-point}{%}}

    -
    - -

    Increase the contrast in an image by stretching the range of intensity values.

    - -

    While performing the stretch, black-out at most black-point pixels and white-out at most white-point pixels. Or, if percent is used, black-out at most -black-point % pixels and white-out at most white-point % pixels.

    - -

    Prior to ImageMagick 6.4.7-0, -contrast-stretch will black-out at most black-point pixels and white-out at most total pixels -minus white-point pixels. Or, if percent is used, black-out at most black-point % pixels and white-out at most 100% minus white-point % pixels.

    - -

    Note that -contrast-stretch 0 will modify the image such that -the image's min and max values are stretched to 0 and QuantumRange, respectively, without any loss of data due to burn-out or -clipping at either end. This is not the same as -normalize, which is equivalent to -contrast-stretch 0.15x0.05% (or -prior to ImageMagick 6.4.7-0, -contrast-stretch 2%x99%).

    - -

    Internally operator works by creating a histogram bin, and then uses that -bin to modify the image. As such some colors may be merged together when they -originally fell into the same 'bin'.

    - -

    All the channels are normalized in concert by the came amount so as to -preserve color integrity, when the default +channel -setting is in use. Specifying any other -channel -setting will normalize the RGB channels independently.

    - -

    See also -auto-level for a 'perfect' -normalization of mathematical images.

    - -

    This operator is under review for re-development.

    - - -
    -

    -convolve kernel

    -
    - -

    Convolve an image with a user-supplied convolution kernel.

    - -

    The kernel is a matrix specified as -a comma-separated list of integers (with no spaces), ordered left-to right, -starting with the top row. Presently, only odd-dimensioned kernels are -supported, and therefore the number of entries in the specified kernel must be 32=9, 52=25, -72=49, etc.

    - -

    Note that the ‑convolve operator supports the ‑bias setting. This option shifts the convolution so that -positive and negative results are relative to a user-specified bias value. -This is important for non-HDRI compilations of ImageMagick when dealing with -convolutions that contain negative as well as positive values. This is -especially the case with convolutions involving high pass filters or edge -detection. Without an output bias, the negative values is clipped at zero. -

    - -

    When using an ImageMagick with the HDRI compile-time setting, ‑bias is not needed, as ImageMagick is able to store/handle any -negative results without clipping to the color value range (0..QuantumRange). -See the discussion on HDRI implementations of ImageMagick on the page High -Dynamic-Range Images. For more about HDRI go the ImageMagick Usage pages or this -Wikipedia -entry.

    - - -
    -

    -copy geometry offset

    -
    - -

    copy pixels from one area of an image to another.

    - -
    -

    -crop geometry{@}{!}

    -
    - -

    Cut out one or more rectangular regions of the image.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -

    The width and height of the geometry argument give the size of the image that remains -after cropping, and x and y in the -offset (if present) gives the location of the top left -corner of the cropped image with respect to the original image. To specify the -amount to be removed, use -shave instead.

    - -

    If the x and y offsets are -present, a single image is generated, consisting of the pixels from the -cropping region. The offsets specify the location of the upper left corner of -the cropping region measured downward and rightward with respect to the upper -left corner of the image. If the -gravity option is -present with NorthEast, East, or SouthEast -gravity, it gives the distance leftward from the right edge of the image to -the right edge of the cropping region. Similarly, if the -gravity option is present with SouthWest, -South, or SouthEast gravity, the distance is measured -upward between the bottom edges.

    - -

    If the x and y offsets are -omitted, a set of tiles of the specified geometry, covering the entire input -image, is generated. The rightmost tiles and the bottom tiles are smaller if -the specified geometry extends beyond the dimensions of the input image.

    - -

    You can add the @ to the geometry argument to equally divide the image into the number of tiles generated.

    - -

    By adding a exclamation character flag to the geometry argument, the -cropped images virtual canvas page size and offset is set as if the -geometry argument was a viewport or window. This means the canvas page size -is set to exactly the same size you specified, the image offset set -relative top left corner of the region cropped.

    - -

    If the cropped image 'missed' the actual image on its virtual canvas, a -special single pixel transparent 'missed' image is returned, and a 'crop -missed' warning given.

    - -

    It might be necessary to +repage the image prior to -cropping the image to ensure the crop coordinate frame is relocated to the -upper-left corner of the visible image. - -Similarly you may want to use +repage after cropping to -remove the page offset that will be left behind. This is especially true when -you are going to write to an image format such as PNG that supports an image -offset.

    - -
    -

    -cycle amount

    -
    - -

    displace image colormap by amount.

    - -

    Amount defines the number of positions each -colormap entry is shifted.

    - - -
    -

    -debug events

    -
    - -

    enable debug printout.

    - -

    The events parameter specifies which events are to be logged. It -can be either None, All, Trace, or -a comma-separated list consisting of one or more of the following domains: -Accelerate, Annotate, Blob, Cache, -Coder, Configure, Deprecate, -Exception, Locale, Render, -Resource, Security, TemporaryFile, -Transform, X11, or User.

    - - -

    For example, to log cache and blob events, use.

    - -
    -convert -debug "Cache,Blob" rose: rose.png
    -
    - -

    The User domain is normally empty, but developers can log user -events in their private copy of ImageMagick.

    - -

    To print the complete list of debug methods, use -list -debug.

    - -

    Use the -log option to specify the format for debugging -output.

    - -

    Use +debug to turn off all logging.

    - -

    Debugging may also be set using the MAGICK_DEBUG environment variable. The allowed values for the MAGICK_DEBUG -environment variable are the same as for the -debug -option.

    - - -
    -

    -decipher filename

    -
    - -

    Decipher and restore pixels that were previously transformed by -encipher.

    - -

    Get the passphrase from the file specified by filename.

    - -

    For more information, see the webpage, ImageMagick: Encipher or -Decipher an Image.

    - - -
    -

    -deconstruct

    -
    - -

    find areas that has changed between images

    - -

    Given a sequence of images all the same size, such as produced by -coalesce, replace the second and later images, with -a smaller image of just the area that changed relative to the previous image. -

    - -

    The resulting sequence of images can be used to optimize an animation -sequence, though will not work correctly for GIF animations when parts of the -animation can go from opaque to transparent.

    - -

    This option is actually equivalent to the -layers -method 'compare-any'.

    - - -
    -

    -define key{=value}...

    -
    - -

    add specific global settings generally used to control coders and image processing operations.

    - -

    This option creates one or more definitions for coders and decoders to use -while reading and writing image data. Definitions are generally used to -control image file format coder modules, and image processing operations, -beyond what is provided by normal means. Defined settings are listed in -verbose information ("info:" output format) -as "Artifacts".

    - -

    If value is missing for a definition, an empty-valued -definition of a flag is created with that name. This used to control on/off -options. Use +define key to remove definitions -previously created. Use +define "*" to remove all -existing definitions.

    - -

    The same 'artifact' settings can also be defined using the -set "option:key" "value" option, which also allows the use of Format and Print Image -Properties in the defined value.

    - -

    The option and key are case-independent (they are -converted to lowercase for use within the decoders) while the value -is case-dependent.

    - -

    Such settings are global in scope, and affect all images and operations.

    - -

    The following definitions are just some of the artifacts that are -available:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - . If this - option is omitted, the default is GIF for PseudoClass - images and PNM for DirectClass images. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - . - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    bmp:format=value valid values are bmp2, bmp3, - and bmp4. This option can be useful when the - method of prepending "BMP2:" to the output filename is inconvenient or - is not available, such as when using the mogrify utility.
    colorspace:auto-grayscale=on|offprevent automatic conversion to grayscale inside coders that support - grayscale. This should be accompanied by -type truecolor. PNG and TIF do - not need this define. With PNG, just use PNG24:image. With TIF, just use - -type truecolor. JPG and PSD will need this define.
    complex:snr=valueSet the divide SNR constant-complex
    compose:args=argumentsSets certain compose argument values when using convert ... -compose ... - -composite. See Image Composition
    compose:clamp=on|offset each pixel whose value is below zero to zero and any the pixel whose value is above the quantum range to the quantum range (e.g. 65535) otherwise the pixel value remains unchanged. Define supported in ImageMagick 6.9.1-3 and above.
    connected-components:area-threshold=valueMerges any region with area smaller than value into its surrounding region or largest neighbor.
    connected-components:keep=list-of-idsCommand and/or hyphenated list of id values to keep in the output. Supported in Imagemagick 6.9.3-0.
    connected-components:mean-color=trueChanges the output image from id values to mean color values. Supported in Imagemagick 6.9.2-8.
    connected-components:remove=list-of-idsCommand and/or hyphenated list of id values to remove from the output. Supported in Imagemagick 6.9.2-9.
    connected-components:verbose=trueLists id, bounding box, centroid, area, mean color for each region.
    convolve:scale={kernel_scale}[!^] [,{origin_addition}] [%]Defines the kernel scaling. The special flag ! automatically scales to - full dynamic range. The ! flag can be used in combination with a factor or - percent. The factor or percent is then applied after the automatic scaling. - An example is 50%!. This produces a result 50% darker than full dynamic - range scaling. The ^ flag assures the kernel is 'zero-summing', for - example when some values are positive and some are negative as in edge - detection kernels. The origin addition adds that value to the center - pixel of the kernel. This produces and effect that is like adding the image - that many times to the result of the filtered image. The typical value - is 1 so that the original image is added to the result of the convolution. - The default is 0.
    convolve:showkernel=1Outputs (to 'standard error') all the information about a specified -morphology convolve kernel.
    dcm:display-range=resetSets the display range to the minimum and maximum pixel values for the - DCM image format.
    dds:cluster-fit=true|falseEnables the dds cluster-fit.
    dds:compression=dxt1|dxt5|noneSets the dds compression.
    dds:mipmaps=valueSets the dds number of mipmaps.
    dds:weight-by-alpha=true|falseEnables the dds alpha weighting.
    delegate:bimodal=trueSpecifies direct conversion from Postscript to PDF.
    distort:scale=valueSets the output scaling factor for use with -distort
    distort:viewport=WxH+X+YSets the viewport for use with -distort
    dot:layout-engine=valueSpecifies the layout engine for the DOT image format (e.g. - neato).
    filter:option=valueSet a filter option for use with -resize. - See -filter for details.
    fourier:normalize=inverseSets the location for the FFT/IFT normalization as use by - +-fft and +-ift. The default is - forward.
    h:format=valueSet the image encoding format use when writing a C-style header. - format can be any output format supported by ImageMagick - except for h and magick
    icon:auto-resizeAutomatically stores multiple sizes when writing an ico image - (requires a 256x256 input image).
    jp2:layer-number=valueSets the maximum number of quality layers to decode. Same for JPT, JC2, - and J2K
    jp2:number-resolutions=valueSets the number of resolutions to encode.Same for JPT, JC2, and J2K
    jp2:progression-order=valuechoose from LRCP, RLCP, RPCL, PCRL or CPRL. Same for JPT, JC2, and - J2K
    jp2:quality=value,value...Sets the quality layer PSNR, given in dB. The order is from left to - right in ascending order. The default is a single lossless quality layer. - Same for JPT, JC2, and J2K
    jp2:rate=valueSpecify the compression factor to use while writing JPEG-2000 files. The - compression factor is the reciprocal of the compression ratio. The valid - range is 0.0 to 1.0, with 1.0 indicating lossless compression. If defined, - this value overrides the -quality setting. A quality setting of 75 - results in a rate value of 0.06641. Same for JPT, JC2, and J2K
    jp2:reduce-factor=valueSets the number of highest resolution levels to be discarded.Same for - JPT, JC2, and J2K
    jpeg:block-smoothing=on|off 
    jpeg:colors=valueSet the desired number of colors and let the JPEG encoder do the - quantizing.
    jpeg:dct-method=valueChoose from default, fastest, - float, ifast, and islow.
    jpeg:extent=valueRestrict the maximum JPEG file size, for example -define - jpeg:extent=400KB. The JPEG encoder will search for the highest - compression quality level that results in an output file that does not - exceed the value. The -quality option also will be respected - starting with version 6.9.2-5. Between 6.9.1-0 and 6.9.2-4, add -quality - 100 in order for the jpeg:extent to work properly. Prior to 6.9.1-0, the - -quality setting was ignored.
    jpeg:fancy-upsampling=on|off 
    jpeg:optimize-coding=on|off 
    jpeg:q-table=table 
    jpeg:sampling-factor=sampling-factor-string 
    jpeg:size=geometrySet the size hint of a JPEG image, for - example, -define jpeg:size=128x128. - It is most useful for increasing performance and reducing the memory - requirements when reducing the size of a large JPEG image.
    json:featuresincludes features in verbose information
    json:limit 
    json:locate 
    json:momentsincludes image moments in verbose information
    magick:format=valueSet the image encoding format use when writing a C-style header. - This is the same as "h:format=format" described above.
    mng:need-cacheoffturn playback caching off for streaming MNG.
    morphology:compose=compose-methodSpecifies how to merge results generated by multiple-morphology kernel. The default is none. One - typical value is 'lighten' as used, for example, with the sobel edge - kernels.
    morphology:showkernel=1Outputs (to 'standard error') all the information about a generated -morphology kernel.
    pcl:fit-to-page=true
    pdf:fit-page=geometry geometry specifies the scaling dimensions for resizing when the PDF is - being read. The geometry is either WxH{%} or page size. No offsets are - allowed. (introduced in IM 6.8.8-8)
    pdf:fit-to-page=true 
    pdf:use-cropbox=true 
    pdf:use-trimbox=true 
    png:bit-depth=value 
    png:color-type=valuedesired bit-depth and color-type for PNG output. You can force the PNG - encoder to use a different bit-depth and color-type than it would have - normally selected, but only if this does not cause any loss of image - quality. Any attempt to reduce image quality is treated as an error and no - PNG file is written. E.g., if you have a 1-bit black-and-white image, you - can use these "defines" to cause it to be written as an 8-bit grayscale, - indexed, or even a 64-bit RGBA. But if you have a 16-million color image, - you cannot force it to be written as a grayscale or indexed PNG. If you - wish to do this, you must use the appropriate -depth, - -colors, or -type directives to - reduce the image quality prior to using the PNG encoder. Note that in - indexed PNG files, "bit-depth" refers to the number of bits per index, - which can be 1, 2, 4, or 8. In such files, the color samples always have - 8-bit depth.
    png:compression-filter=value valid values are 0 through 9. 0-4 are the corresponding PNG filters, - 5 means adaptive filtering except for images with a colormap, 6 means - adaptive filtering for all images, 7 means MNG "loco" compression, 8 means - Z_RLE strategy with adaptive filtering, and 9 means Z_RLE strategy with no - filtering.
    png:compression-level=value valid values are 0 through 9, with 0 providing the least but fastest - compression and 9 usually providing the best and always the slowest.
    png:compression-strategy=value valid values are 0 through 4, meaning default, filtered, huffman_only, - rle, and fixed ZLIB compression strategy. If you are using an old zlib - that does not support Z_RLE (before 1.2.0) or Z_FIXED (before 1.2.2.2), - values 3 and 4, respectively, will use the zlib default strategy - instead.
    png:format=value valid values are png8, png24, - png32, png48, - png64, and png00. - This property can be useful for specifying - the specific PNG format to be used, when the usual method of prepending the - format name to the output filename is inconvenient, such as when writing - a PNG-encoded ICO file or when using mogrify. - Value = png8 reduces the number of colors to 256, - only one of which may be fully transparent, if necessary. The other - values do not force any reduction of quality; it is an error to request - a format that cannot represent the image data without loss (except that - it is allowed to reduce the bit-depth from 16 to 8 for all formats). - Value = png24 and png48 - allow transparency, only if a single color is fully transparent and that - color does not also appear in an opaque pixel; such transparency is - written in a PNG tRNS chunk. - Value = png00 causes the image to inherit its - color-type and bit-depth from the input image, if the input was also - a PNG.
    png:exclude-chunk=value
    png:include-chunk=valueancillary chunks to be excluded from or included in PNG output. - -

    The value can be the name of a PNG chunk-type such - as bKGD, a comma-separated list of chunk-names - (which can include the word date, the word - all, or the word none). - Although PNG chunk-names are case-dependent, you can use all lowercase - names if you prefer.

    - -

    The "include-chunk" and "exclude-chunk" lists only affect the behavior - of the PNG encoder and have no effect on the PNG decoder.

    - -

    As a special case, if the sRGB chunk is excluded and - the gAMA chunk is included, the gAMA chunk will - only be written if gamma is not 1/2.2, since most decoders assume - sRGB and gamma=1/2.2 when no colorspace information is included in - the PNG file. Because the list is processed from left to right, you - can achieve this with a single define:

    - -
    --define png:include-chunk=none,gAMA
    -
    - -

    As a special case, if the sRGB chunk is not excluded and - the PNG encoder recognizes that the image contains the sRGB ICC profile, - the PNG encoder will write the sRGB chunk instead of the - entire ICC profile. To force the PNG encoder to write the sRGB - profile as an iCCP chunk in the output PNG instead of the - sRGB chunk, exclude the sRGB chunk.

    - -

    The critical PNG chunks IHDR, PLTE, - IDAT, and IEND cannot be excluded. Any such - entries appearing in the list will be ignored.

    - -

    If the ancillary PNG tRNS chunk is excluded and the - image has transparency, the PNG colortype is forced to be 4 or 6 - (GRAY_ALPHA or RGBA). If the image is not transparent, then the - tRNS chunk isn't written anyhow, and there is no effect - on the PNG colortype of the output image.

    - -

    The -strip option does the equivalent of the - following for PNG output:

    - -
    --define png:exclude-chunk=EXIF,iCCP,iTXt,sRGB,tEXt,zCCP,zTXt,date
    -
    - -

    The default behavior is to include all known PNG ancillary chunks - plus ImageMagick's private vpAg ("virtual page") chunk, - and to exclude all PNG chunks that are unknown to ImageMagick, - regardless of their PNG "copy-safe" status as described in the - PNG specification.

    - -

    Any chunk names that are not known to ImageMagick are ignored - if they appear in either the "include-chunk" or "exclude-chunk" list. - The ancillary chunks currently known to ImageMagick are - bKGD, cHRM, gAMA, iCCP, - oFFs, pHYs, sRGB, tEXt, - tRNS, vpAg, and zTXt.

    - -

    You can also put date in the list to include or exclude - the "Date:create" and "Date:modify" text chunks that ImageMagick normally - inserts in the output PNG.

    png:preserve-colormap[=true]Use the existing image->colormap. Normally the PNG encoder will - try to optimize the palette, eliminating unused entries and putting - the transparent colors first. If this flag is set, that behavior - is suppressed.
    png:preserve-iCCP[=true]By default, the PNG decoder and encoder examine any ICC profile - that is present, either from an iCCP chunk in the PNG - input or supplied via an option, and if the profile is recognized - to be the sRGB profile, converts it to the sRGB chunk. - You can use -define png:preserve-iCCP to prevent - this from happening; in such cases the iCCP chunk - will be read or written and no sRGB chunk will be - written. There are some ICC profiles that claim to be sRGB but - have various errors that cause them to be rejected by libpng16; such - profiles are recognized anyhow and converted to the sRGB - chunk, but are rejected if the -define png:preserve-iCCP - is present. Note that not all "sRGB" ICC profiles are recognized - yet; we will add them to the list as we encounter them.
    png:swap-bytes[=true]The PNG specification requires that any multi-byte integers be stored in - network byte order (MSB-LSB endian). This option allows you to - fix any invalid PNG files that have 16-bit samples stored incorrectly - in little-endian order (LSB-MSB). The "-define png:swap-bytes" option - must appear before the input filename on the commandline. The swapping - is done during the libpng decoding operation.
    profile:skip=name1,name2,...Skip the named profile[s] when reading the image. Use skip="*" to - skip all named profiles in the image. Many named profiles exist, - including ICC, EXIF, APP1, IPTC, XMP, and others.
    ps:imagemaskIf the ps:imagemask flag is defined, the PS3 and EPS3 coders will - create Postscript files that render bilevel images with the Postscript - imagemask operator instead of the image operator.
    psd:alpha-unblend=offDisables new automatic un-blending of transparency with the base image - for the flattened layer 0 before adding the alpha channel to the output - image. This define must be placed before the input psd image. (Available - as of IM 6.9.2.5). The automatic un-blending is new to IM 6.9.2.5 and - prevents the transparency from being applied twice in the output - image.
    quantum:format=typeSet the type to floating-point to specify a floating-point - format for raw files (e.g. GRAY:) or for MIFF and TIFF images in HDRI mode - to preserve negative values. If -depth 16 is - included, the result is a single precision floating point format. - If -depth 32 is included, the result is - double precision floating point format.
    quantum:polarity=photometric-interpretationSet the photometric-interpretation of an image (typically for TIFF image - file format) to either min-is-black (default) or - min-is-white.
    sample:offset=geometryLocation of the sampling point within the sub-region being sampled, - expressed as percentages (see -sample).
    showkernel=1Outputs (to 'standard error') all the information about a generated -morphology kernel.
    stream:buffer-size=valueSet the stream buffer size. Select 0 for unbuffered I/O.
    tiff:alpha=associated|unassociated|unspecifiedSpecify the alpha extra samples as associated, unassociated or unspecified
    tiff:endian=msb|lsb 
    tiff:exif-properties=falseSkips reading the EXIF properties.
    tiff:fill-order=msb|lsb 
    tiff:ignore-layers=trueIgnores the photoshop layers.
    tiff:ignore-tags=comma-separate-list-of-tag-IDsAllows one or more tag ID values to be ignored.
    tiff:rows-per-strip=valueSets the number of rows per strip
    tiff:tile-geometry=WxHSets the tile size for pyramid tiffs. Requires the suffix - PTIF: before the outputname
    - -

    For example, to create a postscript file that will render only the black -pixels of a bilevel image, use:

    - -
    -convert bilevel.tif -define ps:imagemask eps3:stencil.ps
    -
    - -

    Set attributes of the image registry by prefixing the value with -registry:. For example, to set a temporary path to put work files, -use:

    - -
    --define registry:temporary-path=/data/tmp
    -
    - -
    -

    -delay ticks
    -delay ticksxticks-per-second {<} {>}

    -
    - -

    display the next image after pausing.

    - -

    This option is useful for regulating the animation of image sequences -ticks/ticks-per-second seconds must expire before the display of the -next image. The default is no delay between each showing of the image -sequence. The default ticks-per-second is 100.

    - -

    Use > to change the image delay only if its current -value exceeds the given delay. < changes the image delay -only if current value is less than the given delay. For example, if -you specify 30> and the image delay is 20, the image delay does -not change. However, if the image delay is 40 or 50, the delay it is changed -to 30. Enclose the given delay in quotation marks to prevent the -< or > from being interpreted by your shell as -a file redirection.

    - - -
    -

    -delete indexes

    -
    - -

    delete the images specified by index, from the image sequence.

    - -

    Specify the image by its index in the sequence. The first image is index -0. Negative indexes are relative to the end of the sequence, for example, -1 -represents the last image of the sequence. Specify a range of images with -a dash (e.g. 0-4). Separate indexes with a comma (e.g. 0,2). Use -+delete to delete the last image in the current image sequence.

    - - -
    -

    -density width
    -density widthxheight

    -
    - -

    Set the horizontal and vertical resolution of an image for rendering to devices.

    - -

    This option specifies the image resolution to store while encoding a raster -image or the canvas resolution while rendering (reading) vector formats such -as Postscript, PDF, WMF, and SVG into a raster image. Image resolution -provides the unit of measure to apply when rendering to an output device or -raster image. The default unit of measure is in dots per inch (DPI). The -units option may be used to select dots per centimeter -instead.

    - -

    The default resolution is 72 dots per inch, which is equivalent to one -point per pixel (Macintosh and Postscript standard). Computer screens are -normally 72 or 96 dots per inch, while printers typically support 150, 300, -600, or 1200 dots per inch. To determine the resolution of your display, use -a ruler to measure the width of your screen in inches, and divide by the -number of horizontal pixels (1024 on a 1024x768 display).

    - -

    If the file format supports it, this option may be used to update the -stored image resolution. Note that Photoshop stores and obtains image -resolution from a proprietary embedded profile. If this profile is not -stripped from the image, then Photoshop will continue to treat the image using -its former resolution, ignoring the image resolution specified in the standard -file header.

    - -

    The -density option sets an attribute and -does not alter the underlying raster image. It may be used to adjust the -rendered size for desktop publishing purposes by adjusting the scale applied -to the pixels. To resize the image so that it is the same size at a different -resolution, use the -resample option.

    - -
    -

    -depth value

    -
    - -

    depth of the image.

    - -

    This the number of bits in a color sample within a pixel. Use this option -to specify the depth of raw images whose depth is unknown such as GRAY, RGB, -or CMYK, or to change the depth of any image after it has been read.

    - -
    -

    -descend

    -
    - -

    obtain image by descending window hierarchy.

    - -
    -

    -deskew threshold

    -
    - -

    straighten an image. A threshold of 40% works for most images.

    - -

    Use -set option:deskew:auto-crop -width to auto crop the image. The set argument is the pixel -width of the image background (e.g 40).

    - -
    -

    -despeckle

    -
    - -

    reduce the speckles within an image.

    - -
    -

    -direction type

    -
    - -

    render text right-to-left or left-to-right.

    - -
    -

    -displace horizontal-scale
    -displace horizontal-scalexvertical-scale

    -
    - -

    shift image pixels as defined by a displacement map.

    - -

    With this option, the 'overlay' image, and optionally the 'mask' image, -is used as a displacement map, which is used to displace the lookup of -what part of the 'background' image is seen at each point of the overlaid -area. Much like the displacement map is a 'lens' that redirects light shining -through it so as to present a distorted view the original 'background' image -behind it.

    - -

    Any perfect grey areas of the displacement map produce a zero -displacement of the image. Black areas produce the given maximum negative -displacement of the lookup point, while white produce a maximum positive -displacement of the lookup.

    - -

    Note that it is the lookup of the 'background' that is displaced, not a -displacement of the image itself. As such an area of the displacement map -containing 'white' will have the lookup point 'shifted' by a positive amount, -and thus generating a copy of the destination image to the right/downward from -the correct position. That is the image will look like it may have been -'shifted' in a negative left/upward direction. Understanding this is a very -important in understanding how displacement maps work.

    - -

    The given arguments define the maximum amount of displacement in pixels -that a particular map can produce. If the displacement scale is large enough -it is also possible to lookup parts of the 'background' image that lie well -outside the bounds of the displacement map itself. That is you could very -easily copy a section of the original image from outside the overlay area -into the overlay area.

    - -

    The '%' flag makes the displacement scale relative to the size of the -overlay image (100% = half width/height of image). Using '!' switches -percentage arguments to refer to the destination image size instead. -these flags were added as of IM v6.5.3-5.

    - -

    Normally a single grayscale displacement map is provided, which with the -given scaling values will determine a single direction (vector) in which -displacements can occur (positively or negatively). However, if you also -specify a third image which is normally used as a mask, -the composite image is used for horizontal X -displacement, while the mask image is used for vertical Y -displacement. This allows you to define completely different displacement -values for the X and Y directions, and allowing you to lookup any point within -the scale bounds. In other words each pixel can lookup -any other nearby pixel, producing complex 2 dimensional displacements, rather -than a simple 1 dimensional vector displacements.

    - -

    Alternatively rather than supplying two separate images, as of IM v6.4.4-0, -you can use the 'red' channel of the overlay image to specify the horizontal -or X displacement, and the 'green' channel for the vertical or Y displacement. -

    - -

    As of IM v6.5.3-5 any alpha channel in the overlay image is used as a -mask the transparency of the destination image. However areas outside the -overlaid areas will not be effected.

    - - -
    -

    -display host:display[.screen]

    -
    - -

    Specifies the X server to contact.

    - -

    This option is used with convert for obtaining image or font from this -X server. See X(1).

    - -
    -

    -dispose method

    -
    - -

    define the GIF disposal image setting for images that are being created or read in.

    - -

    The layer disposal method defines the way each the displayed image is to be -modified after the current 'frame' of an animation has finished being -displayed (after its 'delay' period), but before the next frame on an -animation is to be overlaid onto the display.

    - -

    Here are the valid methods:

    - -
    -
    Undefined
    0: No disposal specified (equivalent to 'none').
    -
    None
    1: Do not dispose, just overlay next frame image.
    -
    Background
    2: Clear the frame area with the background color.
    -
    Previous
    3: Clear to the image prior to this frames overlay.
    -
    - -

    You can also use the numbers given above, which is what the GIF format -uses internally to represent the above settings.

    - -

    To print a complete list of dispose methods, use -list dispose.

    - -

    Use +dispose, turn off the setting and prevent -resetting the layer disposal methods of images being read in.

    - -

    Use -set 'dispose' method to set the image -disposal method for images already in memory.

    - -
    -

    -dissimilarity-threshold value

    -
    - -

    maximum RMSE for subimage match (default 0.2).

    - - -
    -

    -dissolve src_percent[xdst_percent]

    -
    - -

    dissolve an image into another by the given percent.

    - -

    The opacity of the composite image is multiplied by the given percent, then -it is composited 'over' the main image. If src_percent -is greater than 100, start dissolving the main image so it becomes -transparent at a value of '200'. If both percentages -are given, each image are dissolved to the percentages given.

    - -

    Note that dissolve percentages do not add, two opaque images dissolved -'50,50', produce a 75% transparency. For a 50% + 50% blending of the two -images, you would need to use dissolve values of '50,100'.

    - -
    -

    -distort method arguments

    -
    - -

    distort an image, using the given method and its required arguments.

    - -

    The arguments is a single string containing a list -of floating point numbers separated by commas or spaces. The number of -and meaning of the floating point values depends on the distortion method being used.

    - -

    Choose from these distortion types:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    ScaleRotateTranslate
    SRT
    - Distort image by first scaling and rotating about a given 'center', - before translating that 'center' to the new location, in that order. It - is an alternative method of specifying a 'Affine' type of - distortion, but without shearing effects. It also provides a good way - of rotating and displacing a smaller image for tiling onto a larger - background (IE 2-dimensional animations).
    - - The number of arguments determine the specific meaning of each - argument for the scales, rotation, and translation operations.
    - -
    -
    2:
    Scale Angle
    -
    3:
    X,Y Angle
    -
    4:
    X,Y Scale Angle
    -
    5:
    X,Y ScaleX,ScaleY Angle
    -
    6:
    X,Y Scale Angle NewX,NewY
    -
    7:
    X,Y ScaleX,ScaleY Angle NewX,NewY
    -
    - - This is actually an alternative way of specifying a 2 dimensional linear - 'Affine' or 'AffineProjection' distortion.
    Affine - Distort the image linearly by moving a list of at least 3 or more sets - of control points (as defined below). Ideally 3 sets or 12 floating - point values are given allowing the image to be linearly scaled, - rotated, sheared, and translated, according to those three points. See - also the related 'AffineProjection' and 'SRT' - distortions.
    - - More than 3 sets given control point pairs (12 numbers) is least - squares fitted to best match a linear affine distortion. If only 2 - control point pairs (8 numbers) are given a two point image translation - rotation and scaling is performed, without any possible shearing, - flipping or changes in aspect ratio to the resulting image. If only one - control point pair is provides the image is only translated, (which may - be a floating point non-integer translation).
    - - This distortion does not include any form of perspective distortion. -
    AffineProjection - Linearly distort an image using the given Affine Matrix of 6 - pre-calculated coefficients forming a set of Affine Equations to map - the source image to the destination image. - -

    - sx, rx, - ry, sy, - tx, ty -

    - - See -affine setting for more detail, and - meanings of these coefficients.
    - - The distortions 'Affine' and 'SRT' provide - alternative methods of defining this distortion, with ImageMagick doing - the calculations needed to generate the required coefficients. You can - see the internally generated coefficients, by using a -verbose setting with those other variants.
    BilinearForward
    - BilinearReverse
    - Bilinear Distortion, given a minimum of 4 sets of coordinate pairs, or - 16 values (see below). Not that lines may not appear straight after - distortion, though the distance between coordinates will remain - consistent.
    - - The 'BilinearForward' is used to map rectangles to any - quadrilateral, while the 'BilinearReverse' form maps any - quadrilateral to a rectangle, while preserving the straight line edges - in each case.
    - - Note that 'BilinearForward' can generate invalid pixels - which will be colored using the -mattecolor - color setting. Also if the quadrilateral becomes 'flipped' the image - may disappear.
    - - There are future plans to produce a true Bilinear distortion that will - attempt to map any quadrilateral to any other quadrilateral, while - preserving edges (and edge distance ratios). - -
    Perspective - Perspective distort the images, using a list of 4 or more sets of - control points (as defined below). More that 4 sets (16 numbers) of - control points provide least squares fitting for more accurate - distortions (for the purposes of image registration and panorama - effects). Less than 4 sets will fall back to a 'Affine' - linear distortion.
    - - Perspective Distorted images ensures that straight lines remain - straight, but the scale of the distorted image will vary. The horizon - is anti-aliased, and the 'sky' color may be set using the - -mattecolor setting.
    PerspectiveProjection - Do a 'Perspective' distortion biased on a set of 8 - pre-calculated coefficients. You can get these coefficients by looking - at the -verbose output of a - 'Perspective' distortion, or by calculating them yourself. - If the last two perspective scaling coefficients are zero, the - remaining 6 represents a transposed 'Affine Matrix'.
    Arc - Arc the image (variation of polar mapping) over the angle given around - a circle. - -

    -
    arc_angle
    -
    The angle over which to arc the image side-to-side
    -
    rotate_angle
    -
    Angle to rotate resulting image from vertical center
    -
    top_radius
    -
    Set top edge of source image at this radius
    -
    bottom_radius
    -
    Set bottom edge to this radius (radial scaling)
    -

    - - The resulting image is always resized to best fit the resulting image, - (as if using +distort) while attempting to - preserve scale and aspect ratio of the original image as much as - possible with the arguments given by the user. All four arguments will - be needed to change the overall aspect ratio of an 'Arc'ed image.
    - - This a variation of a polar distortion designed to try to preserve the - aspect ratio of the image rather than direct Cartesian to Polar - conversion.
    Polar - Like 'Arc' but do a complete Cartesian to Polar mapping of - the image. that is the height of the input image is mapped to the - radius limits, while the width is wrapped around between the - angle limits.
    - - Arguments: Rmax,Rmin CenterX,CenterY, start,end_angle
    - - All arguments are optional. With Rmin defaulting to zero, the - center to the center of the image, and the angles going from -180 (top) - to +180 (top). If Rmax is given the special value of - '0', the the distance from the center to the nearest edge - is used for the radius of the output image, which will ensure the whole - image is visible (though scaled smaller). However a special value of - '-1' will use the distance from the center to the furthest - corner, This may 'clip' the corners from the input rectangular image, - but will generate the exact reverse of a 'DePolar' with - the same arguments.
    - - If the plus form of distort (+distort) is used - output image center will default to 0,0 of the virtual - canvas, and the image size adjusted to ensure the whole input image is - made visible in the output image on the virtual canvas.
    DePolar - Uses the same arguments and meanings as a 'Polar' distortion - but generates the reverse Polar to Cartesian distortion.
    - - The special Rmax setting of '0' may however clip - the corners of the input image. However using the special - Rmax setting of '-1' (maximum center to corner - distance) will ensure the whole distorted image is preserved in the - generated result, so that the same argument to 'Polar' will - reverse the distortion re-producing the original. - - Note that as this distortion requires the area resampling of a circular - arc, which can not be handled by the builtin EWA resampling function. - As such the normal EWA filters are turned off. It is recommended some - form of 'super-sampling' image processing technique be used to produce - a high quality result.
    Barrel - Given the four coefficients (A,B,C,D) as defined by Helmut - Dersch, perform a barrel or pin-cushion distortion appropriate to - correct radial lens distortions. That is in photographs, make straight - lines straight again.
    - -

    Arguments: A B C [ D [ - X , Y ] ]
    - or Ax Bx Cx Dx - Ay By Cy Dy - [ X , Y ]

    - So that it forms the function -

    Rsrc = r * ( A*r3 + B*r2 + - C*r + D )

    - - Where X,Y is the optional center of the distortion - (defaulting to the center of the image).
    - The second form is typically used to distort images, rather than - correct lens distortions.
    -
    BarrelInverse - This is very similar to 'Barrel' with the same set of - arguments, and argument handling. However it uses the inverse - of the radial polynomial, - so that it forms the function -

    Rsrc = r / ( A*r3 + B*r2 + - C*r + D )

    - Note that this is not the reverse of the 'Barrel' - distortion, just a different barrel-like radial distortion method. - -
    Shepards - Distort the given list control points (any number) using an Inverse - Squared Distance Interpolation Method (Shepards - Method). The control points in effect do 'localized' displacement - of the image around the given control point (preserving the look and - the rotation of the area near the control points. For best results - extra control points should be added to 'lock' the positions of the - corners, edges and other unchanging parts of the image, to prevent - their movement.
    - - The distortion has been likened to 'taffy pulling' using nails, or - pins' stuck in a block of 'jelly' which is then moved to the new - position, distorting the surface of the jelly.
    - - Internally it is equivalent to generating a displacement map (see -displace) for source image color look-up using - the -sparse-color method of the same name. - -
    - -

    To print a complete list of distortion methods, use -list -distort.

    - -

    Many of the above distortion methods such as 'Affine', -'Perspective', and 'Shepards' use a list control points -defining how these points in the given image should be distorted in the -destination image. Each set of four floating point values represent a source -image coordinate, followed immediately by the destination image coordinate. -This produces a list of values such as...

    -

    - U1,V1 X1,Y1 - U2,V2 X2,Y2 - U3,V3 X3,Y3 - ... - Un,Vn Xn,Yn -

    -

    where U,V on the source image is mapped to X,Y on the -destination image.

    - -

    For example, to warp an image using 'perspective' distortion, -needs a list of at least 4 sets of coordinates, or 16 numbers. Here is the -perspective distortion of the built-in "rose:" image. Note how spaces were -used to group the 4 sets of coordinate pairs, to make it easier to read and -understand.

    - -
    -convert rose:  -virtual-pixel black \
    -  -distort Perspective '0,0,0,0  0,45,0,45  69,0,60,10  69,45,60,35' \
    -   rose_3d_rotated.gif"
    -
    - -

    If more that the required number of coordinate pairs are given for -a distortion, the distortion method is 'least squares' fitted to produce the -best result for all the coordinate pairs given. If less than the ideal number -of points are given, the distort will generally fall back to a simpler form of -distortion that can handles the smaller number of coordinates (usually a linear -'Affine' distortion).

    - -

    By using more coordinates you can make use of image registration tool to -find matching coordinate pairs in overlapping images, so as to improve the -'fit' of the distortion. Of course a bad coordinate pair can also make the -'fit' worse. Caution is always advised.

    - -

    Colors are acquired from the source image according to a cylindrical -resampling -filter, using a special technique known as -EWA resampling. This produces very high quality results, especially when -images become smaller (minified) in the output, which is very common when -using 'perspective' distortion. For example here we view -a infinitely tiled 'plane' all the way to the horizon.

    - -
    -convert -size 90x90 pattern:checkerboard -normalize -virtual-pixel tile \
    -  -distort perspective  '0,0,5,45  89,0,45,46  0,89,0,89  89,89,89,89' \
    -   checks_tiled.jpg
    -
    - -

    Note that a infinitely tiled perspective images involving the horizon can -be very slow, because of the number of pixels that are compressed to generate -each individual pixel close to the 'horizon'. You can turn off EWA -resampling, by specifying the special -filter setting of -'point' (recommended if you plan to use super-sampling instead). -

    - -

    If an image generates invalid pixels, such as the 'sky' in the last -example, -distort will use the current -mattecolor setting for these pixels. If you do not -what these pixels to be visible, set the color to match the rest of the -ground.

    - -

    The output image size will by default be the same as the input image. This -means that if the part of the distorted image falls outside the viewed area of -the 'distorted space', those parts is clipped and lost. However if you use -the plus form of the operator (+distort) the operator -will attempt (if possible) to show the whole of the distorted image, while -retaining a correct 'virtual canvas' offset, for image layering. This offset -may need to be removed using +repage, to remove if it -is unwanted.

    - -

    Setting -verbose setting, will cause -distort to attempt to output the internal coefficients, -and the -fx equivalent to the distortion, for expert study, -and debugging purposes. This many not be available for all distorts.

    - -

    You can alternatively specify a special "-define distort:viewport={geometry_string}" setting which will -specify the size and the offset of the generated 'viewport' image of the -distorted image space.

    - -

    Setting a "-define -distort:scale={scale_factor}" will scale the output image (viewport or -otherwise) by that factor without changing the viewed contents of the -distorted image. This can be used either for 'super-sampling' the image for -a higher quality result, or for panning and zooming around the image (with -appropriate viewport changes, or post-distort cropping and resizing).

    - -

    Setting "-define resample:verbose=1" -will output the cylindrical filter lookup table created by the EWA (Elliptical -Weighted Average) resampling algorithm. Note this table uses a squared radius -lookup value. This is typically only used for debugging EWA resampling.

    - - -
    -

    -distribute-cache port

    -
    - -

    launch a distributed pixel cache server.

    - -
    -

    -dither method

    -
    - -

    Apply a Riemersma or Floyd-Steinberg error diffusion dither to -images when general color reduction is applied via an option, or automagically -when saving to specific formats. This enabled by default.

    - -

    Dithering places two or more colors in neighboring pixels so that to the -eye a closer approximation of the images original color is reproduced. This -reduces the number of colors needed to reproduce the image but at the cost of -a lower level pattern of colors. Error diffusion dithers can use any set of -colors (generated or user defined) to an image.

    - -

    Dithering is turned on by default, to turn it off use the plus form of the -setting, +dither. This will also also render PostScript -without text or graphic aliasing. Disabling dithering often (but not always) -leads to faster process, a smaller number of colors, but more cartoon like -image coloring. Generally resulting in 'color banding' effects in areas with -color gradients.

    - -

    The color reduction operators -colors, -monochrome, -remap, and -posterize, apply dithering to images using the reduced -color set they created. These operators are also used as part of automatic -color reduction when saving images to formats with limited color support, such -as GIF:, XBM:, and others, so dithering may also be used -in these cases.

    - -

    Alternatively you can use -random-threshold -to generate purely random dither. Or use -ordered-dither to apply threshold mapped dither -patterns, using uniform color maps, rather than specific color maps.

    - - -
    -

    -draw string

    -
    - -

    Annotate an image with one or more graphic primitives.

    - -

    Use this option to annotate or decorate an image with one or more graphic -primitives. The primitives include shapes, text, transformations, and pixel -operations.

    - -

    The shape primitives:

    - -
    -
    point
    x,y
    -
    line
    x0,y0 x1,y1
    -
    rectangle
    x0,y0 x1,y1
    -
    roundRectangle
    x0,y0 x1,y1 wc,hc
    -
    arc
    x0,y0 x1,y1 a0,a1
    -
    ellipse
    x0,y0 rx,ry a0,a1
    -
    circle
    x0,y0 x1,y1
    -
    polyline
    x0,y0 ... xn,yn
    -
    polygon
    x0,y0 ... xn,yn
    -
    bezier
    x0,y0 ... xn,yn
    -
    path
    specification
    -
    image
    operator x0,y0 w,h filename
    -
    - -

    The text primitive:

    - -
    -
    text
    x0,y0 string
    -
    -

    The text gravity primitive:

    - -
    -
    gravity
    NorthWest, North, NorthEast, West, Center, East, SouthWest, South, or SouthEast
    -
    - -

    The text gravity primitive only affects the placement of text and does not -interact with the other primitives. It is equivalent to using the -gravity command-line option, except that it is limited in -scope to the -draw option in which it appears.

    - -

    The transformation primitives:

    - -
    -
    rotate
    degrees
    -
    translate
    dx,dy
    -
    scale
    sx,sy
    -
    skewX
    degrees
    -
    skewY
    degrees
    -
    - -

    The pixel operation primitives:

    - -
    -
    color
    x0,y0 method
    -
    matte
    x0,y0 method
    -
    - -

    The shape primitives are drawn in the color specified by the preceding -fill setting. For unfilled shapes, use -fill none. You can optionally control the stroke (the -"outline" of a shape) with the -stroke and -strokewidth settings.

    - -

    A point primitive is specified by a single point in the -pixel plane, that is, by an ordered pair of integer coordinates, -x,y. (As it involves only a single pixel, a point -primitive is not affected by -stroke or -strokewidth.)

    - -

    A line primitive requires a start point and end point.

    - -

    A rectangle primitive is specified by the pair of points at the -upper left and lower right corners.

    - -

    A roundRectangle primitive takes the same corner points as -a rectangle followed by the width and height of the rounded corners -to be removed.

    - -

    The circle primitive makes a disk (filled) or circle (unfilled). -Give the center and any point on the perimeter (boundary).

    - -

    The arc primitive is used to inscribe an elliptical segment in -to a given rectangle. An arc requires the two corners used for -rectangle (see above) followed by the start and end angles of the -arc of the segment segment (e.g. 130,30 200,100 45,90). The start and end -points produced are then joined with a line segment and the resulting segment -of an ellipse is filled.

    - -

    Use ellipse to draw a partial (or whole) ellipse. Give the -center point, the horizontal and vertical "radii" (the semi-axes of -the ellipse) and start and end angles in degrees (e.g. 100,100 100,150 -0,360).

    - -

    The polyline and polygon primitives require three or -more points to define their perimeters. A polyline is simply -a polygon in which the final point is not stroked to the start -point. When unfilled, this is a polygonal line. If the -stroke setting is none (the default), then -a polyline is identical to a polygon.

    - -

    A coordinate is a pair of integers separated by a space or -optional comma.

    - -

    As an example, to define a circle centered at 100,100 that extends to -150,150 use:

    - -
    --draw 'circle 100,100 150,150'
    -
    - -

    The Bezier primitive creates a spline curve and requires three -or points to define its shape. The first and last points are the -knots and these points are attained by the curve, while any -intermediate coordinates are control points. If two control points -are specified, the line between each end knot and its sequentially respective -control point determines the tangent direction of the curve at that end. If -one control point is specified, the lines from the end knots to the one -control point determines the tangent directions of the curve at each end. If -more than two control points are specified, then the additional control points -act in combination to determine the intermediate shape of the curve. In order -to draw complex curves, it is highly recommended either to use the -path primitive or to draw multiple four-point bezier segments with -the start and end knots of each successive segment repeated. For example:

    - -
    --draw 'bezier 20,50 45,100 45,0 70,50'
    --draw 'bezier 70,50 95,100 95,0 120,50'
    -
    - -

    A path represents an outline of an object, defined in terms of -moveto (set a new current point), lineto (draw a straight line), curveto (draw -a Bezier curve), arc (elliptical or circular arc) and closepath (close the -current shape by drawing a line to the last moveto) elements. Compound paths -(i.e., a path with subpaths, each consisting of a single moveto followed by -one or more line or curve operations) are possible to allow effects such as -donut holes in objects. (See Paths.)

    - -

    Use image to composite an image with another image. Follow the -image keyword with the composite operator, image location, image size, and -filename:

    - -
    --draw 'image SrcOver 100,100 225,225 image.jpg'
    -
    - -

    You can use 0,0 for the image size, which means to use the actual -dimensions found in the image header. Otherwise, it is scaled to the given -dimensions. See Alpha Compositing for -a detailed discussion of alpha composition methods that are available.

    - -

    The "special augmented compose operators" such as "dissolve" that require -arguments cannot be used at present with the -draw image option. -

    - -

    Use text to annotate an image with text. Follow the text -coordinates with a string. If the string has embedded spaces, enclose it in -single or double quotes.

    - -

    For example, the following annotates the image with Works like -magick! for an image titled bird.miff.

    - -
    --draw "text 100,100 'Works like magick!' "
    -
    - -

    See the -annotate option for another convenient way -to annotate an image with text.

    - -

    The rotate primitive rotates subsequent shape primitives and -text primitives about the origin of the main image. If the -region option precedes the -draw -option, the origin for transformations is the upper left corner of the -region.

    - -

    The translate primitive translates subsequent shape and text -primitives.

    - -

    The scale primitive scales them.

    - -

    The skewX and skewY primitives skew them with respect -to the origin of the main image or the region.

    - -

    The transformations modify the current affine matrix, which is initialized -from the initial affine matrix defined by the -affine -option. Transformations are cumulative within the -draw -option. The initial affine matrix is not affected; that matrix is only changed -by the appearance of another -affine option. If another --draw option appears, the current affine matrix is -reinitialized from the initial affine matrix.

    - -

    Use the color primitive to change the color of a pixel to the -fill color (see -fill). Follow the pixel coordinate with -a method:

    - -
    -point
    -replace
    -floodfill
    -filltoborder
    -reset
    -
    - -

    Consider the target pixel as that specified by your coordinate. The -point method recolors the target pixel. The replace -method recolors any pixel that matches the color of the target pixel. -Floodfill recolors any pixel that matches the color of the target -pixel and is a neighbor, whereas filltoborder recolors any neighbor -pixel that is not the border color. Finally, reset recolors all -pixels.

    - -

    Use matte to the change the pixel matte value to transparent. -Follow the pixel coordinate with a method (see the color primitive -for a description of methods). The point method changes the matte -value of the target pixel. The replace method changes the matte -value of any pixel that matches the color of the target pixel. -Floodfill changes the matte value of any pixel that matches the -color of the target pixel and is a neighbor, whereas filltoborder -changes the matte value of any neighbor pixel that is not the border color (-bordercolor). Finally reset changes the -matte value of all pixels.

    - -

    You can set the primitive color, font, and font bounding box color with -fill, -font, and -box -respectively. Options are processed in command line order so be sure to use -these options before the -draw option.

    - -

    Strings that begin with a number must be quoted (e.g. use '1.png' rather -than 1.png).

    - -

    Drawing primitives conform to the Magick -Vector Graphics format.

    - - -
    -

    -duplicate count,indexes

    -
    - -

    duplicate an image one or more times.

    - -

    Specify the count and the image to duplicate by its index in the sequence. -The first image is index 0. Negative indexes are relative to the end of the -sequence, for example, -1 represents the last image of the sequence. Specify -a range of images with a dash (e.g. 0-4). Separate indexes with a comma (e.g. -0,2). Use +duplicate to duplicate the last image in the current -image sequence.

    - -
    -

    -edge radius

    -
    - -

    detect edges within an image.

    - -
    -

    -emboss radius

    -
    - -

    emboss an image.

    - -
    -

    -encipher filename

    -
    - -

    Encipher pixels for later deciphering by -decipher.

    - -

    Get the passphrase from the file specified by filename.

    - -

    For more information, see the webpage, ImageMagick: Encipher or -Decipher an Image.

    - - - -
    -

    -encoding type

    -
    - -

    specify the text encoding.

    - -

    Choose from

    - -
    -AdobeCustom     AdobeExpert
    -AdobeStandard   AppleRoman
    -BIG5            GB2312
    -Latin 2         None
    -SJIScode        Symbol
    -Unicode         Wansung
    -
    - -
    -

    -endian type

    -
    - -

    Specify endianness (MSB or LSB) of the image.

    - -

    To print a complete list of endian types, use the -list endian option.

    - -

    Use +endian to revert to unspecified endianness.

    - - -
    -

    -enhance

    -
    - -

    Apply a digital filter to enhance a noisy image.

    - - -
    -

    -equalize

    -
    - -

    perform histogram equalization on the image channel-by-channel.

    - -

    To perform histogram equalization on all channels in concert, transform the -image into some other color space, such as HSL, OHTA, YIQ or YUV, then -equalize the appropriate intensity-like channel, then convert back to RGB.

    - -

    For example using HSL, we have: ... -colorspace HSL -channel lightness --equalize -colorspace RGB ...

    - -

    For YIQ, YUV and OHTA use the red channel. For example, OHTA is a principal -components transformation that puts most of the information in the first -channel. Here we have ... -colorspace OHTA -channel red -equalize --colorspace RGB ...

    - -
    -

    -evaluate operator value

    -
    - -

    Alter channel pixels by evaluating an arithmetic, relational, or logical expression.

    - -

    (See the -function operator for some -multi-parameter functions. See the -fx operator if more -elaborate calculations are needed.)

    - -

    The behaviors of each operator are summarized in the -following list. For brevity, the numerical value of a "pixel" referred to -below is the value of the corresponding channel of that pixel, while -a "normalized pixel" is that number divided by the maximum -(installation-dependent) value QuantumRange. (If -normalized pixels are used, they are restored, following the other -calculations, to the full range by multiplying by QuantumRange.)

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    operatorSummary (see further below for details)
    Abs Add value to pixels and return absolute value.
    Add Add value to pixels.
    AddModulus Add value to pixels modulo QuantumRange.
    And Binary AND of pixels with value.
    Cos, Cosine Apply cosine to pixels with frequency value with 50% bias added.
    Divide Divide pixels by value.
    Exp base-e exponential function
    Exponential base-e exponential function
    LeftShift Shift the pixel values left by value bits (i.e., multiply pixels by 2value).
    Log Apply scaled logarithm to normalized pixels.
    Max Set pixels to maximum of value and current pixel value (i.e. set any pixels currently less than value to value).
    Mean Add the value and divide by 2.
    Median Choose the median value from an image sequence.
    Min Set pixels to minimum of value and current pixel value (i.e. set any pixels currently greater than value to value).
    Multiply Multiply pixels by value.
    Or Binary OR of pixels with value.
    Pow Raise normalized pixels to the power value.
    RightShift Shift the pixel values right by value bits (i.e., divide pixels by 2value).
    RMS Square the pixel and add the value.
    RootMeanSquare Square the pixel and add the value.
    Set Set pixel equal to value.
    Sin, Sine Apply sine to pixels with frequency value with 50% bias added.
    Subtract Subtract value from pixels.
    Xor Binary XOR of pixels with value.
    Gaussian-noise
    Impulse-noise
    Laplacian-noise
    Multiplicative-noise (These are equivalent to the corresponding -noise operators.)
    PoissonNoise
    Uniform-noise
    Threshold Threshold pixels larger than value.
    ThresholdBlack Threshold pixels to zero values equal to or below value.
    ThresholdWhite Threshold pixels to maximum values above value.
    - -

    The specified functions are applied only to each previously set -channel in the image. If necessary, the results of the -calculations are truncated (clipped) to fit in the interval [0, QuantumRange]. The transparency channel of the image is -represented as a 'alpha' values (0 = fully transparent), so, for example, a -Divide by 2 of the alpha channel will make the image -semi-transparent. Append the percent symbol '%' to specify a value -as a percentage of the QuantumRange.

    - -

    To print a complete list of -evaluate operators, use --list evaluate.

    - -

    The results of the Add, Subtract and -Multiply methods can also be achieved using either the -level or the +level operator, with -appropriate argument, to linearly modify the overall range of color values. -Please note, however, that -level treats transparency as -'matte' values (0 = opaque), while -evaluate works with -'alpha' values.

    - -

    AddModulus has been added as of ImageMagick 6.4.8-4 and provides -addition modulo the QuantumRange. It is therefore -equivalent to Add unless the resulting pixel value is outside the -interval [0, QuantumRange].

    - -

    Exp or Exponential has been added as of ImageMagick 6.6.5-1 and -works on normalized pixel values. The value used with -Exp should be negative so as to produce a decaying exponential -function. Non-negative values will always produce results larger unity and -thus outside the interval [0, QuantumRange]. The -formula is expressed below.

    - -

    -exp(value × u) -

    - -

    If the input image is squared, for example, using -function polynomial "2 0 0", then a decaying Gaussian function will be -the result.

    - -

    Log has been added as of ImageMagick 6.4.2-1 and works on -normalized pixel values. This a scaled log function. The value used with Log provides a scaling -factor that adjusts the curvature in the graph of the log function. The -formula applied to a normalized value u is below.

    - -

    -log(value × u + 1) / log(value + 1) -

    - -

    Pow has been added as of ImageMagick 6.4.1-9, and works on -normalized pixel values. Note that Pow is related to the -gamma operator. For example, -gamma 2 is equivalent -to -evaluate pow 0.5, i.e., a 'square root' function. The value used -with -gamma is simply the reciprocal of the value used -with Pow.

    - -

    Cosine and Sine was added as of IM v6.4.8-8 and -converts the image values into a value according to a (co)sine wave function. -The synonyms Cos and Sin may also be used. The output -is biased 50% and normalized by 50% so as to fit in the respective color value -range. The value scaling of the period of the -function (its frequency), and thus determines the number of 'waves' that will -be generated over the input color range. For example, if the value is 1, the effective period is simply the QuantumRange; but if the value is 2, -then the effective period is the half the QuantumRange.

    - -

    -0.5 + 0.5 × cos(2 π u × value). -

    - -

    See also the -function operator, which is a -multi-value version of evaluate.

    - -
    -

    -evaluate-sequence operator

    -
    - -

    Alter channel pixels by evaluating an arithmetic, relational, or -logical expression over a sequence of images.

    - -

    To print a complete list of -evaluate-sequence operators, use -list evaluate.

    - -
    -

    -extent geometry

    -
    - -

    Set the image size and offset.

    - -

    If the image is enlarged, unfilled areas are set to the background color. -To position the image, use offsets in the geometry -specification or precede with a -gravity setting. To -specify how to compose the image with the background, use -compose.

    - -

    This command reduces or expands a JPEG image to fit on an 800x600 -display. If the aspect ratio of the input image isn't exactly 4:3, then the -image is centered on an 800x600 black canvas:

    - -
    -convert input.jpg -resize 800x600 -background black -compose Copy \ 
    -  -gravity center -extent 800x600 -quality 92 output.jpg
    -
    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -extract geometry

    -
    - -

    Extract the specified area from image.

    - -

    This option is most useful for extracting a subregion of a very large raw -image. Note that these two commands are equivalent:

    - -
    -convert -size 16000x16000 -depth 8 -extract 640x480+1280+960 \ 
    -  image.rgb image.png",
    -convert -size 16000x16000 -depth 8 'image.rgb[640x480+1280+960]' \
    -  image.rgb image.png"
    -
    - -

    If you omit the offsets, as in

    - -
    -convert -size 16000x16000 -depth 8 -extract 640x480 \ 
    -  image.rgb image.png
    -
    - -

    the image is resized to the specified dimensions instead, -equivalent to:

    - -
    -convert -size 16000x16000 -depth 8 -resize 640x480 image.rgb image.png
    -
    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -family fontFamily

    -
    - -

    Set a font family for text.

    - -

    This setting suggests a font family that ImageMagick should try to use for -rendering text. If the family can be found it is used; if not, a default font -(e.g., "Arial") or a family known to be similar is substituted (e.g., -"Courier" might be used if "System" is requested but not found).

    - -

    For other settings that affect fonts, see the options -font, -stretch, -style, and -weight.

    - -
    -

    -features distance

    -
    - -

    display (co-occurrence matrix) texture measure features for each channel in the image in each of four directions (horizontal, vertical, left and right diagonals) for the specified distance.

    - -
    -Angular Second Moment       Sum Entropy
    -Contrast                    Entropy
    -Correlation                 Difference Variance
    -Sum of Squares Variance     Difference Entropy
    -Inverse Difference Moment   Information Measure of Correlation 1
    -Sum Average                 Information Measure of Correlation 2
    -Sum Variance                Maximum Correlation Coefficient
    -
    - -
    -

    -fft

    -
    - -

    implements the forward discrete Fourier transform (DFT).

    - -

    This option is new as of ImageMagick 6.5.4-3 (and now working for Windows -users in ImageMagick 6.6.0-9). It transforms an image from the normal -(spatial) domain to the frequency domain. In the frequency domain, an image is -represented as a superposition of complex sinusoidal waves of varying -amplitudes. The image x and y coordinates are the possible frequencies along -the x and y directions, respectively, and the pixel intensity values are -complex numbers that correspond to the sinusoidal wave amplitudes. See for -example, Fourier -Transform, Discrete Fourier -Transform and Fast Fourier -Transform.

    - -

    A single image name is provided as output for this option. However, the -output result will have two components. It is either a two-frame image or two -separate images, depending upon whether the image format specified supports -multi-frame images. The reason that we get a dual output result is because the -frequency domain represents an image using complex numbers, which cannot be -visualized directly. Therefore, the complex values are automagically separated -into a two-component image representation. The first component is the -magnitude of the complex number and the second is the phase of the complex -number. See for example, Complex Numbers.

    - -

    The magnitude and phase component images must be specified using image -formats that do not limit the color or compress the image. Thus, MIFF, TIF, -PFM, EXR and PNG are the recommended image formats to use. All of these -formats, except PNG support multi-frame images. So for example,

    - -
    -convert image.png -fft fft_image.miff
    -
    - -

    generates a magnitude image as fft_image.miff[0] and a phase -image as fft_image.miff[1]. Similarly,

    - -
    -convert image.png -fft fft_image.png
    -
    - -

    generates a magnitude image as fft_image-0.png and a phase image -as fft_image-1.png. If you prefer this representation, then you can -force any of the other formats to produce two output images by including +adjoin following -fft in the command line.

    - -

    The input image can be any size, but if not square and even-dimensioned, it -is padded automagically to the larger of the width or height of the input -image and to an even number of pixels. The padding will occur at the bottom -and/or right sides of the input image. The resulting output magnitude and -phase images is square at this size. The kind of padding relies on the -virtual-pixel setting.

    - -

    Both output components will have dynamic ranges that fit within -[0, QuantumRange], so that HDRI need not be enabled. -Phase values nominally range from 0 to 2*π, but is scaled to span the full -dynamic range. (The first few releases had non-HDRI scaled but HDRI not -scaled). The magnitude image is not scaled and thus generally will contain -very small values. As such, the image normally will appear totally black. In -order to view any detail, the magnitude image typically is enhanced with a log -function into what is usually called the spectrum. A log function is used to -enhance the darker values more in comparison to the lighter values. This can -be done, for example, as follows:

    - -
    -convert fft_image.miff[0] -contrast-stretch 0 \
    -  -evaluate log 1000 fft_image_spectrum.png"
    -
    - -

    where either -contrast-stretch 0 or -auto-level is used to scale the image to full dynamic -range, first. The argument to the -evaluate log -typically is specified between 100 and 10,000, depending upon the amount of -detail that one wants to bring out in the spectrum. Larger values produce more -visible detail. Too much detail, however, may hide the important features.

    - -

    The FFTW delegate library is required to -use -fft.

    - -

    Use +fft to produce two output images that are the real -and imaginary components of the complex valued Fourier transform.

    - -

    However, as the real and imaginary components can contain negative values, -this requires that IM be configured with HDRI enabled. In this case, you must -use either MIFF, TIF, PFM or MPC formats for the real and imaginary component -results, since they are formats that preserve both negative and fractional -values without clipping them or truncating the fractional part. With either -MIFF or TIF, one should add -define quantum:format=32, to allow those image -types to work properly in HDRI mode without clipping.

    - -

    The real and imaginary component images resulting from +fft are also square, even dimensioned images due to the same -padding that was discussed above for the magnitude and phase component -images.

    - -

    See the discussion on HDRI implementations of ImageMagick on the page High Dynamic-Range Images. For more -about HDRI go the ImageMagick Usage pages, Fred's Fourier Processing With ImageMagick page or this Wikipedia - entry.

    - -

    By default the FFT is normalized (and the IFT is not). Use "-define fourier:normalize=forward to explicitly normalize the FFT and unnormalize the IFT.

    - - -
    -

    -fill color

    -
    - -

    color to use when filling a graphic primitive.

    - -

    This option accepts a color name, a hex color, or a numerical RGB, RGBA, -HSL, HSLA, CMYK, or CMYKA specification. See Color Names for -a description of how to properly specify the color argument.

    - -

    Enclose the color specification in quotation marks to prevent the "#" or -the parentheses from being interpreted by your shell.

    - -

    For example,

    - -
    --fill blue
    --fill "#ddddff"
    --fill "rgb(255,255,255)"
    -
    - -

    See -draw for further details.

    - -

    To print a complete list of color names, use the -list color option.

    - -
    -

    -filter type

    -
    - -

    Use this type of filter when resizing or distorting an image.

    - -

    Use this option to affect the resizing operation of an image during -operations such as -resize and -distort. For example you can use a simple resize filter such as:

    - -
    -Point       Hermite       Cubic
    -Box         Gaussian      Catrom
    -Triangle    Quadratic     Mitchell
    -
    - -

    The Bessel and Sinc filter is also provided (as well -as a faster SincFast equivalent form). However these filters are -generally useless on their own as they are infinite filters that are being -clipped to the filters support size. Their direct use is not recommended -except via expert settings (see below).

    - -

    Instead these special filter functions are typically windowed by a windowing -function that the -filter setting defines. That is -using these functions will define a 'Windowed' filter, appropriate to the -operator involved. Windowed filters include:

    - -
    -Lanczos       Hamming       Parzen
    -Blackman      Kaiser        Welsh
    -Hanning       Bartlett      Bohman
    -
    - -

    Also one special self-windowing filter is also provided -Lagrange, which will automagically re-adjust its function depending -on the current 'support' or 'lobes' expert settings (see below).

    - -

    If you do not select a filter with this option, the filter defaults to -Mitchell for a colormapped image, an image with a matte channel, or -if the image is enlarged. Otherwise the filter default to -Lanczos.

    - -

    To print a complete list of resize filters, use the -list -filter option.

    - -

    You can modify how the filter behaves as it scales your image through the -use of these expert settings (see also -define and -set):-

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    -define filter:blur=factorScale the X axis of the filter (and its window). Use > 1.0 for - blurry or < 1.0 for sharp. This should only be used with Gaussian and - Gaussian-like filters simple filters, or you may not get the expected - results.
    -define filter:support=radiusSet the filter support radius. Defines how large the filter should be and - thus directly defines how slow the filtered resampling process is. All - filters have a default 'preferred' support size. Some filters like - Lagrange and windowed filters adjust themselves depending on - this value. With simple filters this value either does nothing (but slow - the resampling), or will clip the filter function in a detrimental way. -
    -define filter:lobes=countSet the number of lobes to use for the Sinc/Bessel filter. This an - alternative way of specifying the 'support' range of the filter, that is - designed to be more suited to windowed filters, especially when used for - image distorts.
    -define filter:sigma=valueThe 'sigma' value used to define the Gaussian filter. Default - sigma value is '0.5'. It only effects Gaussian but - does not shrink (but may enlarge) the filter's 'support'. It can be used - to generate very small blurs but without the filter 'missing' pixels due - to using a small support setting. A larger value of '0.707' - (a value of '1/sqrt(2)') is another common setting.
    -define filter:b=b-spline_factor
    -define filter:c=keys_alpha_factorRedefine the values used for cubic filters such as Cubic, - Catrom, Mitchel, and Hermite, as well as - the Parzen cubic windowing function. If only one of the values - are defined, the other is set so as to generate a 'Cubic-Keys' filter. - The values meaning was defined by a research paper by - Mitchell-Netravali.
    -define filter:kaiser-beta=valueThe 'alpha' value used to as part of the Kaiser Windowing function. - Default value is '6.5'. It only effects Kaiser windowing function, and - does not effect any other attributes. - Before ImageMagick v6.7.6-10, this option was known as "filter:alpha", (an - inheritance from the very old "zoom" program). It was changed to bring the - function in line with more modern academic research usage, and better - assign it be more definitive.
    -define filter:kaiser-alpha=valueThis value when multiplied by 'PI' is equivalent to "kaiser-beta", and - will override that setting. It only effects Kaiser windowing function, - and does not effect any other attributes.
    -define filter:filter=filter_functionUse this function directly as the weighting filter. This will allow - you to directly use a windowing function such as Blackman, - as a resampling filter, rather than as its normal usage as a windowing - function. If defined, no windowing function also defined, the window function is set - to Box). Directly specifying Sinc or Jinc - as a filter will also do this.
    -define filter:window=filter_functionThe IIR (infinite impulse response) filters Sinc and - Jinc are windowed (brought down to zero over the defined - support range) with the given filter. This allows you to specify a filter - function to be used as a windowing function for these IIR filters. - Many of the defined filters are actually windowing functions for these IIR - filters. A typical choices is Box, (which effectively turns - off the windowing function).
    -define filter:win-support=radiusScale windowing function to this size instead. This causes the windowing - (or self-windowing Lagrange filter) to act is if the support window is - larger than what is actually supplied to the calling operator. The filter - however is still clipped to the real support size given. If unset this - will equal the normal filter support size.
    -define filter:verbose=1This causes IM to print information on the final internal filter - selection to standard output. This includes a commented header on the - filter settings being used, and data allowing the filter weights to be - easily graphed. Note however that some filters are internally defined in terms of other filters. The Lanczos filter for example is defined in terms of - a SincFast windowed SincFast filter, while - Mitchell is defined as a general Cubic family filter - with specific 'B' and 'C' settings.
    - -

    For example, to get a 8 lobe jinc windowed sinc filter (Genseng filter?):

    - -
    -convert image.png \
    -  -filter sinc \
    -  -set filter:window=jinc \
    -  -set filter:lobes=8 \
    -  -resize 150%   image.jpg"
    -
    - -

    Or a raw un-windowed Sinc filter with 4 lobes:

    - -
    -convert image.png \
    -  -set filter:filter=sinc \
    -  -set filter:lobes=4 \
    -  -resize 150%   image.jpg"
    -
    - -

    To extract the data for a raw windowing function, combine it with -a 'Box' filter. For example the 'Welch parabolic -windowing function.

    - -
    -convert null: -define filter:filter=Box \
    -  -define filter:window=Welch \
    -  -define filter:support=1.0 \
    -  -define filter:verbose=1 \
    -  -resize 2 null:  > window_welch.dat
    -gnuplot
    -  set grid
    -  plot \"window_welch.dat\" with lines
    -
    - -

    Note that the use of expert options is provided for image processing experts -who have studied and understand how resize filters work. Without this -knowledge, and an understanding of the definition of the actual filters -involved, using expert settings are more likely to be detrimental to your image -resizing.

    - - -
    -

    -flatten

    -
    - -

    This is a simple alias for the -layers method "flatten".

    - - -
    -

    -flip

    -
    - -

    create a mirror image

    - -

    reflect the scanlines in the vertical direction. The image will be mirrored -upside-down.

    - - -
    -

    -floodfill {+-}x{+-}y color

    -
    - -

    floodfill the image with color at the specified offset.

    - -

    Flood fill starts from the given 'seed point' which is not gravity effected. -Any color that matches within -fuzz color distance of the -given color argument, connected to that 'seed point' -will be replaced with the current -fill color.

    - -

    Note that if the pixel at the 'seed point' does not itself match the given -color (according to -fuzz), then no -action will be taken.

    - -

    This operator works more like the -opaque option, than -a more general flood fill that reads the matching color directly at the 'seed -point'. For this form of flood fill, look at -draw and -its 'color floodfill' drawing method.

    - - -
    -

    -flop

    -
    - -

    create a mirror image.

    - -

    Reflect the scanlines in the horizontal direction, just like the image in -a vertical mirror.

    - - -
    -

    -font name

    -
    - -

    set the font to use when annotating images with text, or creating labels.

    - -

    To print a complete list of fonts, use the -list font -option (for versions prior to 6.3.6, use 'type' instead of 'font').

    - -

    In addition to the fonts specified by the above pre-defined list, you can -also specify a font from a specific source. For example Arial.ttf -is a TrueType font file, ps:helvetica is PostScript font, and -x:fixed is X11 font.

    - -

    For other settings that affect fonts, see the options -family, -stretch, -style, and -weight.

    - - -
    -

    -foreground color

    -
    - -

    Define the foreground color for menus.", "display

    - -

    The color is specified using the format described under the -fill option.

    - -

    The default foreground color is black.

    - -
    -

    -format type

    -
    - -

    the image format type.

    - -

    When used with the mogrify utility, this option converts any -image to the image format you specify. -For a list of image format types supported by ImageMagick, use -list format.

    - -

    By default the file is written to its original name. However, if the -filename extension matches a supported format, the extension is replaced with -the image format type specified with -format. For -example, if you specify tiff as the format type and the -input image filename is image.gif, the output image -filename becomes image.tiff.

    - -
    -

    -format string

    -
    - -

    output formatted image characteristics.

    - -

    See Format and Print Image -Properties for an explanation on how to specify the argument to this -option.

    - -
    -

    -frame geometry

    -
    - -

    Surround the image with a border or beveled frame.

    - -

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

    - -

    See Image Geometry for complete details about the geometry argument. The size portion of the geometry argument indicates the amount of extra width and -height that is added to the dimensions of the image. If no offsets are given -in the geometry argument, then the border added is -a solid color. Offsets x and y, if present, specify that -the width and height of the border is partitioned to form an outer bevel of -thickness x pixels and an inner bevel of thickness -y pixels. Negative offsets make no sense as frame arguments. -

    - -

    The -frame option is affected by the current -compose setting and assumes that this is using the default -'Over' composition method. It generates an image of the appropriate -size with the current -bordercolor setting, and then -draws the frame of four distinct colors close to the current -mattecolor. The original image is then overlaid onto -center of this image. This means that with the default compose method of -'Over' any transparent parts may be replaced by the current -bordercolor setting.

    - -

    The image composition is not -affected by the -gravity option.

    - - -
    -

    -frame

    -
    - -

    include the X window frame in the imported image.

    -
    -

    -function function parameters

    -
    - -

    Apply a function to channel values.

    - -

    This operator performs calculations based on the given arguments to modify -each of the color values for each previously set -channel in the image. See -evaluate for details concerning how the results of the -calculations are handled.

    - -

    This is can be considered a multi-argument version of the -evaluate operator. (Added in -ImageMagick 6.4.8−8.)

    - -

    Here, parameters is a comma-separated list of -numerical values. The number of values varies depending on which function is selected. Choose the function from:

    - -
    -Polynomial
    -Sinusoid
    -Arcsin
    -Arctan
    -
    - -

    To print a complete list of -function operators, -use -list function. Descriptions follow.

    - -
    -
    Polynomial
    -

    The Polynomial function takes an arbitrary number of parameters, -these being the coefficients of a polynomial, in decreasing order of degree. -That is, entering

    - -
    --function Polynomial an,an-1,...a1,a0
    -
    - -

    will invoke a polynomial function given by

    - -
    -an un + an-1 un-1 + ··· a1 u + a0,
    -
    - -

    where u is pixel's original normalized channel value.

    - -

    The Polynomial function can be used in place of Set -(the constant polynomial) and Add, Divide, -Multiply, and Subtract (some linear -polynomials) of the -evaluate operator. The -level operator also affects channels linearly. Some -correspondences follow.

    - - - - - - - - - - - - - - - - - - - - - - - - -
    -evaluate Set value -function Polynomial value(Constant functions; set value×100% gray when channels are RGB.)
    -evaluate Add value -function Polynomial 1,value
    -evaluate Subtract value -function Polynomial 1,−value
    -evaluate Multiply value -function Polynomial value,0
    +level black% x white%-function Polynomial A,B(Reduce contrast. Here, A=(white-black)/100 and B=black/100.)
    - -

    The Polynomial function gives great versatility, since -polynomials can be used to fit any continuous curve to any degree of accuracy -desired.

    - -
    -
    Sinusoid
    -
    -

    The Sinusoid function can be used to vary the channel values -sinusoidally by setting frequency, phase shift, amplitude, and a bias. These -values are given as one to four parameters, as follows,

    - -
    --function Sinusoid freq,[phase,[amp,[bias]]]
    -
    - -

    where phase is in degrees. (The domain [0,1] of the function -corresponds to 0 through freq×360 degrees.) -The result is that if a pixel's normalized channel value is originally -u, its resulting normalized value is given by

    - -
    -amp * sin(2*π* (freq * u + phase / 360)) + bias
    -
    - -

    For example, the following generates a curve that starts and ends at 0.9 -(when u=0 and 1, resp.), oscillating three times between -.7−.2=.5 and .7+.2=.9.

    - -
    --function Sinusoid 3,-90,.2,.7
    -
    - -

    The default values of amp and bias are both .5. The default for phase -is 0.

    - -

    The Sinusoid function generalizes Sin and -Cos of the -evaluate operator by allowing -varying amplitude, phase and bias. The correspondence is as follows.

    - - - - - - - - - - -
    -evaluate Sin freq -function Sinusoid freq,0
    -evaluate Cos freq -function Sinusoid freq,90
    -
    -
    ArcSin
    -
    -

    The ArcSin function generates the inverse curve of a Sinusoid, -and can be used to generate cylindrical distortion and displacement maps. -The curve can be adjusted relative to both the input values and output range -of values.

    - -
    --function ArcSin width,[center,[range,[bias]]]
    -
    - -

    with all values given in terms of normalized color values (0.0 for black, -1.0 for white). Defaulting to values covering the full range from 0.0 to 1.0 -for bout input (width), and output (width) values. '1.0,0.5,1.0,0.5'

    - -
    -range/π * asin( 2/width * ( u - center ) ) + bias
    -
    - -
    -
    ArcTan
    -
    -

    The ArcTan function generates a curve that smooth crosses from -limit values at infinities, though a center using the given slope value. -All these values can be adjusted via the arguments.

    - -
    --function ArcTan slope,[center,[range,[bias]]]
    -
    - -

    Defaulting to '1.0,0.5,1.0,0.5'. -

    - -
    -range/π * atan( slope*π * ( u - center ) ) + bias
    -
    -
    - -
    - - - -
    -

    -fuzz distance{%}

    -
    - -

    Colors within this distance are considered equal.

    - -

    A number of algorithms search for a target color. By default the color must -be exact. Use this option to match colors that are close to the target color -in RGB space. For example, if you want to automagically trim the edges of an -image with -trim but the image was scanned and the target -background color may differ by a small amount. This option can account for -these differences.

    - -

    The distance can be in absolute intensity units or, by -appending % as a percentage of the maximum possible intensity (255, -65535, or 4294967295).

    - -

    Use +fuzz to reset the fuzz value to 0.

    - - -
    -

    -fx expression

    -
    - -

    apply a mathematical expression to an image or image channels.

    - -

    If the first character of expression is @, -the expression is read from a file titled by the remaining characters in the -string.

    - -

    See FX, -The Special Effects Image Operator for a detailed discussion of this -option.

    - - -
    -

    -gamma value

    -
    - -

    level of gamma correction.

    - -

    The same color image displayed on two different workstations may look -different due to differences in the display monitor. Use gamma correction to -adjust for this color difference. Reasonable values extend from -0.8 to 2.3. Gamma less than 1.0 darkens the image and -gamma greater than 1.0 lightens it. Large adjustments to image gamma may -result in the loss of some image information if the pixel quantum size is only -eight bits (quantum range 0 to 255).

    - -

    Gamma adjusts the image's channel values pixel-by-pixel according to -a power law, namely, pow(pixel,1/gamma) or pixel^(1/gamma), where pixel is the -normalized or 0 to 1 color value. For example, using a value of gamma=2 is the -same as taking the square root of the image.

    - -

    You can apply separate gamma values to the red, green, and blue channels of -the image with a gamma value list delimited with commas (e.g., -1.7,2.3,1.2).

    - -

    Use +gamma value to set the -image gamma level without actually adjusting the image pixels. This option -is useful if the image is of a known gamma but not set as an image attribute -(e.g. PNG images). Write the "file gamma" which is the reciprocal of the -display gamma; e.g., if your image is sRGB and you want to write a PNG gAMA -chunk, use

    - -
    -convert input.png +gamma .45455 output.png
    -
    - -

    (0.45455 is 1/2.2)

    - -

    Note that gamma adjustments are also available via the -level operator.

    - -
    -

    -gaussian-blur radius
    -gaussian-blur radiusxsigma

    -
    - -

    Blur the image with a Gaussian operator.

    - -

    Convolve the image with a Gaussian or normal distribution using the given -Sigma value. The formula is:

    - -

    gaussian distribution

    - -

    The Sigma value is the important argument, and -determines the actual amount of blurring that will take place.

    - -

    The Radius is only used to determine the size of the -array which will hold the calculated Gaussian distribution. It should be an -integer. If not given, or set to zero, IM will calculate the largest possible -radius that will provide meaningful results for the Gaussian distribution. -

    - -

    The larger the Radius the radius the slower the -operation is. However too small a Radius, and sever -aliasing effects may result. As a guideline, Radius -should be at least twice the Sigma value, though three -times will produce a more accurate result.

    - -

    This differs from the faster -blur operator in that a -full 2-dimensional convolution is used to generate the weighted average of the -neighboring pixels.

    - -

    The -virtual-pixel setting will determine how -pixels which are outside the image proper are blurred into the final result. -

    - - -
    -

    -geometry geometry

    -
    - -

    Set the preferred size and location of the image.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -gravity type

    -
    - -

    Sets the current gravity suggestion for various other settings and options.

    - -

    Choices include: NorthWest, North, -NorthEast, West, Center, East, -SouthWest, South, SouthEast. Use -list gravity to get a complete list of -gravity settings available in your ImageMagick -installation.

    - -

    The direction you choose specifies where to position text or subimages. For -example, a gravity of Center forces the text to be centered within -the image. By default, the image gravity is NorthWest. See -draw for more details about graphic primitives. Only the -text primitive of -draw is affected by the -gravity option.

    - -

    The -gravity option is also used in concert with the --geometry setting and other settings or options that -take geometry as an argument, such as the -crop option.

    - -

    If a -gravity setting occurs before another option -or setting having a geometry argument that specifies an -offset, the offset is usually applied to the point within the image suggested -by the -gravity argument. Thus, in the following -command, for example, suppose the file image.png has dimensions -200x100. The offset specified by the argument to -region -is (−40,+20). The argument to -gravity is -Center, which suggests the midpoint of the image, at the point -(100,50). The offset (−40,20) is applied to that point, giving -(100−40,50+20)=(60,70), so the specified 10x10 region is located at -that point. (In addition, the -gravity affects the -region itself, which is centered at the pixel -coordinate (60,70). (See Image Geometry for complete details about the geometry argument.)

    - -
    -convert image.png -gravity Center -region 10x10-40+20 \ 
    -  -negate output.png
    -
    - -

    When used as an option to composite, -gravity gives the direction that the image gravitates -within the composite.

    - -

    When used as an option to montage, -gravity gives the direction that an image gravitates -within a tile. The default gravity is Center for this purpose.

    - - -
    -

    -grayscale method

    -
    - -

    convert image to grayscale.

    - -

    This will use one of the -intensity methods to -convert the given image into a linear-grayscale image.

    - -

    For example, to convert an image to (linear) Rec709Luminance grayscale, type:

    - -
    -convert in.png -grayscale Rec709Luminance out.png
    -
    - -

    which is equivalent to:

    - -
    -convert in.png -colorspace gray out.png
    -
    - -

    Similarly, to convert an image to (non-linear) Rec709Luma grayscale, type:

    - -
    -convert in.png -grayscale Rec709Luma out.png
    -
    - -

    which is equivalent to:

    - -
    -convert in.png -set colorspace RGB -colorspace gray out.png
    -
    - -

    Note that a 'colorspace' intensity method will produce the same result -regardless of the current colorpsace of the image. But a 'mathematical' -intensity method will depend on the current colorspace the image is currently -using.

    - -

    While this operation uses an -intensity method, -it does not use or set the -intensity setting, so -will not effect other operations that may use that setting.

    - - -
    -

    -green-primary x,y

    -
    - -

    green chromaticity primary point.

    - - -
    -

    -hald-clut

    -
    - -

    apply a Hald color lookup table to the image.

    - -

    A Hald color lookup table is a 3-dimensional color cube mapped to 2 -dimensions. Create it with the HALD: prefix (e.g. HALD:8). You -can apply any color transformation to the Hald image and then use this option -to apply the transform to the image.

    - -
    -convert image.png hald.png -hald-clut transform.png
    -
    - -

    This option provides a convenient method for you to use Gimp or Photoshop -to make color corrections to the Hald CLUT image and subsequently apply them -to multiple images using an ImageMagick script.

    - -

    Note that the representation is only of the normal RGB color space and that -the whole color value triplet is used for the interpolated lookup of the -represented Hald color cube image. Because of this the operation is not -channel setting effected, nor can it adjust or modify an -images transparency or alpha/matte channel.

    - -

    See also -clut which provides color value replacement -of the individual color channels, usually involving a simpler gray-scale -image. E.g: gray-scale to color replacement, or modification by a histogram -mapping.

    - - -
    -

    -help

    -
    - -

    print usage instructions.

    - -
    -

    -highlight-color color

    -
    - -

    when comparing images, emphasize pixel differences with this color.

    - -
    -

    -hough-lines widthxheight{+threshold}

    -
    - -

    identify straight lines in the image (e.g. -hough-lines 9x9+195).

    - -

    Use the Hough line detector with any binary edge extracted image to locate and draw any straight lines that it finds.

    - -

    The process accumulates counts for every white pixel in the binary edge image for every possible orientation (for angles from 0 to 179 in 1 deg increments) and distance from the center of the image to the corners (in 1 px increments). It stores the counts in an accumulator matrix of angle vs distance. The size of the accumulator will be 180x(diagonal/2). Next it searches the accumulator for peaks in counts and converts the locations of the peaks to slope and intercept in the normal x,y input image space. The algorithm uses slope/intercepts to find the endpoints clipped to the bounds of the image. The lines are drawn from the given endpoints. The counts are a measure of the length of the lines.

    . - -

    The WxH arguments specify the filter size for locating the peaks in the Hough accumulator. The threshold excludes lines whose counts are less than the threshold value.

    - -

    Use -background to specify the color of the background onto which the lines will be drawn. The default is black.

    - -

    Use -fill to specify the color of the lines. The default is black.

    - -

    Use -stroke and -strokewidth to specify the thickness of the lines. The default is black and no strokewidth.

    - -

    A text file listing the endpoints and counts may be created by using the suffix, .mvg, for the output image.

    - -

    Use -define hough-lines:accumulator=true to return the accumulator image in addition to the lines image.

    - -
    -

    -iconGeometry geometry

    -
    - -

    specify the icon geometry.

    - -

    Offsets, if present in the geometry specification, are handled in the same -manner as the -geometry option, using X11 style to -handle negative offsets.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -iconic

    -
    - -

    start in icon mode in X Windows", 'animate', 'display

    - -
    -

    -identify

    -
    - -

    identify the format and characteristics of the image.

    - -

    This information is printed: image scene number; image name; image size; -the image class (DirectClass or PseudoClass); the total number of unique colors; and the -number of seconds to read and transform the image. Refer to MIFF for -a description of the image class.

    - -

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

    - -

    If -verbose precedes this option, copious -amounts of image properties are displayed including image statistics, profiles, -image histogram, and others.

    - -
    -

    -ift

    -
    - -

    implements the inverse discrete Fourier transform (DFT).

    - -

    This option is new as of ImageMagick 6.5.4-3 (and now working for Windows -users in ImageMagick 6.6.0-9). It transforms a pair of magnitude and phase -images from the frequency domain to a single image in the normal or spatial -domain. See for example, Fourier Transform, -Discrete Fourier Transform and -Fast Fourier Transform.

    - -

    For example, depending upon the image format used to store the result of -the -fft, one would use either

    - -
    -convert fft_image.miff -ift fft_image_ift.png
    -
    - -

    or

    - -
    -convert fft_image-0.png fft_image-1.png -ift fft_image_ift.png
    -
    - -

    The resulting image may need to be cropped due to padding introduced when -the original image, prior to the -fft or +fft, was not square or even dimensioned. Any padding is at -the right and/or bottom sides of the image.

    - -

    The FFTW delegate library is required to -use -ift.

    - -

    Use +ift (with HDRI enabled) to transform a pair of real -and imaginary images from the frequency domain to a single image in the normal -(spatial) domain.

    - -

    By default the IFT is not normalized (and the FFT is). Use "-define fourier:normalize=inverse to explicitly normalize the IFT and unnormalize the FFT.

    - -
    -

    -immutable

    -
    - -

    make image immutable.

    - -
    -

    -implode factor

    -
    - -

    implode image pixels about the center.

    - -
    -

    -insert index

    -
    - -

    insert the last image into the image sequence.

    - -

    This option takes last image in the current image sequence and inserts it -at the given index. If a negative index is used, the insert position is -calculated before the last image is removed from the sequence. As such --insert -1 will result in no change to the image sequence.

    - -

    The +insert option is equivalent to -insert -1. In -other words, insert the last image, at the end of the current image sequence. -Consequently this has no effect on the image sequence order.

    - -
    -

    -intensity method

    -
    - -

    method to generate intensity value from pixel.

    - -

    ImageMagick provides a number of methods used in situations where an -operator needs to determine a single grayscale value for some purpose, from -an image with red, green, and blue pixel components. Typically the linear -Rec709Luminance formula is used, which is the same formula used when -converting images to -colorspace gray.

    - -

    The following formulas are currently provided, and will first convert -the pixel values to linear-RGB or non-linear sRGB colorspace before -being applied to calculate the final greyscale value.

    - -
    -
    Rec601Luma
    0.298839R' + 0.586811G'+ 0.114350B'
    -
    Rec601Luminance
    0.298839R + 0.586811G + 0.114350B
    -
    Rec709Luma
    0.212656R' + 0.715158G' + 0.072186B'
    -
    Rec709Luminance
    0.212656R + 0.715158G + 0.072186B
    -
    Brightness
    max(R', G', B')
    -
    Lightness
    (min(R', G', B') + max(R', G', B')) / 2.0
    -
    - -

    Note that the above R,G,B values is the image's linear-RGB values, while -R',G',B' are sRGB non-linear values.

    - -

    These intensity methods are mathematical in nature and will use the -current value in the images respective R,G,B channel regardless of -what that is, or what colorspace the image is currently using.

    - -
    -
    Average
    (R + G + B) / 3.0
    -
    MS
    (R^2 + G^2 + B^2) / 3.0
    -
    RMS
    sqrt( (R^2 + G^2 + B^2) / 3.0 )
    -
    - -

    These methods are often used for other purposes, such as generating a -grayscale difference image between two color images (using -compose 'Difference' composition.

    - -

    For example The 'MS' (Mean Squared) setting is good for minimizing color -error comparisions. While... The method 'RMS' (Root Mean Squared) for -example is appropriate for calculating color vector distance, from a color -difference image. This is equivalent to the color only component of the -fuzz factor color compare setting.

    - -

    See also -grayscale which applies one of the above -grayscaling formula directly to an image without setting the -intensity setting.

    - -

    The -colorspace gray image conversion also uses -the current intensity setting, but will always convert the image to the -appropriate sRGB or linear-RGB colorspace before appling the above -function.

    - -

    To print a complete list of possible pixel intensity setting methods, use -list intensity.

    - -

    Operators affected by the -intensity setting include:

    - -
    --adaptive-blur
    --adaptive-sharpen
    --black-threshold
    --clut (when mapping greyscale CLUT image to alpha channel if set by -channels)
    --colors for gray colorspace
    --compose {LightenIntensity, DarkenIntensity, CopyOpacity, CopyBlack}
    --contrast-stretch
    --distort {ErodeIntensity, DilateIntensity}
    --normalize
    --random-threshold
    --selective-blur
    --shade
    --threshold
    --tint
    --white-threshold
    -
    - -
    -

    -intent type

    -
    - -

    use this type of rendering intent when managing the image color.

    - -

    Use this option to affect the color management operation of an image (see --profile). Choose from these intents: Absolute, -Perceptual, Relative, Saturation.

    - -

    The default intent is Perceptual for the sRGB colorspace and undefined for the RGB and gray colorspaces.

    - -

    To print a complete list of rendering intents, use -list intent.

    - -
    -

    -interlace type

    -
    - -

    the type of interlacing scheme.

    - -

    Choose from:

    - -
    -none
    -line
    -plane
    -partition
    -JPEG
    -GIF
    -PNG
    -
    - -

    This option is used to specify the type of interlacing scheme for raw image -formats such as RGB or YUV.

    - -

    None means do not interlace (RGBRGBRGBRGBRGBRGB...),

    - -

    Line uses scanline interlacing (RRR...GGG...BBB...RRR...GGG...BBB...), and.

    - -

    Plane uses plane interlacing (RRRRRR...GGGGGG...BBBBBB...).

    - -

    Partition is like plane except the different planes are saved to -individual files (e.g. image.R, image.G, and image.B).

    - -

    Use Line or Plane to create an interlaced -PNG or GIF or progressive JPEG image.

    - -

    To print a complete list of interlacing schemes, use -list -interlace.

    - -
    -

    -interpolate type

    -
    - -

    Set the pixel color interpolation method to use when looking up a color based on a floating point or real value.

    - -

    When looking up the color of a pixel using a non-integer floating point -value, you typically fall in between the pixel colors defined by the source -image. This setting determines how the color is determined from the colors of -the pixels surrounding that point. That is how to determine the color of a -point that falls between two, or even four different colored pixels.

    - -
    -
    integer
    -
    The color of the top-left pixel (floor function)
    -
    nearest-neighbor
    -
    The nearest pixel to the lookup point (rounded function)
    -
    average
    -
    The average color of the surrounding four pixels
    -
    bilinear
    -
    A double linear interpolation of pixels (the default)
    -
    mesh
    -
    Divide area into two flat triangular interpolations
    -
    bicubic
    -
    Fitted bicubic-spines of surrounding 16 pixels
    -
    spline
    -
    Direct spline curves (colors are blurred)
    -
    filter
    -
    Use resize -filter settings
    -
    - -

    This most important for distortion operators such as -distort, -implode, -transform and -fx.

    - -

    To print a complete list of interpolation methods, use -list interpolate.

    - -

    See also -virtual-pixel, for control of the -lookup for positions outside the boundaries of the image.

    - - -
    -

    -interline-spacing value

    -
    - -

    the space between two text lines.

    - -
    -

    -interword-spacing value

    -
    - -

    the space between two words.

    - -
    -

    -kerning value

    -
    - -

    the space between two letters.

    - -
    -

    -kuwahara radius
    -kuwahara radiusxsigma

    -
    - -

    edge preserving noise reduction filter.

    - -

    The radius is more important than the sigma. If sigma is left off, it will be computed automatically from the radius as sigma=radius-0.5. The sigma provides a bit of additional smoothing control.

    - - -
    -

    -label name

    -
    - -

    assign a label to an image.

    - -

    Use this option to assign a specific label to the image, as it is read in -or created. You can use the -set operation to re-assign -a the labels of images already read in. Image formats such as TIFF, PNG, -MIFF, supports saving the label information with the image.

    - -

    When saving an image to a PostScript file, any label -assigned to an image is used as a header string to print above the postscript -image.

    - -

    You can include the image filename, type, width, height, or other image -attribute by embedding special format character. See Format and Print Image -Properties for details of the percent escape codes.

    - -

    For example,

    - -
    --label "%m:%f %wx%h"  bird.miff
    -
    - -

    assigns an image label of MIFF:bird.miff 512x480 to the -"bird.miff" image and whose width is 512 and height is 480, as it -is read in. If a +label option was used instead, any -existing label present in the image would be used. You can remove all labels -from an image by assigning the empty string.

    - -

    A label is not drawn on the image, but is embedded in the image datastream -via Label tag or similar mechanism. If you want the label to be -visible on the image itself, use the -draw option, or -during the final processing in the creation of an image montage.

    - -

    If the first character of string is @, the image label is read from a file titled by the -remaining characters in the string. Labels in a file are literal, no embedded -formatting characters are recognized.

    - - -
    -

    -lat width
    -lat widthxheight{+-}offset{%}

    -
    - -

    perform local adaptive threshold.

    - -

    Adaptively threshold each pixel based on the value of pixels in a -surrounding window. If the current pixel is lighter than this average plus -the optional offset, then it is made white, otherwise it is made -black. Small variations in pixel values such as found in scanned documents -can be ignored if offset is positive. A negative offset will make it more -sensitive to those small variations.

    - -

    This is commonly used to threshold images with an uneven background. It is -based on the assumption that average color of the small window is the -the local background color, from which to separate the foreground color.

    - - -
    -

    -layers method

    -
    - -

    handle multiple images forming a set of image layers or animation frames.

    - -

    Perform various image operation methods to a ordered sequence of images -which may represent either a set of overlaid 'image layers', a GIF disposal -animation, or a fully-'coalesced' animation sequence.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    compare-anyCrop the second and later frames to the smallest rectangle - that contains all the differences between the two images. No GIF -dispose methods are taken into account.
    This exactly the same as the -deconstruct operator, and does not preserve animations normal - working, especially when animation used layer disposal methods such as - 'Previous' or 'Background'.
    compare-clearAs 'compare-any' but crop to the bounds of any - opaque pixels which become transparent in the second frame. That is the - smallest image needed to mask or erase pixels for the next frame.
    compare-overlayAs 'compare-any' but crop to pixels that add - extra color to the next image, as a result of overlaying color pixels. - That is the smallest single overlaid image to add or change colors.
    This can be used with the -compose alpha - composition method 'change-mask', to reduce the image to - just the pixels that need to be overlaid.
    coalesceEquivalent to a call to the -coalesce operator. Apply the layer disposal methods set in the - current image sequence to form a fully defined animation sequence, as - it should be displayed. Effectively converting a GIF animation into a - 'film strip'-like animation.
    compositeAlpha Composition of two image lists, separated by a - "null:" image, with the destination image list first, and - the source images last. An image from each list are composited - together until one list is finished. The separator image and source - image lists are removed.
    The -geometry offset is adjusted according - to -gravity in accordance of the virtual - canvas size of the first image in each list. Unlike a normal -composite operation, the canvas offset is also - added to the final composite positioning of each image.
    If one of the image lists only contains one image, that image is - applied to all the images in the other image list, regardless of which - list it is. In this case it is the image meta-data of the list which - preserved.
    disposeThis like 'coalesce' but shows the look of - the animation after the layer disposal method has been applied, before - the next sub-frame image is overlaid. That is the 'dispose' image that - results from the application of the GIF -dispose method. This allows you to check what - is going wrong with a particular animation you may be developing. -
    flattenCreate a canvas the size of the first images virtual - canvas using the current -background color, - and -compose each image in turn onto that - canvas. Images falling outside that canvas is clipped. Final - image will have a zero virtual canvas offset.
    This usually used as one of the final 'image layering' operations - overlaying all the prepared image layers into a final image.
    For a single image this method can also be used to fillout a virtual - canvas with real pixels, or to underlay an opaque color to remove - transparency from an image.
    mergeAs 'flatten' method but merging all the given image - layers to create a new layer image just large enough to hold all the - image without clipping or extra space. The new images virtual offset - will preserve the position of the new layer, even if this offset is - negative. The virtual canvas size of the first image is preserved. -
    Caution is advised when handling image layers with - negative offsets as few image file formats handle them correctly. - Following this operation method with +repage - will remove the layer offset, and create an image in which all the - overlaid image positions relative to each other is preserved, though - not necessarily exactly where you specified them. -
    See also 'trim-bounds' below which is closely related but - without doing the'flatten' to merge the images together.
    mosaicAs 'flatten' method but expanding the initial canvas size - of the first image in a positive direction only so as to hold all the - image layers. However as a virtual canvas is 'locked' to the origin, - by its own definition, image layers with a negative offsets will still - become clipped by the top and left edges. See 'merge' or 'trim-bounds' - if this could be a problem.
    This method is commonly used to layout individual image - using various offset but without knowing the final canvas size. The - resulting image will, like 'flatten' not have any virtual offset, so - can be saved to any image file format.
    optimizeOptimize a coalesced animation, into GIF animation using - a number of general techniques. This currently a short cut to - apply both the 'optimize-frame', and - 'optimize-transparency' methods but may be expanded to - include other optimization methods as they are developed.
    optimize-frameOptimize a coalesced animation, into GIF animation by - reducing the number of pixels per frame as much as possible by - attempting to pick the best layer disposal method to use, while ensuring - the result will continue to animate properly.
    There is no guarantee that the best optimization is found. - But then no reasonably fast GIF optimization algorithm can do this. - However this does seem to do better than most other GIF frame - optimizers seen.
    optimize-plusAs 'optimize-frame' but attempt to improve the - overall optimization by adding extra frames to the animation, without - changing the final look or timing of the animation. The frames are - added to attempt to separate the clearing of pixels from the - overlaying of new additional pixels from one animation frame to the - next. If this does not improve the optimization (for the next frame - only), it will fall back to the results of the previous normal - 'optimize-frame' technique.
    There is the possibility that the change in the disposal - style will result in a worsening in the optimization of later frames, - though this is unlikely. In other words there no guarantee that it is - better than the normal 'optimize-frame' technique. For some - animations however you can get a vast improvement in the final - animation size.
    optimize-transparencyGiven a GIF animation, replace any pixel in the sub-frame - overlay images with transparency, if it does not change the resulting - animation by more than the current -fuzz factor. -
    This should allow a existing frame optimized GIF animation - to compress into a smaller file size due to larger areas of one - (transparent) color rather than a pattern of multiple colors repeating - the current disposed image of the last frame.
    remove-dupsRemove (and merge time delays) of duplicate consecutive - images, so as to simplify layer overlays of coalesced animations. -
    Usually this a result of using a constant time delay - across the whole animation, or after a larger animation was split into - smaller sub-animations. The duplicate frames could also have been - used as part of some frame optimization methods.
    remove-zeroRemove any image with a zero time delay, unless ALL the - images have a zero time delay (and is not a proper timed animation, a - warning is then issued).
    In a GIF animation, such images are usually frames which - provide partial intermediary updates between the frames that are - actually displayed to users. These frames are usually added for - improved frame optimization in GIF animations.
    trim-boundsFind the bounds of all the images in the current - image sequence, then adjust the offsets so all images are contained on - a minimal positive canvas. None of the image data is modified or - merged, only the individual image virtual canvas size and offset. - All the images is given the same canvas size, and and will have - a positive offset, but will remain in the same position relative to - each other. As a result of the minimal canvas size at least one image - will touch every edge of that canvas. The image data touching those - edges however may be transparent.
    The result is much like if you used 'merge' followed by a - +repage option, except that all the images - have been kept separate. If 'flatten' is used after using - 'trim-bounds' you will get the same result.
    - -

    To print a complete list of layer types, use -list layers.

    - -

    The operators -coalesce, -deconstruct, -flatten, and -mosaic are only aliases for the above methods and may be depreciated in -the future. Also see -page, -repage operators, the -compose setting, and the -GIF -dispose and -delay -settings.

    - - -
    -

    -level black_point{,white_point}{%}{,gamma}

    -
    - -

    adjust the level of image channels.

    - -

    Given one, two or three values delimited with commas: black-point, -white-point, gamma (for example: 10,250,1.0 or 2%,98%,0.5). The black and -white points range from 0 to QuantumRange, or from 0 to -100%; if the white point is omitted it is set to (QuantumRange - black_point), so as to center contrast changes. -If a % sign is present anywhere in the string, both black and white -points are percentages of the full color range. Gamma will do a -gamma adjustment of the values. If it is omitted, the -default of 1.0 (no gamma correction) is assumed.

    - -

    In normal usage (-level) the image values are stretched so that -the given 'black_point' value in the original image is set to zero -(or black), while the given 'white_point' value is set to QuantumRange (or white). This provides you with direct -contrast adjustments to the image. The 'gamma' of the resulting -image will then be adjusted.

    - -

    From ImageMagick v6.4.1-9 using the plus form of the operator -(+level) or adding the special '!' flag anywhere in the argument -list, will cause the operator to do the reverse of the level adjustment. That -is a zero, or QuantumRange value (black, and white, resp.) -in the original image, is adjusted to the given level values, allowing you to -de-contrast, or compress the channel values within the image. The -'gamma' is adjusted before the level adjustment to de-contrast the -image is made.

    - -

    Only the channels defined by the current -channel -setting are adjusted (defaults to RGB color channels only), allowing you to -limit the effect of this operator.

    - -

    Please note that the transparency channel is treated as 'matte' -values (0 is opaque) and not as 'alpha' values (0 is transparent).

    - - -
    -

    -level-colors {black_color}{,}{white_color}

    -
    - -

    adjust the level of an image using the provided dash separated colors.

    - -

    This function is exactly like -level, except that the -value value for each color channel is determined by the -'black_color' and 'white_color' colors given (as -described under the -fill option).

    - -

    This effectually means the colors provided to -level-colors -is mapped to become 'black' and 'white' respectively, with all the other -colors linearly adjusted (or clipped) to match that change. Each channel is -adjusted separately using the channel values of the colors specified.

    - -

    On the other hand the plus form of the operator (+level-colors) -will map the image color 'black' and 'white' to the given colors -respectively, resulting in a gradient (de-contrasting) tint of the image to -those colors. This can also be used to convert a plain gray-scale image into a -one using the gradient of colors specified.

    - -

    By supplying a single color with a comma separator either before or after -that color, will just replace the respective 'black' or 'white' point -respectively. But if no comma separator is provided, the given color is -used for both the black and white color points, making the operator either -threshold the images around that color (- form) or set all colors to that -color (+ form).

    - - -
    -

    -limit type value

    -
    - -

    Set the pixel cache resource limit.

    - -

    Choose from: area, disk, file, -map, memory, thread, or time.

    - -

    The value for file is in number of files. The other limits are -in bytes. Define arguments for the memory, map, area, and disk resource limits -with SI prefixes (.e.g 100MB).

    - -

    By default the limits are 768 files, 3GB of image area, 1.5GiB memory, 3GiB -memory map, and 18.45EB of disk. These limits are adjusted relative to the -available resources on your computer if this information is available. When -any limit is reached, ImageMagick fails in some fashion but attempts to take -compensating actions, if possible. For example, the following limits -memory:

    - -
    --limit memory 32MiB -limit map 64MiB
    -
    - -

    Use -list resource to list the current limits. For example, our system shows these limits:

    - -
    --> identify -list resource
    -Resource limits:
    -  Width: 100MP
    -  Height: 100MP
    -  Area: 25.181GB
    -  Memory: 11.726GiB
    -  Map: 23.452GiB
    -  Disk: unlimited
    -  File: 768
    -  Thread: 12
    -  Throttle: 0
    -  Time: unlimited
    -
    - -

    Requests for pixel storage to keep intermediate images are satisfied by one -of three resource categories: in-memory pool, memory-mapped files pool, and -disk pool (in that order) depending on the ‑limit settings -and whether the system honors a resource request. If the total size of -allocated pixel storage in the given pool reaches the corresponding limit, the -request is passed to the next pool. Additionally, requests that exceed the -area limit automagically are allocated on disk.

    - -

    To illustrate how ImageMagick utilizes resource limits, consider a typical -image resource request. First, ImageMagick tries to allocate the pixels in -memory. The request might be denied if the resource request exceeds the -memory limit or if the system does not honor the request. If -a memory request is not honored, the pixels are allocated to disk and the file -is memory-mapped. However, if the allocation request exceeds the -map limit, the resource allocation goes to disk. In all cases, if -the resource request exceeds the area limit, the pixels are -automagically cached to disk. If the disk has a hard limit, the program -fails.

    - -

    In most cases you simply do not need to concern yourself with resource -limits. ImageMagick chooses reasonable defaults and most images do not tax -your computer resources. Where limits do come in handy is when you process -images that are large or on shared systems where ImageMagick can consume all -or most of the available memory. In this case, the ImageMagick workflow slows -other processes or, in extreme cases, brings the system to a halt. Under -these circumstances, setting limits give some assurances that the ImageMagick -workflow will not interfere with other concurrent uses of the computer. For -example, assume you have a web interface that processes images uploaded from -the Internet. To assure ImageMagick does not exceed 10MiB of memory you can -simply set the area limit to 10MiB:

    - -
    --limit area 10MB
    -
    - -

    Now whenever a large image is processed, the pixels are automagically -cached to disk instead of memory. This of course implies that large images -typically process very slowly, simply because pixel processing in memory can -be an order of magnitude faster than on disk. Because your web site users -might inadvertently upload a huge image to process, you should set a disk -limit as well:

    - -
    --limit area 10MB -limit disk 500MB
    -
    - -

    Here ImageMagick stops processing if an image requires more than 500MB of disk storage.

    - -

    In addition to command-line resource limit option, resources can be set -with environment variables. Set the -environment variables MAGICK_AREA_LIMIT, -MAGICK_DISK_LIMIT, MAGICK_FILE_LIMIT, -MAGICK_MEMORY_LIMIT, MAGICK_MAP_LIMIT, -MAGICK_THREAD_LIMIT, MAGICK_TIME_LIMIT for limits of -image area, disk space, open files, heap memory, memory map, number of threads -of execution, and maximum elapsed time in seconds respectively.

    - -

    Inquisitive users can try adding -debug cache to -their commands and then scouring the generated output for references to the -pixel cache, in order to determine how the pixel cache was allocated and how -resources were consumed. Advanced Unix/Linux users can pipe that output -through grep memory|open|destroy|disk for more readable sifting. -

    - -

    For more about ImageMagick's use of resources, see the section Cache -Storage and Resource Requirements on the Architecture page.

    - -
    -

    -linear-stretch black-point
    -linear-stretch black-point{xwhite-point}{%}}

    -
    - -

    Linear with saturation stretch.

    - -

    This is very similar to -contrast-stretch, -and uses a 'histogram bin' to determine the range of color values that needs to -be stretched. However it then stretches those colors using the -level operator.

    - -

    As such while the initial determination may have 'binning' round off -effects, the image colors are stretched mathematically, rather than using the -histogram bins. This makes the operator more accurate.

    - -

    note however that a -linear-stretch of -'0' does nothing, while a value of '1' does a near -perfect stretch of the color range.

    - -

    See also -auto-level for a 'perfect' -normalization of mathematical images.

    - -

    This operator is under review for re-development.

    - - -
    -

    -linewidth

    -
    - -

    the line width for subsequent draw operations.

    - -
    -

    -liquid-rescale geometry

    -
    - -

    rescale image with seam-carving.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -list type

    -
    - -

    Print a list of supported arguments for various options or settings. Choose from these list types:

    - -
    -Align
    -Alpha
    -Boolean
    -Cache
    -Channel
    -Class
    -ClipPath
    -Coder
    -Color
    -Colorspace
    -Command
    -Complex
    -Compose
    -Compress
    -Configure
    -DataType
    -Debug
    -Decoration
    -Delegate
    -Direction
    -Dispose
    -Distort
    -Dither
    -Endian
    -Evaluate
    -FillRule
    -Filter
    -Font
    -Format
    -Function
    -Gravity
    -Intensity
    -Intent
    -Interlace
    -Interpolate
    -Kernel
    -Layers
    -LineCap
    -LineJoin
    -List
    -Locale
    -LogEvent
    -Log
    -Magic
    -Method
    -Metric
    -Mime
    -Mode
    -Morphology
    -Module
    -Noise
    -Orientation
    -PixelIntensity
    -Policy
    -PolicyDomain
    -PolicyRights
    -Preview
    -Primitive
    -QuantumFormat
    -Resource
    -SparseColor
    -Statistic
    -Storage
    -Stretch
    -Style
    -Threshold
    -Type
    -Units
    -Validate
    -VirtualPixel
    -
    - -

    These lists vary depending on your version of ImageMagick. Use "-list -list" to get a complete listing of all the "-list" arguments -available:

    - -
    -identify -list list
    -
    - -
    -

    -log string

    -
    - -

    Specify format for debug log.

    - -

    This option specifies the format for the log printed when the -debug option is active.

    - -

    You can display the following components by embedding special format -characters:

    - -
    -
    %d
    domain
    -
    %e
    event
    -
    %f
    function
    -
    %l
    line
    -
    %m
    module
    -
    %p
    process ID
    -
    %r
    real CPU time
    -
    %t
    wall clock time
    -
    %u
    user CPU time
    -
    %%
    percent sign
    -
    \n
    newline
    -
    \r
    carriage return
    -
    - -

    For example:

    - -
    -convert -debug coders -log "%u %m:%l %e" in.gif out.png
    -
    - -

    The default behavior is to print all of the components.

    - -
    -

    -loop iterations

    -
    - -

    add Netscape loop extension to your GIF animation.

    - -

    Set iterations to zero to repeat the animation an infinite number of times, -otherwise the animation repeats itself up to iterations -times.

    - -
    -

    -lowlight-color color

    -
    - -

    when comparing images, de-emphasize pixel differences with this color.

    - -
    -

    -magnify

    -
    - -

    double the size of the image with pixel art scaling.

    - - -
    -

    -map type

    -
    - -

    Display image using this type.

    - -

    Choose from these Standard Colormap types:

    - -
    -best
    -default
    -gray
    -red
    -green
    -blue
    -
    - -

    The X server must support the Standard -Colormap you choose, otherwise an error occurs. Use list as -the type and display searches the list of colormap types in -top-to-bottom order until one is located. See xstdcmap(1) for one way of creating Standard Colormaps.

    - - -
    -

    -map components

    -
    - -

    pixel map.

    - -

    Here are the valid components of a map:

    - -
    -
    r
    red pixel component
    -
    g
    green pixel component
    -
    b
    blue pixel component
    -
    a
    alpha pixel component (0 is transparent)
    -
    o
    opacity pixel component (0 is opaque)
    -
    i
    grayscale intensity pixel component
    -
    c
    cyan pixel component
    -
    m
    magenta pixel component
    -
    y
    yellow pixel component
    -
    k
    black pixel component
    -
    p
    pad component (always 0)
    -
    - -

    You can specify as many of these components as needed in any order (e.g. -bgr). The components can repeat as well (e.g. rgbr).

    - - -
    -

    -mask -filename

    -
    - -

    Prevent updates to image pixels specified by the mask.

    - -

    This the same as using a mask used for composite masking operations, with -grayscale values causing blended updates of the image the mask is attached to. -

    - -

    Use +mask to remove the mask from images.

    - -

    Also see -clip-mask which work in the same way, -but with strict boolean masking.

    - -
    -

    -mattecolor color

    -
    - -

    Specify the color to be used with the -frame option.

    - -

    The color is specified using the format described under the -fill option.

    - -

    The default matte color is #BDBDBD, this shade of gray.

    - -
    -

    -maximum

    -
    - -

    return the maximum intensity of an image sequence.

    - -

    Select the 'maximum' value from all the surrounding pixels.

    - -

    This is legacy option from the method of the same -name.

    - -
    -

    -median geometry

    -
    - -

    apply a median filter to the image.

    - -

    Select the 'middle' value from all the surrounding pixels.

    - -

    This is legacy option from the method of the same -name.

    - -
    -

    -mean-shift widthxheight{+distance{%}}

    -
    - -

    image noise removal and color reduction/segmentation (e.g. -mean-shift 7x7+10%).

    - -

    widthxheight is the window size and distance is the color distance measured in the range 0 to 1 or 0 to 100%

    - -

    The mean shift algorithm is iterative and thus slower the larger the window size. For each pixel, it gets all the pixels in the window centered at the pixel and excludes those that are outside the radius=sqrt((width-1)(height-1)/4) surrounding the pixel. From those pixels, it finds which of them are within the specified squared color distance from the current mean. It then computes a new x,y centroid from those coordinates and a new mean. This new x,y centroid is used as the center for a new window. This process is iterated until it converges and the final mean is then used to replace the original pixel value. It repeats this process for the next pixel, etc, until it processes all pixels in the image. Results are better when using other colorspaces rather than RGB. Recommend YIQ, YUV or YCbCr, which seem to give equivalent results.

    - -
    -

    -metric type

    -
    - -

    Output to STDERR a measure of the differences between images according to the type given metric.

    - -

    Choose from:

    - -
    -
    AE
    absolute error count, number of different pixels (-fuzz effected)
    -
    FUZZ
    mean color distance
    -
    MAE
    mean absolute error (normalized), average channel error distance
    -
    MEPP
    mean error per pixel (normalized mean error, normalized peak error)
    -
    MSE
    mean error squared, average of the channel error squared
    -
    NCC
    normalized cross correlation
    -
    PAE
    peak absolute (normalized peak absolute)
    -
    PHASH
    perceptual hash
    -
    PSNR
    peak signal to noise ratio
    -
    RMSE
    root mean squared (normalized root mean squared)
    -
    - -

    Control the 'AE', or absolute count of pixels that are different, -with the -fuzz factor (ignore pixels which -only changed by a small amount). Use 'PAE' to find the -size of the -fuzz factor needed to make all pixels -'similar', while 'MAE' determines the factor needed -for about half the pixels to be similar.

    - -

    The 'MEPP' metric returns three different metrics -('MAE', 'MAE' normalized, and 'PAE' -normalized) from a single comparison run.

    - -

    To print a complete list of metrics, use the -list -metric option.

    - - -
    -

    -minimum

    -
    - -

    return the minimum intensity of an image sequence.

    - -

    Select the 'minimal' value from all the surrounding pixels.

    - -

    This is legacy option from the method of the same -name.

    - - - -
    -

    -mode geometry

    -
    - -

    make each pixel the \'predominant color\' of the neighborhood.'

    - -
    -

    -mode value

    -
    - -

    Mode of operation.

    - -

    Choose the value from these styles: Frame, -Unframe, or Concatenate

    - -

    Use the -list option with a 'Mode' argument -for a list of -mode arguments available in your -ImageMagick installation.

    - - -
    -

    -modulate brightness[,saturation,hue]

    -
    - -

    Vary the brightness, saturation, and hue of an image.

    - -

    The arguments are given as a percentages of variation. A value of 100 means -no change, and any missing values are taken to mean 100.

    - -

    The brightness is a multiplier of the overall -brightness of the image, so 0 means pure black, 50 is half as bright, 200 is -twice as bright. To invert its meaning -negate the image -before and after.

    - -

    The saturation controls the amount of color in an -image. For example, 0 produce a grayscale image, while a large value such as -200 produce a very colorful, 'cartoonish' color.

    - -

    The hue argument causes a "rotation" of the colors -within the image by the amount specified. For example, 50 results in -a counter-clockwise rotation of 90, mapping red shades to purple, and so on. -A value of either 0 or 200 results in a complete 180 degree rotation of the -image. Using a value of 300 is a 360 degree rotation resulting in no change to -the original image.

    - -

    For example, to increase the color brightness by 20% and decrease the color -saturation by 10% and leave the hue unchanged, use -modulate 120,90.

    - -

    Use -set attribute of 'option:modulate:colorspace' to specify which colorspace to -modulate. Choose from HCL, HCLp, HSB, HSI, HSL (the default), HSV, HWB, or LCH (LCHuv). For example,

    - -
    -convert image.png -set option:modulate:colorspace hsb -modulate 120,90 modulate.png
    -
    - -
    -

    -moments

    -
    - -

    report image moments and perceptual hash.

    - - -
    -

    -monitor

    -
    - -

    monitor progress.

    - - -
    -

    -monochrome

    -
    - -

    transform the image to black and white.

    - -
    -

    -morph frames

    -
    - -

    morphs an image sequence.

    - -

    Both the image pixels and size are linearly interpolated to give the -appearance of a metamorphosis from one image to the next, over all the images -in the current image list. The added images are the equivalent of a -blend composition. The frames -argument determine how many images to interpolate between each image.

    - - -
    -

    -morphology

    -

    -morphology method kernel

    -
    - -

    apply a morphology method to the image.

    - -

    Until I get around to writing an option summary for this, see IM Usage Examples, -Morphology.

    - - -
    -

    -mosaic

    -
    - -

    an simple alias for the -layers method "mosaic"

    - - -
    -

    -motion-blur radius
    -motion-blur radiusxsigma+angle

    -
    - -

    simulate motion blur.

    - -

    Blur with the given radius, standard deviation (sigma), and angle. The -angle given is the angle toward which the image is blurred. That is the -direction people would consider the object is coming from.

    - -

    Note that the blur is not uniform distribution, giving the motion a -definite sense of direction of movement.

    - -

    The -virtual-pixel setting will determine how -pixels which are outside the image proper are blurred into the final result. -

    - -
    -

    -name

    -
    - -

    name an image.

    -
    -

    -negate

    -
    - -

    replace each pixel with its complementary color.

    - -

    The red, green, and blue intensities of an image are negated. White becomes -black, yellow becomes blue, etc. Use +negate to only -negate the grayscale pixels of the image.

    - -
    -

    -noise geometry
    - +noise type

    -
    - -

    Add or reduce noise in an image.

    - -

    The principal function of noise peak elimination filter is to smooth the -objects within an image without losing edge information and without creating -undesired structures. The central idea of the algorithm is to replace a pixel -with its next neighbor in value within a pixel window, if this pixel has been -found to be noise. A pixel is defined as noise if and only if this pixel is -a maximum or minimum within the pixel window.

    - -

    Use -noise radius to -specify the width of the neighborhood when reducing noise. This is equivalent -to using a -statistic NonPeak operation, -which should be used in preference.

    - -

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

    - -
    -Gaussian
    -Impulse
    -Laplacian
    -Multiplicative
    -Poisson
    -Random
    -Uniform
    -
    - -

    The amount of noise added can be controlled by the -attenuate setting. If unset the value is -equivalent to 1.0, or a maximum noise addition.

    - -

    Note that Random will replace the image with noise rather than add noise to the image. Use Uniform, if you wish to add random noise to the image.

    - -

    To print a complete list of noises, use the -list noise option.

    - -

    Also see the -evaluate noise functions that allows -the use of a controlling value to specify the amount of noise that should be -added to an image.

    - - -
    -

    -normalize

    -
    - -

    Increase the contrast in an image by stretching the range of intensity values.

    - -

    The intensity values are stretched to cover the entire range of possible -values. While doing so, black-out at most 2% of the pixels and -white-out at most 1% of the pixels.

    - -

    Note that as of ImageMagick 6.4.7-0, -normalize -is equivalent to -contrast-stretch 2%x1%. -(Before this version, it was equivalent to -contrast-stretch 2%x99%).

    - -

    All the channels are normalized in concert by the came amount so as to -preserve color integrity, when the default +channel -setting is in use. Specifying any other -channel -setting will normalize the RGB channels independently.

    - -

    See -contrast-stretch for more details. -Also see -auto-level for a 'perfect' normalization -that is better suited to mathematically generated images.

    - -

    This operator is under review for re-development.

    - - -
    -

    -opaque color

    -
    - -

    change this color to the fill color within the image.

    - -

    The color argument is defined using the format -described under the -fill option. The -fuzz setting can be used to match and replace colors similar to the one -given.

    - -

    Use +opaque to paint any pixel that does not match -the target color.

    - -

    The -transparent operator is exactly the same -as -opaque but replaces the matching color with -transparency rather than the current -fill color setting. -To ensure that it can do this it also ensures that the image has an alpha -channel enabled, as per "-alpha set", for -the new transparent colors, and does not require you to modify the -channel to enable alpha channel handling.

    - - -
    -

    -ordered-dither threshold_map{,level...}

    -
    - -

    dither the image using a pre-defined ordered dither threshold map specified, and a uniform color map with the -given number of levels per color channel.

    - -

    You can choose from these standard threshold maps:

    - -
    -threshold   1x1   Threshold 1x1 (non-dither)
    -checks      2x1   Checkerboard 2x1 (dither)
    -o2x2        2x2   Ordered 2x2 (dispersed)
    -o3x3        3x3   Ordered 3x3 (dispersed)
    -o4x4        4x4   Ordered 4x4 (dispersed)
    -o8x8        8x8   Ordered 8x8 (dispersed)
    -h3x4a       4x1   Halftone 4x4 (angled)
    -h6x6a       6x1   Halftone 6x6 (angled)
    -h8x8a       8x1   Halftone 8x8 (angled)
    -h3x4o             Halftone 4x4 (orthogonal)
    -h6x6o             Halftone 6x6 (orthogonal)
    -h8x8o             Halftone 8x8 (orthogonal)
    -h36x16o           Halftone 16x16 (orthogonal)
    -c5x5b       c5x5  Circles 5x5 (black)
    -c5x5w             Circles 5x5 (white)
    -c6x6b       c6x6  Circles 6x6 (black)
    -c6x6w             Circles 6x6 (white)
    -c7x7b       c7x7  Circles 7x7 (black)
    -c7x7w             Circles 7x7 (white)
    -
    - -

    The threshold generated a simple 50% threshold of the image. -This could be used with level to do the equivalent of -posterize to reduce an image to basic primary colors. -

    - -

    The checks pattern produces a 3 level checkerboard dither -pattern. That is a grayscale will become a pattern of solid black, solid -white, and mid-tone colors into a checkerboard pattern of black and white. -

    - -

    You can define your own threshold map for ordered -dithering and halftoning your images, in either personal or system -thresholds.xml XML file. See Resources -for more details of configuration files.

    - -

    To print a complete list of the thresholds that have been defined, use the --list threshold option.

    - -

    Note that at this time the same threshold dithering map is used for all -color channels, no attempt is made to offset or rotate the map for different -channels is made, to create an offset printing effect. Also as the maps are -simple threshold levels, the halftone and circle maps will create incomplete -circles along the edges of a colored area. Also all the effects are purely -on/off boolean effects, without anti-aliasing to make the circles smooth -looking. Large dots can be made to look better with a small amount of blurring -after being created.

    - - -
    -

    -orient image orientation

    -
    - -

    specify orientation of a digital camera image.

    - -

    Choose from these orientations:

    - -
    -bottom-left    right-top
    -bottom-right   top-left
    -left-bottom    top-right
    -left-top       undefined
    -right-bottom
    -
    - -

    To print a complete list of orientations, use the -list -orientation option.

    - - -
    -

    -page geometry
    - -page media[offset][{^!<>}]
    - +page -

    -
    - -

    Set the size and location of an image on the larger virtual canvas.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -

    For convenience you can specify the page size using media (see below). Offsets can then be added as with other -geometry arguments (e.g. -page Letter+43+43).

    - -

    Use media as shorthand to specify the dimensions (widthxheight) of the PostScript page in dots per inch or a TEXT page in pixels. -The choices for a PostScript page are:

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

    This option is also used to place subimages when writing to a multi-image -format that supports offsets, such as GIF89 and MNG. When used for this -purpose the offsets are always measured from the top left corner of the canvas -and are not affected by the -gravity option. To -position a GIF or MNG image, use -page{+-}x{+-}y (e.g. -page +100+200). When writing to a MNG -file, a -page option appearing ahead of the first image in -the sequence with nonzero width and height defines the width and height values -that are written in the MHDR chunk. Otherwise, the MNG width and -height are computed from the bounding box that contains all images in the -sequence. When writing a GIF89 file, only the bounding box method is used to -determine its dimensions.

    - -

    For a PostScript page, the image is sized as in -geometry but positioned relative to the lower -left-hand corner of the page by {+-}xoffset{+-}y offset. Use -page 612x792, for example, to center the image within the -page. If the image size exceeds the PostScript page, it is reduced to fit the -page. The default gravity for the -page option is NorthWest, i.e., positive x and y offset are measured rightward and downward from the top left -corner of the page, unless the -gravity option is -present with a value other than NorthWest.

    - -

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

    - -

    This option is used in concert with -density.

    - -

    Use +page to remove the page settings for an image.

    - -
    -

    -paint radius

    -
    - -

    simulate an oil painting.

    - -

    Each pixel is replaced by the most frequent color in a circular -neighborhood whose width is specified with radius.

    - -
    -

    -path path

    - -

    write images to this path on disk.

    - -
    -

    -pause seconds

    -
    - -

    Pause between animation loops

    - -

    Pause for the specified number of seconds before repeating the animation.

    - -
    -

    -pause seconds

    -
    - -

    Pause between snapshots.

    - -

    Pause for the specified number of seconds before taking the next snapshot.

    - -
    -

    -perceptible epsilon

    -
    - -

    set each pixel whose value is less than |epsilon| to -epsilon or epsilon (whichever is closer) otherwise the pixel value remains unchanged.

    - -
    -

    -ping

    -
    - -

    efficiently determine image characteristics.

    - -
    -

    -pointsize value

    -
    - -

    pointsize of the PostScript, OPTION1, or TrueType font.

    - -
    -

    -polaroid angle

    -
    - -

    simulate a Polaroid picture.

    - -

    Use +polaroid to rotate the image at a random angle between -15 and +15 degrees.

    - -
    -

    -poly "wt,exp ..."

    -
    - -

    combines multiple images according to a weighted sum of polynomials; one floating point weight (coefficient) and one floating point polynomial exponent (power) for each image expressed as comma separated pairs.

    - -

    The weights should typically be fractions between -1 and 1. But the sum of weights should be 1 or at least between 0 and 1 to avoid clamping in non-hdri mode at black and white.

    - -

    The exponents may be positive, negative or zero. A negative exponent is equivalent to 1 divided by the image raised to the corresponding positive exponent. A zero exponent always produces 1 scaled by quantumrange to white, i.e. wt*white, no matter what the image.

    - -

    The format is: output = wt1*image1^exp1 + wt2*image2^exp2 ...

    - -

    Some simple uses are:

    -
      -
    • A weighted sum of each image provided all weights add to unity and all exponents=1. If the the weights are all equal to 1/(number of images), then this is equivalent to -evaluate-sequence mean.
    • -
    • The sum of squares of two or more images, provided the weights are equal (and sum to 1 to avoid clamping) and the exponents equal 2.
    • -
    - -

    Note that one may add a constant color to the expression simply by using xc:somecolor for one of the images and specifying the desired weight and exponent equal to 0.

    - -

    Similarly one may add white to the expression by simply using null: (or xc:white) for one of the images with the appropriate weight and exponent equal to 0.

    - - -
    -

    -posterize levels

    -
    - -

    reduce the image to a limited number of color levels per channel.

    - -

    Very low values of levels, e.g., 2, 3, 4, have the most -visible effect.

    - -
    -

    -precision value

    -
    - -

    set the maximum number of significant digits to be printed.

    - -
    -

    -preview type

    -
    - -

    image preview type.

    - -

    Use this option to affect the preview operation of an image (e.g. -convert file.png -preview Gamma Preview:gamma.png). Choose from -these previews:

    - -
    -AddNoise
    -Blur
    -Brightness
    -Charcoal
    -Despeckle
    -Dull
    -EdgeDetect
    -Gamma
    -Grayscale
    -Hue
    -Implode
    -JPEG
    -OilPaint
    -Quantize
    -Raise
    -ReduceNoise
    -Roll
    -Rotate
    -Saturation
    -Segment
    -Shade
    -Sharpen
    -Shear
    -Solarize
    -Spiff
    -Spread
    -Swirl
    -Threshold
    -Wave
    -
    - -

    To print a complete list of previews, use the -list preview option.

    - -

    The default preview is JPEG.

    - -
    -

    -print string

    -
    - -

    interpret string and print to console.

    - -
    -

    -process command

    -
    - -

    process the image with a custom image filter.

    - -

    The command arguments has the form "module arg1 arg2 arg3 ... -argN" where module is the name of the module to invoke (e.g. -"Analyze") and arg1 arg2 arg3 ... argN are an arbitrary number of arguments to -pass to the process module.

    - -
    -

    -profile filename
    - +profile profile_name

    -
    - -

    Manage ICM, IPTC, or generic profiles in an image.

    - -

    Using -profile filename adds an -ICM (ICC color management), IPTC (newswire information), or a generic profile -to the image.

    - -

    Use +profile profile_name to -remove the indicated profile. ImageMagick uses standard filename globbing, so -wildcard expressions may be used to remove more than one profile. Here we -remove all profiles from the image except for the XMP profile: +profile -"!xmp,*".

    - -

    Use identify -verbose to find out which profiles are in the -image file. Use -strip to remove all profiles (and -comments).

    - -

    To extract a profile, the -profile option is not -used. Instead, simply write the file to an image format such as APP1, 8BIM, ICM, or IPTC.

    - -

    For example, to extract the Exif data (which is stored in JPEG files in the -APP1 profile), use.

    - -
    -convert cockatoo.jpg profile.exif
    -
    - -

    It is important to note that results may depend on whether or not the -original image already has an included profile. Also, keep in mind that -profile is an "operator" (as opposed to a "setting") and -therefore a conversion is made each time it is encountered, in order, in the -command-line. For instance, in the following example, if the original image is -CMYK with profile, a CMYK-CMYK-RGB conversion results.

    - -
    -convert CMYK.tif -profile "CMYK.icc" -profile "RGB.icc" RGB.tiff
    -
    - -

    Furthermore, since ICC profiles are not necessarily symmetric, extra -conversion steps can yield unwanted results. CMYK profiles are often very -asymmetric since they involve 3−>4 and 4−>3 channel mapping. -

    - -
    -

    -quality value

    -
    - -

    JPEG/MIFF/PNG compression level.

    - -

    For the JPEG and MPEG image formats, quality is 1 (lowest image quality and -highest compression) to 100 (best quality but least effective compression). -The default is to use the estimated quality of your input image if it can -be determined, otherwise 92. When the quality is greater than 90, then the -chroma channels are not downsampled. -Use the -sampling-factor option to specify the -factors for chroma downsampling.

    - -

    For the JPEG-2000 image format, quality is mapped using a non-linear -equation to the compression ratio required by the Jasper library. This -non-linear equation is intended to loosely approximate the quality provided by -the JPEG v1 format. The default quality value 100, a request for non-lossy -compression. A quality of 75 results in a request for 16:1 compression.

    - -

    For the MNG and PNG image formats, the quality value sets the zlib -compression level (quality / 10) and filter-type (quality % 10). The default -PNG "quality" is 75, which means compression level 7 with adaptive PNG -filtering, unless the image has a color map, in which case it means -compression level 7 with no PNG filtering.

    - -

    For compression level 0 (quality value less than 10), the Huffman-only -strategy is used, which is fastest but not necessarily the worst -compression.

    - -

    If filter-type is 4 or less, the specified PNG filter-type is used for -all scanlines:

    - -
    -
    0
    none
    -
    1
    sub
    -
    2
    up
    -
    3
    average
    -
    4
    Paeth
    -
    - -

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

    - -

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

    - -

    Only if the output is MNG, if filter-type is 7, the LOCO color -transformation (intrapixel differencing) and adaptive filtering -with minimum-sum-of-absolute-values are used.

    - -

    If the filter-type is 8 the zlib Z_RLE compression strategy (or the -Z_HUFFMAN_ONLY strategy, when compression level is 0) is used with -adaptive PNG filtering.

    - -

    If the filter-type is 9 the zlib Z_RLE compression strategy (or the -Z_HUFFMAN_ONLY strategy, when compression level is 0) is used with -no PNG filtering.

    - -

    The quality setting has no effect on the appearance or signature of PNG -and MNG images, since the compression is always lossless.

    - -

    Not all combinations of compression level, strategy, and PNG filter type -can be obtained using the -quality option. For more precise control, -you can use the PNG:compression-level=N, PNG:compression-strategy=N, and -PNG:compression-filter=N defines, respectively, instead. -See -define. Values from the defines take precedence -over values from the -quality option.

    - -

    For further information, see -the PNG specification.

    - -

    For the MIFF and TIFF image formats, quality/10 is the Zip/BZip compression level, which is 0 (worst but fastest compression) to 9 (best but slowest). It has no effect on the image appearance, since the compression is always lossless.

    - -

    For the BPG image format, quality/2 is the actual BPG compression level (range from 0 to 51).

    - -
    -

    -quantize colorspace

    -
    - -

    reduce colors using this colorspace.

    - -

    This setting defines the colorspace used to sort out and reduce the number -of colors needed by an image (for later dithering) by operators such as -colors, Note that color reduction also happens -automatically when saving images to color-limited image file formats, such as -GIF, and PNG8.

    - - -
    -

    -quiet

    -
    - -

    suppress all warning messages. Error messages are still reported.

    - -
    -

    -radial-blur angle

    -
    - -

    Blur around the center of the image.

    - -

    Note that this is actually a rotational blur rather than a radial and as -such actually mis-named.

    - -

    The -virtual-pixel setting will determine how -pixels which are outside the image proper are blurred into the final result. -

    - - -
    -

    -raise thickness

    -
    - -

    Lighten or darken image edges.

    - -

    This will create a 3-D effect. Use -raise to create -a raised effect, otherwise use +raise.

    - -

    Unlike the similar -frame option, -raise does not alter the dimensions of the image.

    - -
    -

    -random-threshold lowxhigh

    -
    - -

    Apply a random threshold to the image.

    - -
    -

    -red-primary x,y

    -
    - -

    Set the red chromaticity primary point.

    - -
    -

    -regard-warnings

    -
    - -

    Pay attention to warning messages.

    - -

    This option causes some warnings in some image formats to be treated -as errors.

    - -
    -

    -remap filename

    -
    - -

    Reduce the number of colors in an image to the colors used by this image.

    - -

    If the -dither setting is enabled (the default) then -the given colors are dithered over the image as necessary, otherwise the closest -color (in RGB colorspace) is selected to replace that pixel in the image.

    - -

    As a side effect of applying a -remap of colors across all -images in the current image sequence, all the images will have the same color -table. That means that when saved to a file format such as GIF, it will use -that color table as a single common or global color table, for all the images, -without requiring extra local color tables.

    - -

    Use +remap to reduce all images in the current image -sequence to use a common color map over all the images. This equivalent to -appending all the images together (without extra background colors) and color -reducing those images using -colors with a 256 color -limit, then -remap those colors over the original list of -images. This ensures all the images follow a single color map.

    - -

    If the number of colors over all the images is less than 256, then +remap should not perform any color reduction or dithering, as -no color changes are needed. In that case, its only effect is to force the use -of a global color table. This recommended after using either -colors or -ordered-dither to -reduce the number of colors in an animated image sequence.

    - -

    Note, the remap image colormap has at most 8-bits of precision. Deeper color maps are automagically coalesced with other colors to meet this requirement.

    - -
    -

    -region geometry

    -
    - -

    Set a region in which subsequent operations apply.

    - -

    The x and y offsets are treated -in the same manner as in -crop.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -

    Use +region to remove any previously set regions.

    - -
    -

    -remote

    -
    - -

    perform a remote operation.

    - -

    The only command recognized is the name of an image file to load.

    - -

    If you have more than one display application -running simultaneously, use the window option to -specify which application to control.

    - -
    -

    -render

    -
    - -

    render vector operations.

    - -

    Use +render to turn off rendering vector operations. -This useful when saving the result to vector formats such as MVG or SVG.

    - -
    -

    -repage geometry

    -
    - -

    Adjust the canvas and offset information of the image.

    - -

    This option is like -page but acts as an image operator -rather than a setting. You can separately set the canvas size or the offset -of the image on that canvas by only providing those components.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -

    If a ! flag is given the offset given is added to the existing -offset to move the image relative to its previous position. This useful for -animation sequences.

    - -

    A given a canvas size of zero such as '0x0' forces it to -recalculate the canvas size so the image (at its current offset) will appear -completely on that canvas (unless it has a negative offset).

    - -

    Use +repage to completely remove/reset the virtual -canvas meta-data from the images.

    - -

    The -set 'page' option can be used to -directly assign virtual canvas meta-data.

    - - -
    -

    -resample horizontalxvertical

    -
    - -

    Resample image to specified horizontal and vertical resolution.

    - -

    Resize the image so that its rendered size remains the same as the original -at the specified target resolution. For example, if a 300 DPI image renders at -3 inches by 2 inches on a 300 DPI device, when the image has been resampled to -72 DPI, it will render at 3 inches by 2 inches on a 72 DPI device. Note that -only a small number of image formats (e.g. JPEG, PNG, and TIFF) are capable of -storing the image resolution. For formats which do not support an image -resolution, the original resolution of the image must be specified via -density on the command line prior to specifying the -resample resolution.

    - -

    Note that Photoshop stores and obtains image resolution from a proprietary -embedded profile. If this profile exists in the image, then Photoshop will -continue to treat the image using its former resolution, ignoring the image -resolution specified in the standard file header.

    - -
    -

    -resize geometry

    -
    - -

    Resize an image.

    - -

    See Image Geometry for complete details about the geometry argument. Offsets, if present in the geometry string, are -ignored, and the -gravity option has no effect.

    - -

    If the -filter option -or -define filter:option=value precedes the -resize option, the image is resized with the specified -filter.

    - -

    Many image processing algorithms assume your image is in a linear-light -coding. If your image is gamma-corrected, you can remove the nonlinear gamma -correction, apply the transform, then restore it like this:

    - -
    -convert portrait.jpg -gamma .45455 -resize 25% -gamma 2.2  \
    -  -quality 92 passport.jpg
    -
    - -
    -

    -respect-parentheses

    -
    - -

    settings remain in effect until parenthesis boundary.

    - -
    -

    -reverse

    -
    - -

    Reverse the order of images in the current image list.

    - - -
    -

    -roll {+-}x{+-}y

    -
    - -

    roll an image vertically or horizontally by the amount given.

    - -

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

    - - -
    -

    -rotate degrees{<}{>}

    -
    - -

    Apply Paeth image rotation (using shear operations) to the image.

    - -

    Use > to rotate the image only if its width exceeds the -height. < rotates the image only if its width is less -than the height. For example, if you specify -rotate "-90>" and -the image size is 480x640, the image is not rotated. However, if the image is -640x480, it is rotated by -90 degrees. If you use > or -<, enclose it in quotation marks to prevent it from being -misinterpreted as a file redirection.

    - -

    Empty triangles in the corners, left over from rotating the image, are -filled with the background color.

    - -

    See also the -distort operator and specifically the -'ScaleRotateTranslate' distort method.

    - - -
    -

    -sample geometry

    -
    - -

    minify / magnify the image with pixel subsampling and pixel replication, respectively.

    - -

    Change the image size simply by directly sampling the pixels original -from the image. When magnifying, pixels are replicated in blocks. When -minifying, pixels are sub-sampled (i.e., some rows and columns are skipped -over).

    - -

    The results are thus equivalent to using -resize with -a -filter setting of point (nearest -neighbor), though -sample is a lot faster, as it -avoids all the filter processing of the image. As such it completely ignores -the current -filter setting.

    - -

    The key feature of the -sample is that no new colors -will be added to the resulting image, though some colors may disappear.

    - -

    See Image Geometry for complete details about the geometry argument. Offsets, if present in the geometry string, are -ignored, unlike -resize.

    - - -

    The actual sampling point is the middle of the sub-region being sampled. -As such a single pixel sampling of an image will take the middle pixel, (or -top-left-middle if image has even dimensions). However the -define 'sample:offset' can be set to modify -this position some other location within each sub-region being sampled, as -a percentage offset.

    - -

    By default this value is '50' for the midpoint, but could be set -to '0' for top-left, '100' for bottom-right, or with -separate X and Y offsets such as '0x50' for left-middle edge of -sampling sub-region.

    - - -
    -

    -sampling-factor horizontal-factorxvertical-factor

    -
    - -

    sampling factors used by JPEG or MPEG-2 encoder and YUV decoder/encoder.

    - -

    This option specifies the sampling factors to be used by the JPEG encoder -for chroma downsampling. If this option is omitted, the JPEG library will use -its own default values. When reading or writing the YUV format and when -writing the M2V (MPEG-2) format, use -sampling-factor 2x1 or -sampling-factor 4:2:2 to specify the 4:2:2 -downsampling method.

    - -
    -

    -scale geometry

    -
    - -

    minify / magnify the image with pixel block averaging and pixel replication, respectively.

    - -

    Change the image size simply by replacing pixels by averaging pixels -together when minifying, or replacing pixels when magnifying.

    - -

    The results are thus equivalent to using -resize with -a -filter setting of box. Though it is a lot -faster, as it avoids all the filter processing of the image. As such it -completely ignores the current -filter setting.

    - -

    If when shrinking (minifying) images the original image is some integer -multiple of the new image size, the number of pixels averaged together to -produce the new pixel color is the same across the whole image. This is -a special case known as 'binning' and is often used as a method of reducing -noise in image such as those generated by digital cameras, especially in low -light conditions.

    - - -
    -

    -scene value

    -
    - -

    set scene number.

    - -

    This option sets the scene number of an image or the first image in an image sequence.

    - -
    -

    -screen

    -
    - -

    specify the screen to capture.

    - -

    This option indicates that the GetImage request used to obtain the image -should be done on the root window, rather than directly on the specified -window. In this way, you can obtain pieces of other windows that overlap the -specified window, and more importantly, you can capture menus or other popups -that are independent windows but appear over the specified window.

    - -
    -

    -seed

    -
    - -

    seed a new sequence of pseudo-random numbers

    - -
    -

    -segment cluster-thresholdxsmoothing-threshold

    -
    - -

    segment the colors of an image.

    - -

    Segment an image by analyzing the histograms of the color components and -identifying units that are homogeneous with the fuzzy c-means technique. This -is part of the ImageMagick color quantization routines.

    - -

    Specify cluster threshold as the number of pixels in -each cluster that must exceed the cluster threshold to be considered valid. -Smoothing threshold eliminates noise in the second -derivative of the histogram. As the value is increased, you can expect -a smoother second derivative. The default is 1.5.

    - -

    If the -verbose setting is defined, a detailed report -of the color clusters is returned.

    - - -
    -

    -selective-blur radius
    -selective-blur radiusxsigma{+threshold}

    -
    - -

    Selectively blur pixels within a contrast threshold.

    - -

    Blurs those pixels that are less than or equal to the threshold in -contrast. The threshold may be expressed as a fraction of QuantumRange or as a percentage.

    - -
    -

    -separate

    -
    - -

    separate an image channel into a grayscale image. Specify the channel with -channel.

    - -
    -

    -sepia-tone threshold

    -
    - -

    simulate a sepia-toned photo.

    - -

    Specify threshold as the percent threshold of the intensity (0 - 99.9%).

    - -

    This option applies a special effect to the image, similar to the effect -achieved in a photo darkroom by sepia toning. Threshold ranges from 0 to QuantumRange and is a measure of the extent of the sepia -toning. A threshold of 80% is a good starting point for a reasonable -tone.

    - - - -
    -

    -set key value

    -

    +set key

    -
    - -

    sets image attributes and properties for images in the current image sequence.

    - -

    This will assign (or modify) specific settings attached to all the images -in the current image sequence. Using the +set form of the -option will either remove, or reset that setting to a default state, as -appropriate.

    - -

    For example, it will modify specific well known image meta-data -'attributes' such as those normally overridden by: the options -delay, -dispose, and -page, -colorspace; generally -assigned before the image is read in, by using a key of -the same name.

    - -

    If the given key does not match a specific known -'attribute ', such as shown above, the setting is stored as a a free form -'property' string. Such settings are listed in -verbose information ("info:" output format) as "Properties". -

    - -

    This includes string 'properties' that are set by and assigned to images -using the options -comment, -label, -caption. These options actually assign -a global 'artifact' which are automatically assigned (and any Format Percent -Escapes expanded) to images as they are read in. For example:

    - -
    --> convert rose: -set comment 'Rose is a rose is a rose is a rose' rose.png
    -identify -format %c rose.png
    -Rose is a rose is a rose is a rose
    -
    - -

    The set value can also make use of Format and Print Image -Properties in the defined value. For example:

    - -
    --> convert rose: -set origsize '%wx%h' -resize 50% \
    -  -format 'Old size = %[origsize]  New size = %wx%h' info:
    -Old size = 70x46  New size = 35x23
    -
    - -

    Other well known 'properties' that are available include: -'date:create' and 'date:modify' and -'signature'.

    - -

    The -repage operator will also allow you to modify -the 'page' attribute of an image for images already in memory (also -see -page). However it is designed to provide a finer -control of the sub-parts of this 'attribute'. The -set page -option will only provide a direct, unmodified assignment of 'page' -attribute.

    - -

    This option can also associate a colorspace or profile with your image. -For example,

    - -
    -convert image.psd -set profile ISOcoated_v2_eci.icc image-icc.psd
    -
    - -

    Some 'properties' must be defined in a specific way to be used. For -example only 'properties' prefixed with "filename:" can be used to -modify the output filename of an image. For example

    - -
    -convert rose: -set filename:mysize '%wx%h' 'rose_%[filename:mysize].png'
    -
    - -

    If the setting value is prefixed with "option:" the setting will -be saved as a global "Artifact" exactly as if it was set using the -define option. As such settings are global in scope, they -can be used to pass 'attributes' and 'properties' of one specific image, -in a way that allows you to use them in a completely different image, even if -the original image has long since been modified or destroyed. For example:

    - -
    -convert rose:  -set option:rosesize '%wx%h' -delete 0 \
    -  label:'%[rosesize]'   label_size_of_rose.gif"
    -
    - -

    Note that Format Percent Escapes will only match -a 'artifact' if the given key does not match an existing -'attribute' or 'property'.

    - -

    You can set the attributes of the image registry by prefixing the value -with registry:.

    - -

    The -set profile option can also be used to inject -previously-formatted ancillary chunks into the output PNG file, using -the commandline option as shown below or by setting the profile via a -programming interface:

    - -
    -convert in.png -set profile PNG-chunk-x:<filename> out.png
    -
    - -

    where x is a location flag and -filename is a file containing the chunk -name in the first 4 bytes, then a colon (":"), followed by the chunk data. -This encoder will compute the chunk length and CRC, so those must not -be included in the file.

    - -

    "x" can be "b" (before PLTE), "m" (middle, i.e., between PLTE and IDAT), -or "e" (end, i.e., after IDAT). If you want to write multiple chunks -of the same type, then add a short unique string after the "x" to prevent -subsequent profiles from overwriting the preceding ones, e.g.,

    - - -
    -convert in.png -set profile PNG-chunk-b01:file01 \ 
    -  -profile PNG-chunk-b02:file02 out.png
    -
    - -
    -

    -shade azimuthxelevation

    -
    - -

    shade the image using a distant light source.

    - -

    Specify azimuth and elevation as -the position of the light source. Use +shade to return -the shading results as a grayscale image.

    - -
    -

    -shadow percent-opacity{xsigma}{+-}x{+-}y{%}

    -
    - -

    simulate an image shadow.

    - -
    -

    -shared-memory

    -
    - -

    use shared memory.

    - -

    This option specifies whether the utility should attempt to use shared -memory for pixmaps. ImageMagick must be compiled with shared memory support, -and the display must support the MIT-SHM extension. -Otherwise, this option is ignored. The default is True.

    - -
    -

    -sharpen radius
    -sharpen radiusxsigma

    -
    - -

    sharpen the image.

    - -

    Use a Gaussian operator of the given radius and standard deviation (sigma).

    - -
    -

    -shave geometry

    -
    - -

    Shave pixels from the image edges.

    - -

    The size portion of the geometry -argument specifies the width of the region to be removed from both sides of -the image and the height of the regions to be removed from top and bottom. -Offsets are ignored.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -shear Xdegrees[xYdegrees]

    -
    - -

    Shear the image along the x-axis and/or y-axis.

    - -

    The shear angles may be positive, negative, or zero. When Ydegrees is omitted it defaults to 0. When both angles are -given, the horizontal component of the shear is performed before the vertical -component.

    - -

    Shearing slides one edge of an image along the x-axis or y-axis (i.e., -horizontally or vertically, respectively),creating a parallelogram. The amount -of each is controlled by the respective shear angle. For horizontal shears, -Xdegrees is measured clockwise relative to "up" (the -negative y-axis), sliding the top edge to the right when 0°<Xdegrees<90° and to the left when 90°<Xdegrees<180°. For vertical shears Ydegrees is measured clockwise relative to "right" (the -positive x-axis), sliding the right edge down when 0°<Ydegrees<90° and up when 90°<Ydegrees<180°.

    - -

    Empty triangles left over from shearing the image are filled with the color -defined by the -background option. The color is specified -using the format described under the -fill option.

    - -

    The horizontal shear is performed before the vertical part. This is -important to note, since horizontal and vertical shears do not -commute, i.e., the order matters in a sequence of shears. For -example, the following two commands are not equivalent.

    - -
    -convert logo: -shear 20x0 -shear 0x60 logo-sheared.png
    -convert logo: -shear 0x60 -shear 20x0 logo-sheared.png
    -
    - -

    The first of the two commands above is equivalent to the following, except -for the amount of empty space created; the command that follows generates -a smaller image, and so is a better choice in terms of time and space.

    - -
    -convert logo: -shear 20x60 logo-sheared.png
    -
    - -
    -

    -sigmoidal-contrast contrastxmid-point

    -
    - -

    increase the contrast without saturating highlights or shadows.

    - -

    Increase the contrast of the image using a sigmoidal transfer function -without saturating highlights or shadows. Contrast -indicates how much to increase the contrast. For example, 0 is none, 3 is -typical and 20 is a lot. -

    - -

    The mid-point indicates where the maximum change -'slope' in contrast should fall in the resultant image (0 is white; 50% is -middle-gray; 100% is black).

    - -

    By default the image contrast is increased, use +sigmoidal-contrast to decrease the contrast.

    - -

    To achieve the equivalent of a sigmoidal brightness change (similar to -a gamma adjustment), you would use -sigmoidal-contrast -{brightness}x0% to increase brightness and +sigmoidal-contrast {brightness}x0% to decrease brightness. -Note the use of '0' fo rthe mid-point of the sigmoidal curve.

    - -

    Using a very high contrast will produce a sort of -'smoothed thresholding' of the image. Not as sharp (with high aliasing -effects) of a true threshold, but with tapered gray-levels around the threshold -mid-point.

    - -
    -

    -silent

    -
    - -

    operate silently.

    - -
    -

    -similarity-threshold value

    -
    - -

    minimum RMSE for subimage match.

    - -

    If this setting is used, then the search will stop as soon as it finds a match whose metric is less than or equal to the value. A partially filled second output image will result. Using a value of zero, will cause the search to stop at the first perfect match it finds. If this setting is left off, then the search will proceed to completion or as limited by -dissimilarity-threshold.

    - -
    -

    -size width[xheight][+offset]

    -
    - -

    set the width and height of the image.

    - -

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

    - -

    For Photo CD images, choose from these sizes:

    - -
    -192x128
    -384x256
    -768x512
    -1536x1024
    -3072x2048
    -
    - -
    -

    -sketch radius
    -sketch radiusxsigma+angle

    -
    - -

    simulate a pencil sketch.

    - -

    Sketch with the given radius, standard deviation (sigma), and angle. The -angle given is the angle toward which the image is sketched. That is the -direction people would consider the object is coming from.

    - -
    -

    -smush offset

    -
    - -

    smush an image sequence together.

    - -
    -

    -snaps value

    -
    - -

    Set the number of screen snapshots.

    - -

    Use this option to grab more than one image from the X server screen, to create an animation sequence.

    - -
    -

    -solarize threshold

    -
    - -

    negate all pixels above the threshold level.

    - -

    Specify factor as the percent threshold of the intensity (0 - 99.9%).

    - -

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

    - -
    -

    -sparse-color method 'x,y color ...'

    -
    - -

    color the given image using the specified points of color, and filling the other intervening colors using the given methods.

    - - -
    -
    barycentric
    -
    three point triangle of color given 3 points. - Giving only 2 points will form a linear gradient between those points. - The gradient generated extends beyond the triangle created by those - 3 points.
    -
    bilinear
    -
    Like barycentric but for 4 points. Less than 4 points - fall back to barycentric.
    -
    voronoi
    -
    Simply map each pixel to the to nearest color point - given. The result are polygonal 'cells' of solid color.
    -
    manhatten
    -
    Like voronoi, but resulting polygonal 'cells' are mapped to a fixed coordinate system.
    -
    shepards
    -
    Colors points biased on the ratio of inverse distance - squared. Generating spots of color in a sea of the average of - colors.
    -
    inverse
    -
    Colors points biased on the ratio of inverse distance. - This generates sharper points of color rather than rounded spots of - 'shepards' Generating spots of color in a sea of the - average of colors.
    -
    - -

    The points are placed according to the images location on the virtual -canvas (-page or -repage -offset), and do not actually have to exist on the given image, but may be -some point beyond the edge of the image. All points are floating point values. -

    - -

    Only the color channels defined by the -channel are -modified, which means that by default matte/alpha transparency channel is not -effected. Typically transparency channel is turned off either before or after -the operation.

    - -

    Of course if some color points are transparent to generate a transparent -gradient, then the image also requires transparency enabled to store the -values.

    - -

    All the above methods when given a single point of color will replace all -the colors in the image with the color given, regardless of the point. This is -logical, and provides an alternative technique to recolor an image to some -default value.

    - - -
    -

    -splice geometry

    -
    - -

    Splice the current background color into the image.

    - -

    This will add rows and columns of the current -background color into the given image according to the -given -gravity geometry setting. See Image Geometry for complete details about the geometry argument. Essentially -splice will divide the -image into four quadrants, separating them by the inserted rows and columns. -

    - -

    If a dimension of geometry is zero no rows or columns will be added for that -dimension. Similarly using a zero offset with the appropriate -gravity setting will add rows and columns to the edges of -the image, padding the image only along that one edge. Edge padding is what -splice is most commonly used for.

    - -

    If the exact same geometry and -gravity is later used with -chop the -added added all splices removed.

    - -
    -

    -spread amount

    -
    - -

    displace image pixels by a random amount.

    - -

    The argument amount defines the size of the -neighborhood around each pixel from which to choose a candidate pixel to -blend.

    - -

    The lookup is controlled by the -interpolate setting.

    - -
    -

    -statistic type geometry

    -
    - -

    replace each pixel with corresponding statistic from the neighborhood.

    - -

    Choose from these statistic types:

    -
    -
    Gradient
    maximum difference (max - min) value in neighborhood
    -
    Maximum
    maximum value per channel in neighborhood
    -
    Minimum
    minimum value per channel in neighborhood
    -
    Mean
    average value per channel in neighborhood
    -
    Median
    median value per channel in neighborhood
    -
    Mode
    mode (most frequent) value per channel in neighborhood
    -
    Nonpeak
    value just before or after the median value per channel in neighborhood
    -
    RMS
    root mean square value per channel in neighborhood
    -
    StandardDeviation
    standard deviation value per channel in neighborhood
    -
    - -
    -

    -stegano offset

    -
    - -

    hide watermark within an image.

    - -

    Use an offset to start the image hiding some number of pixels from the -beginning of the image. Note this offset and the image size. You will need -this information to recover the steganographic image (e.g. display -size -320x256+35 stegano:image.png).

    - -
    -

    -stereo +x{+y}

    -
    - -

    composite two images to create a red / cyan stereo anaglyph.

    - -

    The left side of the stereo pair (second image) is saved as the red channel of the output image. The right side (first image) is saved as the green and blue channels. Red-green stereo glasses are required to properly view the stereo image.

    - -
    -

    -storage-type type

    -
    - -

    pixel storage type. Here are the valid types:

    - -
    -
    char
    unsigned characters
    -
    double
    doubles
    -
    float
    floats
    -
    integer
    integers
    -
    long
    longs
    -
    quantum
    pixels in the native depth of your ImageMagick distribution
    -
    short
    unsigned shorts
    -
    - -

    Float and double types are normalized from 0.0 to 1.0 otherwise the pixels -values range from 0 to the maximum value the storage type can support.

    - -
    -

    -stretch fontStretch

    -
    - -

    Set a type of stretch style for fonts.

    - -

    This setting suggests a type of stretch that ImageMagick should try to -apply to the currently selected font family. Select fontStretch from the following.

    - -
    -Any
    -Condensed
    -Expanded
    -ExtraCondensed
    -ExtraExpanded
    -Normal
    -SemiCondensed
    -SemiExpanded
    -UltraCondensed
    -UltraExpanded
    -
    - -

    To print a complete list of stretch types, use -list -stretch.

    - -

    For other settings that affect fonts, see the options -font, -family, -style, and -weight.

    - -
    -

    -strip

    -
    - -

    strip the image of any profiles or comments.

    - -
    -

    -stroke color

    -
    - -

    color to use when stroking a graphic primitive.

    - -

    The color is specified using the format described under the -fill option.

    - -

    See -draw for further details.

    - -
    -

    -strokewidth value

    -
    - -

    set the stroke width.

    - -

    See -draw for further details.

    - -
    -

    -style fontStyle

    -
    - -

    Set a font style for text.

    - -

    This setting suggests a font style that ImageMagick should try to apply to -the currently selected font family. Select fontStyle from -the following.

    - -
    -Any
    -Italic
    -Normal
    -Oblique
    -
    - -

    For other settings that affect fonts, see the options -font, -family, -stretch, and -weight.

    - -
    -

    -subimage-search

    -
    - -

    search for subimage.

    - -

    This option is required to have compare search for the best match location -of a small image within a larger image. This search will produce two images -(or two frames). The first is the "difference" image and the second will -be the "match score" image.

    - -

    The "match-score" image is smaller containing a pixel for ever possible -position of the top-left corner of the given sub-image. that is its size will -be the size of the larger_image - sub_image + 1. The brightest location in -this image is the location s the locate on the best match that is also -reported. Note that this may or may not be a perfect match, and the actual -brightness will reflect this. Other bright 'peaks' can be used to locate other -possible matching locations.

    - -

    Note that the search will try to compare the sub-image at every possible -location in the larger image, as such it can be very slow. The smaller the -sub-image the faster this search is.

    - - -
    -

    -swap index,index

    -
    - -

    Swap the positions of two images in the image sequence.

    - -

    For example, -swap 0,2 swaps the first and the third -images in the current image sequence. Use +swap to switch -the last two images in the sequence.

    - -
    -

    -swirl degrees

    -
    - -

    swirl image pixels about the center.

    - -

    Degrees defines the tightness of the swirl.

    - -
    -

    -synchronize

    -
    - -

    synchronize image to storage device.

    - -

    Set to "true" to ensure all image data is fully flushed and synchronized -to disk. There is a performance penalty, but the benefits include ensuring a -valid image file in the event of a system crash and early reporting if there -is not enough disk space for the image pixel cache.

    - -
    -

    -taint

    -
    - -

    Mark the image as modified.

    - -
    -

    -text-font name

    -
    - -

    font for writing fixed-width text.

    - -

    Specifies the name of the preferred font to use in fixed (typewriter style) -formatted text. The default is 14 point Courier.

    - -

    You can tag a font to specify whether it is a PostScript, TrueType, or -OPTION1 font. For example, Courier.ttf is a TrueType font and -x:fixed is OPTION1.

    - -
    -

    -texture filename

    -
    - -

    name of texture to tile onto the image background.

    - -
    -

    -threshold value{%}

    -
    - - - -

    Apply simultaneous black/white threshold to the image.

    - -

    Any pixel values (more specifically, those channels set using ‑channel) that exceed the specified threshold are reassigned the -maximum channel value, while all other values are assigned the minimum.

    - -

    The threshold value can be given as a percentage or as an absolute integer -value corresponding to the desired channel value. When given as an integer, -the minimum attainable value is 0 (corresponding to black when all channels -are affected), but the maximum value (corresponding to white) is that of the -quantum depth of the particular build of ImageMagick, and is -therefore dependent on the installation. For that reason, a reasonable -recommendation for most applications is to specify the threshold values as -a percentage.

    - -

    The following would force pixels with red values above 50% to have 100% -red values, while those at or below 50% red would be set to 0 in the red -channel. The green, blue, and alpha channels (if present) would be unchanged. -

    - -
    -convert in.png -channel red -threshold 50% out.png
    -
    - -

    As (possibly) impractical but instructive examples, the following would -generate an all-black and an all-white image with the same dimensions as the -input image.

    - - -
    -convert in.png -threshold 100% black.png
    -convert in.png -threshold -1 white.png
    -
    - -

    Note that the values of the transparency channel is treated as 'matte' -values (0 is opaque) and not as 'alpha' values (0 is transparent).

    - -

    See also ‑black‑threshold and ‑white‑threshold. -

    - -
    -

    -thumbnail geometry

    -
    - -

    Create a thumbnail of the image.

    - -

    This is similar to -resize, except it is optimized -for speed and any image profile, other than a color profile, is removed to -reduce the thumbnail size. To strip the color profiles as well, add -strip just before of after this option.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -tile filename

    -
    - -

    Set the tile image used for filling a subsequent graphic primitive.

    - -
    -

    -tile geometry

    -
    - -

    Specify the layout of images.

    - -

    See Image Geometry for complete details about the geometry argument.

    - -
    -

    -tile

    -
    - -

    Specifies that a subsequent composite operation is repeated across and down image.

    - -
    -

    -tile-offset {+-}x{+-}y

    -
    - -

    Specify the offset for tile images, relative to the background image it is tiled on.

    - -

    This should be set before the tiling image is set by -tile or -texture, or directly applied for -creating a tiled canvas using TILE: or PATTERN: input -formats.

    - -

    Internally ImageMagick does a -roll of the tile image -by the arguments given when the tile image is set.

    - -
    -

    -tint value

    -
    - -

    Tint the image with the fill color.

    - -

    Tint the image with the fill color.

    - -

    Specify the amount of tinting as a percentage. Pure colors like black, -white red, yellow, will not be affected by -tint. Only mid-range colors such -as the various shades of grey.

    - -
    -

    -title string

    -
    - -

    Assign a title to displayed image.", "animate", "display", "montage

    - -

    Use this option to assign a specific title to the image. This assigned to -the image window and is typically displayed in the window title bar. -Optionally you can include the image filename, type, width, height, Exif data, -or other image attribute by embedding special format characters described -under the -format option.

    - -

    For example,

    - -
    --title "%m:%f %wx%h"
    -
    - -

    produces an image title of MIFF:bird.miff 512x480 for an image -titled bird.miff and whose width is 512 and height is 480.

    - - -
    -

    -transform

    -
    - -

    transform the image.

    - -

    This option applies the transformation matrix from a previous -affine option.

    - -
    -convert -affine 2,2,-2,2,0,0 -transform bird.ppm bird.jpg
    -
    - - -

    This operator has been now been superseded by the -distort 'AffineProjection' method.

    - - -
    -

    -transparent color

    -
    - -

    Make this color transparent within the image.

    - -

    The color argument is defined using the format -described under the -fill option. The -fuzz setting can be used to match and replace colors similar to the one -given.

    - -

    Use +transparent to invert the pixels matched. -that is make all non-matching colors transparent.

    - -

    The -opaque operator is exactly the same as -transparent but replaces the matching color with the -current -fill color setting, rather than transparent. -However the -transparent operator also ensures -that the image has an alpha channel enabled, as per "-alpha set", and does not require you to modify the -channel to enable alpha channel handling.

    - -

    Note that this does not define the color as being the 'transparency color' -used for color-mapped image formats, such as GIF. For that use -transparent-color

    - - -
    -

    -transparent-color color

    -
    - -

    Set the transparent color.

    - -

    Sometimes this is used for saving to image formats such as -GIF and PNG8 which uses this color to represent boolean transparency. This -does not make a color transparent, it only defines what color the transparent -color is in the color palette of the saved image. Use -transparent to make an opaque color transparent.

    - -

    This option allows you to have both an opaque visible color, as well as a -transparent color of the same color value without conflict. That is, you can -use the same color for both the transparent and opaque color areas within an -image. This, in turn, frees to you to select a transparent color that is -appropriate when an image is displayed by an application that does not handle a -transparent color index, while allowing ImageMagick to correctly handle images of this -type.

    - -

    The default transparent color is #00000000, which is fully transparent black.

    - -
    -

    -transpose

    -
    - -

    Mirror the image along the top-left to bottom-right diagonal.

    - -

    This option mathematically transposes the pixel array. It is equivalent to the sequence -flip -rotate 90. -

    - -
    -

    -transverse

    -
    - -

    Mirror the image along the images bottom-left top-right diagonal. Equivalent to the operations -flop -rotate 90.

    - - -
    -

    -treedepth value

    -
    - -

    tree depth for the color reduction algorithm.

    - -

    Normally, this integer value is zero or one. A value of zero or one causes -the use of an optimal tree depth for the color reduction algorithm.

    - -

    An optimal depth generally allows the best representation of the source -image with the fastest computational speed and the least amount of memory. -However, the default depth is inappropriate for some images. To assure the -best representation, try values between 2 and 8 for this parameter. Refer to -the color reduction algorithm for more details.

    - -

    The -colors or -monochrome -option, or writing to an image format which requires color reduction, is -required for this option to take effect.

    - -
    -

    -trim

    -
    - -

    trim an image.

    - -

    This option removes any edges that are exactly the same color as the corner -pixels. Use -fuzz to make -trim remove -edges that are nearly the same color as the corner pixels.

    - -

    The page or virtual canvas information of the image is preserved allowing -you to extract the result of the -trim operation from the -image. Use a +repage to remove the virtual canvas page -information if it is unwanted.

    - -

    If the trimmed image 'disappears' an warning is produced, and a special -single pixel transparent 'missed' image is returned, in the same way as when a --crop operation 'misses' the image proper.

    - - -
    -

    -type type

    -
    - -

    the image type.

    Choose from: Bilevel, -Grayscale, GrayscaleMatte, Palette, -PaletteMatte, TrueColor, TrueColorMatte, -ColorSeparation, or ColorSeparationMatte.

    - -

    Normally, when a format supports different subformats such as grayscale and -truecolor, the encoder will try to choose an efficient subformat. The -type option can be used to override this behavior. For -example, to prevent a JPEG from being written in grayscale format even though -only gray pixels are present, use.

    - -
    -convert bird.png -type TrueColor bird.jpg
    -
    - -

    Similarly, use -type TrueColorMatte to force the -encoder to write an alpha channel even though the image is opaque, if the -output format supports transparency.

    - -

    Use -type optimize to ensure the image is written in the smallest possible file size.

    - -
    -

    -undercolor color

    -
    - -

    set the color of the annotation bounding box.

    - -

    The color is specified using the format described under the -fill option.

    - -

    See -draw for further details.

    - - -
    -

    -update seconds

    -
    - -

    detect when image file is modified and redisplay.

    - -

    Suppose that while you are displaying an image the file that is currently -displayed is over-written. display will automagically detect that -the input file has been changed and update the displayed image -accordingly.

    - - -
    -

    -unique-colors

    -
    - -

    discard all but one of any pixel color.

    - - -
    -

    -units type

    -
    - -

    the units of image resolution.

    - -

    Choose from: Undefined, PixelsPerInch, or -PixelsPerCentimeter. This option is normally used in conjunction -with the -density option.

    - - -
    -

    -unsharp radius
    -unsharp radiusxsigma{+gain}{+threshold}

    -
    - -

    sharpen the image with an unsharp mask operator.

    - -

    The -unsharp option sharpens an image. The image is -convolved with a Gaussian operator of the given radius and standard deviation -(sigma). For reasonable results, radius should be larger than sigma. Use -a radius of 0 to have the method select a suitable radius.

    - -

    The parameters are:

    - -
    -
    radius
    -
    The radius of the Gaussian, in pixels, not counting the center pixel (default 0).
    -
    sigma
    -
    The standard deviation of the Gaussian, in pixels (default 1.0).
    -
    gain
    -
    The fraction of the difference between the original and the blur image that is added back into the original (default 1.0).
    -
    threshold
    -
    The threshold, as a fraction of QuantumRange, needed to apply the difference amount (default 0.05).
    -
    - -
    -

    -verbose

    -
    - -

    print detailed information about the image when this option precedes the -identify option or info:.

    - - -
    -

    -version

    -
    - -

    print ImageMagick version string and exit.

    - - -
    -

    -view string

    -
    - -

    FlashPix viewing parameters.

    - - -
    -

    -vignette radius{xsigma}{+-}x{+-}y{%}

    -
    - -

    soften the edges of the image in vignette style.

    - -

    The vignette effect rolloff is controlled by radiusxsigma. For nominal rolloff, this would be set to 0xsigma. A value of 0x0 will produce a circle/ellipse with no rolloff. The arguments x and y control the size of the circle. Larger values decrease the radii and smaller values increase the radii. Values of +0+0 will generate a circle/ellipse the same size as the image. The default values for x and y are 10% of the corresponding image dimension. Thus, the radii will be decreased by 10%, i.e., the diameters of the circle/ellipse will be 80% of the corresponding image dimension.

    - -
    -

    -virtual-pixel method

    -
    - -

    Specify contents of virtual pixels.

    - -

    This option defines what color source should be used if and when a color -lookup completely 'misses' the source image. The color(s) that appear to -surround the source image. Generally this color is derived from the source -image, but could also be set to a specify background color.

    - -

    Choose from these methods:

    - -
    -
    background
    the area surrounding the image is the background color
    -
    black
    the area surrounding the image is black
    -
    checker-tile
    alternate squares with image and background color
    -
    dither
    non-random 32x32 dithered pattern
    -
    edge
    extend the edge pixel toward infinity
    -
    gray
    the area surrounding the image is gray
    -
    horizontal-tile
    horizontally tile the image, background color above/below
    -
    horizontal-tile-edge
    horizontally tile the image and replicate the side edge pixels
    -
    mirror
    mirror tile the image
    -
    random
    choose a random pixel from the image
    -
    tile
    tile the image (default)
    -
    transparent
    the area surrounding the image is transparent blackness
    -
    vertical-tile
    vertically tile the image, sides are background color
    -
    vertical-tile-edge
    vertically tile the image and replicate the side edge pixels
    -
    white
    the area surrounding the image is white
    -
    - -

    The default value is "edge".

    - -

    This most important for distortion operators such as -distort, -implode, and -fx. -However it also effects operations that may access pixels just outside the -image proper, such as -convolve, -blur, and -sharpen.

    - -

    To print a complete list of virtual pixel types, use the -list virtual-pixel option.

    - - -
    -

    -visual type

    -
    - -

    Animate images using this X visual type.", 'animate', 'display'

    - -

    Choose from these visual classes:

    - -
    -StaticGray    TrueColor
    -GrayScale     DirectColor
    -StaticColor   default
    -PseudoColor   visual id
    -
    - -

    The X server must support the visual you choose, otherwise an error occurs. -If a visual is not specified, the visual class that can display the most -simultaneous colors on the default screen is chosen.

    - - -
    -

    -watermark brightnessxsaturation

    -
    - -

    Watermark an image using the given percentages of brightness and saturation.

    - -

    Take a grayscale image (with alpha mask) and modify the destination image's -brightness according to watermark image's grayscale value and the -brightness percentage. The destinations color saturation -attribute is just direct modified by the saturation -percentage, which defaults to 100 percent (no color change).

    - - -
    -

    -wave amplitude
    -wave amplitudexwavelength

    -
    - -

    Shear the columns of an image into a sine wave.

    - -

    Specify amplitude and wavelength -of the wave.

    - -
    -

    -weight fontWeight

    -
    - -

    Set a font weight for text.

    - -

    This setting suggests a font weight that ImageMagick should try to apply to -the currently selected font family. Use a positive integer for -fontWeight or select from the following.

    - -
    -
    Thin
    -
    Same as fontWeight = 100.
    -
    ExtraLight
    -
    Same as fontWeight = 200.
    -
    Light
    -
    Same as fontWeight = 300.
    -
    Normal
    -
    Same as fontWeight = 400.
    -
    Medium
    -
    Same as fontWeight = 500.
    -
    DemiBold
    -
    Same as fontWeight = 600.
    -
    Bold
    -
    Same as fontWeight = 700.
    -
    ExtraBold
    -
    Same as fontWeight = 800.
    -
    Heavy
    -
    Same as fontWeight = 900.
    -
    -
    - -

    To print a complete list of weight types, use -list weight.

    - -

    For other settings that affect fonts, see the options -font, -family, -stretch, and -style.

    - -
    -

    -white-point x,y

    -
    - -

    chromaticity white point.

    - -
    -

    -white-threshold value{%}

    -
    - -

    Force to white all pixels above the threshold while leaving all pixels at or below the threshold unchanged.

    - -

    The threshold value can be given as a percentage or as an absolute integer -value within [0, QuantumRange] corresponding to the -desired ‑channel value. See ‑thresholdfor more details on thresholds and resulting values.

    - -
    -

    -window id

    -
    - -

    Make the image the background of a window.", 'animate', 'display'

    - -

    id can be a window id or name. Specify root -to select X's root window as the target window.

    - -

    By default the image is tiled onto the background of the target window. If -backdrop or -resize are specified, the -image is surrounded by the background color. Refer to X RESOURCES -for details.

    - -

    The image will not display on the root window if the image has more unique -colors than the target window colormap allows. Use -colors to reduce the number of colors.

    - -
    -

    -window-group

    -
    - -

    specify the window group.

    - -
    -

    -write filename

    -
    - -

    write an image sequence.

    - -

    The image sequence preceding the -write filename option is written out, and processing continues with the same image in its current state if there are additional options. To restore the image to its original state after writing it, use the +write filename option.

    - -

    Use -compress to specify the type of image compression.

    -
    -
    - - - - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/command-line-processing.html b/ImageMagick-7.0.0-0/www/command-line-processing.html deleted file mode 100644 index 8e87ce80b..000000000 --- a/ImageMagick-7.0.0-0/www/command-line-processing.html +++ /dev/null @@ -1,664 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Processing - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    The Anatomy of the Command-line • Input Filename • Image Setting • Image Operator • Image Sequence Operator • Image Geometry • Image Stack • Output Filename

    - -

    The ImageMagick command-line can be as simple as this:

    - -
    -convert image.jpg image.png
    -
    - -

    Or it can be complex with a plethora of options, as in the following:

    - -
    -convert label.gif +matte \
    -  \( +clone  -shade 110x90 -normalize -negate +clone  -compose Plus -composite \) \
    -  \( -clone 0 -shade 110x50 -normalize -channel BG -fx 0 +channel -matte \) \
    -  -delete 0 +swap  -compose Multiply -composite  button.gif");
    -
    - -

    This example command is long enough that the command must be written across several lines, so we formatted it for clarity by inserting backslashes (\). The backslash is the Unix line-continuation character. In the Windows shell, use a carat character (^) for line-continuation. We use the Unix style on these web pages, as above. Sometimes, however, the lines are wrapped by your browser if the browser window is small enough, but the command-lines, shown in white, are still intended to be typed as one line. Line continuation characters need not be entered. The parentheses that are escaped above using the backslash are not escaped in Windows. There are some other differences between Windows and Unix (involving quotation marks, for instance), but we'll discuss some of those issues later, as they arise.

    - -

    Without knowing much about the ImageMagick command-line, you can probably surmise that the first command above converts an image in the JPEG format to one in the PNG format. However, very few may realize the second, more complex command, gives a flat two-dimensional label a three-dimensional look with rich textures and simulated depth:

    - - - - -

    Here we show percent completion of a task as a shaded cylinder:

    - -
      - Shaded Cylinder -
    - -

    Given the complexity of the rendering, you might be surprised it is accomplished by a single command-line:

    - -
    -convert -size 320x90 canvas:none -stroke snow4 -size 1x90 -tile gradient:white-snow4 \
    -  -draw 'roundrectangle 16, 5, 304, 85 20,40' +tile -fill snow \
    -  -draw 'roundrectangle 264, 5, 304, 85  20,40' -tile gradient:chartreuse-green \
    -  -draw 'roundrectangle 16,  5, 180, 85  20,40' -tile gradient:chartreuse1-chartreuse3 \
    -  -draw 'roundrectangle 140, 5, 180, 85  20,40' +tile -fill none \
    -  -draw 'roundrectangle 264, 5, 304, 85 20,40' -strokewidth 2 \
    -  -draw 'roundrectangle 16, 5, 304, 85 20,40' \( +clone -background snow4 \
    -  -shadow 80x3+3+3 \) +swap -background none -layers merge \( +size -font Helvetica \
    -  -pointsize 90 -strokewidth 1 -fill red label:'50 %' -trim +repage \( +clone \
    -  -background firebrick3 -shadow 80x3+3+3 \) +swap -background none -layers merge \) \
    -  -insert 0 -gravity center -append -background white -gravity center -extent 320x200 \
    -  cylinder_shaded.png
    -
    - -

    In the next sections we dissect the anatomy of the ImageMagick command-line. Hopefully, after carefully reading and better understanding how the command-line works, you should be able to accomplish complex image-processing tasks without resorting to the sometimes daunting program interfaces.

    - -

    See Examples of ImageMagick Usage for additional help when using ImageMagick from the command-line.

    - -

    The Anatomy of the Command-line

    -

    The ImageMagick command-line consists of

    - -
      -
    1. one or more required input filenames.
    2. -
    3. zero, one, or more image settings.
    4. -
    5. zero, one, or more image operators.
    6. -
    7. zero, one, or more image sequence operators.
    8. -
    9. zero, one, or more image stacks.
    10. -
    11. zero or one output image filenames (required by -convert, -composite, -montage, -compare, -import, -conjure). -
    12. -
    - -

    You can find a detailed explanation of each of the constituent parts of the command-line in the sections that follow.

    - -

    Input Filename

    - -

    ImageMagick extends the concept of an input filename to include:

    -
      -
    • filename globbing
    • -
    • an explicit image format
    • -
    • using built-in images and patterns
    • -
    • STDIN, STDOUT, and file descriptors
    • -
    • selecting certain frames from an image
    • -
    • selecting a region of an image
    • -
    • forcing an inline image resize
    • -
    • forcing an inline image crop
    • -
    • using filename references
    • -
    - -

    These extensions are explained in the next few paragraphs.

    - -

    Filename Globbing

    -

    In Unix shells, certain characters such as the asterisk (*) and question mark (?) automagically cause lists of filenames to be generated based on pattern matches. This feature is known as globbing. ImageMagick supports filename globbing for systems, such as Windows, that does not natively support it. For example, suppose you want to convert 1.jpg, 2.jpg, 3.jpg, 4.jpg, and 5.jpg in your current directory to a GIF animation. You can conveniently refer to all of the JPEG files with this command: -

    - -
    -convert *.jpg images.gif
    -
    - -

    Explicit Image Format

    -

    Images are stored in a myriad of image formats including -the better known JPEG, PNG, TIFF and others. ImageMagick must know the format -of the image before it can be read and processed. Most formats have a -signature within the image that uniquely identifies the format. Failing -that, ImageMagick leverages the filename extension to determine the format. -For example, image.jpg or image.JPG tells ImageMagick -it is reading an image in the JPEG format.

    - -

    In some cases the image may not contain a signature -and/or the filename does not identify the image format. In these cases an -explicit image format must be specified. For example, suppose our image -is named image and contains raw red, green, and blue intensity -values. ImageMagick has no way to automagically determine the image format -so we explicitly set one: -

    - -
    -convert -size 640x480 -depth 8 rgb:image image.png
    -
    - -

    Built-in Images and Patterns

    - -

    ImageMagick has a number of built-in images and patterns. To utilize the checkerboard pattern, for example, use: -

    - -
    -convert -size 640x480 pattern:checkerboard checkerboard.png
    -
    - -

    STDIN, STDOUT, and file descriptors

    -

    Unix and Windows permit the output of one command to be piped to the input of another. ImageMagick permits image data to be read and written from the standard streams STDIN (standard in) and STDOUT (standard out), respectively, using a pseudo-filename of -. In this example we pipe the output of - convert to the display program: -

    - -
    -convert logo: gif:- | display gif:-
    -
    - -

    The second explicit format "gif:" is optional in the preceding example. The GIF image format has a unique signature within the image so ImageMagick's display command can readily recognize the format as GIF. The convert program also accepts STDIN as input in this way: -

    - -
    -convert rose: gif:- | convert - -resize "200%" bigrose.jpg'
    -
    - -

    Other pipes can be accessed via their file descriptors (as of version 6.4.9-3). The file descriptors 0, 1, and 2 are reserved for the standard streams STDIN, STDOUT, and STDERR, respectively, but a pipe associated with a file descriptor number N>2 can be accessed using the pseudonym fd:N. (The pseudonyms fd:0 and fd:1 can be used for STDIN and STDOUT.) The next example shows how to append image data piped from files with descriptors 3 and 4 and direct the result to the file with descriptor number 5. -

    - -
    -convert fd:3 fd:4 -append fd:5
    -
    - -

    When needed, explicit image formats can be given as mentioned earlier, as in the following. -

    - -
    -convert gif:fd:3 jpg:fd:4 -append tif:fd:5
    -
    - -

    Selecting Frames

    -

    Some images formats contain more than one image frame. Perhaps you only want the first image, or the last, or some number of images in-between. You can specify which image frames to read by appending the image filename with the frame range enclosed in brackets. Here our image (an animated GIF) contains more than one frame but we only want the first: -

    - -
    -convert 'images.gif[0]' image.png
    -
    - -

    Unix shells generally interpret brackets so we enclosed the filename in quotes above. -In a Windows command shell the brackets are not interpreted but using quotes doesn't hurt. However, in most cases the roles of single-quotes and double-quotes are reversed with respect to Unix and Windows, so Windows users should usually try double-quotes where we display single-quotes, and vice versa. -

    - -

    You can read more than one image from a sequence with a frame range. For example, you can extract the first four frames of an image sequence: -

    - -
    -convert 'images.gif[0-3]' images.mng
    -
    - -

    Finally, you can read more than one image from a sequence, out-of-order. The next command gets the third image in the sequence, followed by the second, and then the fourth: -

    - -
    -convert 'images.gif[3,2,4]' images.mng
    -
    - -

    Notice that in the last two commands, a single image is written. The output in this case, where the image type is MNG, is a multi-frame file because the MNG format supports multiple frames. Had the output format been JPG, which only supports single frames, the output would have consisted of separate frames. More about that below, in the section about the Output Filename. -

    - -

    Selecting an Image Region

    -

    Raw images are a sequence of color intensities without additional meta information such as width, height, or image signature. With raw image formats, you must specify the image width and height but you can also specify a region of the image to read. In our example, the image is in the raw 8-bit RGB format and is 6000 pixels wide and 4000 pixels high. However, we only want a region of 600 by 400 near the center of the image: -

    - -
    -convert -size 6000x4000 -depth 8 \
    -  'rgb:image[600x400+1900+2900]' image.jpg
    -
    - -

    - You can get the same results with the ‑extract option: -

    - -
    -convert -size 6000x4000 -depth 8 \
    -  -extract 600x400+1900+2900 rgb:image image.jpg
    -
    - -

    Inline Image Resize

    -

    It is sometimes convenient to resize an image as they are read. Suppose you have hundreds of large JPEG images you want to convert to a sequence of PNG thumbails: -

    - -
    -convert '*.jpg' -resize 120x120 thumbnail%03d.png
    -
    - -

    Here all the images are read and subsequently -resized. It is faster and less resource intensive to resize each image it -is read: -

    - -
    -convert '*.jpg[120x120]' thumbnail%03d.png
    -
    - -

    Inline Image Crop

    -

    It is sometimes convenient to crop an image as they are read. Suppose you have hundreds of large JPEG images you want to convert to a sequence of PNG thumbails: -

    - -
    -convert '*.jpg' -crop 120x120+10+5 thumbnail%03d.png
    -
    - -

    Here all the images are read and subsequently cropped. It is faster and less resource-intensive to crop each image as it is read: -

    - -
    -convert '*.jpg[120x120+10+5]' thumbnail%03d.png
    -
    - - -

    Filename References

    - -

    There are two methods to use a filename to reference other image filenames. -The first is with '@' which reads image filenames separated by white space from the specified file. Assume the file myimages.txt consists of a list of filenames, like so: -

    - -
    -frame001.jpg
    -frame002.jpg
    -frame003.jpg
    -
    - -

    We then expect this command:

    - -
    -convert @myimages.txt mymovie.gif
    -
    - -

    to read the images frame001.jpg, frame002.jpg, and frame003.jpg and convert them to a GIF image sequence.

    -

    If the image path includes one or more spaces, enclose the path in quotes:

    -
    -'my title.jpg'
    -
    - - -

    Some ImageMagick command-line options may exceed the capabilities of -your command-line processor. Windows, for example, limits command-lines -to 8192 characters. If, for example, you have a draw option with polygon -points that exceed the command-line length limit, put the draw option instead -in a file and reference the file with -the @ (e.g. @mypoly.txt).

    - -

    Another method of referring to other image files is by -embedding a formatting character in the filename with a scene range. Consider -the filename image-%d.jpg[1-5]. The command

    - -
    -convert image-%d.jpg[1-5]
    -
    - -

    causes ImageMagick to attempt to read images with these filenames: -

    - -
    -image-1.jpg
    -image-2.jpg
    -image-3.jpg
    -image-4.jpg
    -image-5.jpg
    -
    - -

    Stream Buffering

    -

    By default, the input stream is buffered. To ensure information on the source file or terminal is read as soon as its available, set the buffer size to 0:

    - -
    -convert logo: gif:- | display -define stream:buffer-size=0 gif:-
    -
    - -

    Image Setting

    - -

    An image setting persists as it appears on the command-line and may affect -subsequent processing such as reading an image, an image operator, or when -writing an image as appropriate. An image setting stays in effect until it -is reset or the command-line terminates. The image settings include:

    - - - -

    In this example, -channel applies to each of the images, since, as we mentioned, settings persist: -

    - -
    -convert -channel RGB wand.png wizard.png images.png
    -
    - -

    Image Operator

    - -

    An image operator differs from a setting in that it affects the image -immediately as it appears on the command-line. An operator is -any command-line option not listed as a -image setting or -image sequence operator. Unlike an -image setting, which persists until the command-line terminates, -an operator is applied to an image and forgotten. The image operators -include:

    - - - -

    In this example, -negate negates the wand image but not the wizard:

    - -
    -convert wand.png -negate wizard.png images.png
    -
    - -

    Image Sequence Operator

    - -

    An image sequence operator differs from a setting in that it affects an -image sequence immediately as it appears on the command-line. Choose from -these image sequence operators:

    - - - -

    Image Geometry

    - -

    Many command-line options take a geometry argument -to specify such things as the desired width and height of an image and other -dimensional quantities. Because users want so many variations on the resulting -dimensions, sizes, and positions of images (and because ImageMagick wants to -provide them), the geometry argument can take many -forms. We describe many of these in this section.

    - -

    The image options and settings that take some form of -a geometry argument include the following. -Keep in mind that some of these parse their arguments in slightly -different ways. See the documentation for the individual option or -setting for more specifics.

    - - - -

    The geometry argument might take any of the forms listed in the table below. These will described in more detail in the subsections following the table. The usual form is size[offset], meaning size is required and offset is optional. Occasionally, [size]offset is possible. In no cases are spaces permitted within the geometry argument.

    - - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    sizeGeneral description (actual behavior can vary for different options and settings)
    scale%Height and width both scaled by specified percentage.
    scale-x%xscale-y%Height and width individually scaled by specified percentages. (Only one % symbol needed.)
    widthWidth given, height automagically selected to preserve aspect ratio.
    xheightHeight given, width automagically selected to preserve aspect ratio.
    widthxheightMaximum values of height and width given, aspect ratio preserved.
    widthxheight^Minimum values of width and height given, aspect ratio preserved.
    widthxheight!Width and height emphatically given, original aspect ratio ignored.
    widthxheight>Shrinks an image with dimension(s) larger than the corresponding width and/or height argument(s).
    widthxheight<Enlarges an image with dimension(s) smaller than the corresponding width and/or height argument(s).
    area@Resize image to have specified area in pixels. Aspect ratio is preserved.
    {size}{offset}Specifying the offset (default is +0+0). Below, {size} refers to any of the forms above.
    {size}{+-}x{+-}yHorizontal and vertical offsets x and y, specified in pixels. Signs are required for both. Offsets are affected by ‑gravity setting. Offsets are not affected by % or other size operators.
    - - -

    Basic adjustments to width and height; the operators %, ^, and !

    -

    Here, just below, are a few simple examples of geometry, showing how it might be used as an argument to the ‑resize option. We'll use the internal image logo: for our input image. - -This fine image is 640 pixels wide and 480 pixels high. We say its dimensions are 640x480. When we give dimensions of an image, the width (the horizontal dimension) always precedes the height (the vertical dimension). This will be true when we speak of coordinates or offsets into an image, which will always be x–value followed by y. Just think of your high school algebra classes and the xy–plane. (Well, almost: our y–axis will always go downward!) -

    - -
    -convert logo: -resize '200%' bigWiz.png
    -convert logo: -resize '200x50%' longShortWiz.png
    -convert logo: -resize '100x200' notThinWiz.png
    -convert logo: -resize '100x200^' biggerNotThinWiz.png
    -convert logo: -resize '100x200!' dochThinWiz.png
    -
    - -

    The first of the four commands is simple—it stretches both the width and height of the input image by 200% in each direction; it magnifies the whole thing by a factor of two. The second command specifies different percentages for each direction, stretching the width to 200% and squashing the height to 50%. The resulting image (in this example) has dimensions 1280x240. Notice that the percent symbol needn't be repeated; the following are equivalent: 200x50%, 200%x50, 200%x50%. -

    - -

    By default, the width and height given in a geometry argument are maximum values unless a percentage is specified. That is, the image is expanded or contracted to fit the specified width and height value while maintaining the aspect ratio (the ratio of its height to its width) of the image. For instance, the third command above "tries" to set the dimensions to 100x200. Imagine gradually shrinking the original image (which is 640x480), keeping is aspect ratio constant, until it just fits into a 100x200 rectangle. Since the image is longer than it is tall, it will fit when its width shrinks to 100 pixels. To preserve the aspect ratio, the height will therefore have to be (480/640)×100 pixels=75 pixels, so the final dimensions will be 100x75.

    - -

    Notice that in the previous example, at least one of the specified dimensions will be attained (in this case, the width, 100 pixels). The resulting image fits snugly within the original. One can do just the opposite of this by invoking the ^ operator, as in the fourth example above. In that case, when 100x200^ is given as the argument, again at least one of the dimensions will be attained, but in this case the resulting image can snugly contain the original. Here the geometry argument gives minimum values. In our example, the height will become 200 and the width will be scaled to preserve the aspect ratio, becoming (640/480)×200 pixels=267 pixels. With the ^ operator, one of those dimensions will match the requested size, but the image will likely overflow the dimensions requested to preserve its aspect ratio. (The ^ feature is new as of IM 6.3.8-2.)

    - -

    We see that ImageMagick is very good about preserving aspect ratios of images, to prevent distortion of your favorite photos and images. But you might really want the dimensions to be 100x200, thereby stretching the image. In this case just tell ImageMagick you really mean it (!) by appending an exclamation operator to the geometry. This will force the image size to exactly what you specify. So, for example, if you specify 100x200! the dimensions will become exactly 100x200 (giving a small, vertically elongated wizard).

    - -

    Bounding the width, height, and area; the operators >, <, and @

    -

    -Here are a few more examples: -

    - -
    -convert logo: -resize '100' wiz1.png
    -convert logo: -resize 'x200' wiz2.png
    -convert logo: -resize '100x200>' wiz3.png
    -convert logo: -resize '100x200<' wiz4.png
    -
    - -

    If only one dimension is given it is taken to be the width. When only the width is specified, as in the first example above, the width is accepted as given and the height is chosen to maintain the aspect ratio of the input image. Similarly, if only the height is specified, as in the second example above, the height is accepted and the width is chosen to maintain the aspect ratio.

    - - -

    Use > to shrink an image only if its dimension(s) are larger than the corresponding width and/or height arguments. Use < to enlarge an image only if its dimension(s) are smaller than the corresponding width and/or height arguments. In either case, if a change is made, the result is as if the > or < operator was not present. So, in the third example above, we specified 100x200> and the original image size is 640x480, so the image size is reduced as if we had specified 100x200. However, in the fourth example above, there will be no change to its size.

    - -

    Finally, use @ to specify the maximum area in pixels of an image, again while attempting to preserve aspect ratio. (Pixels take only integer values, so some approximation is always at work.) In the following example, an area of 10000 pixels is requested. The resulting file has dimensions 115x86, which has 9890 pixels.

    - -
    -convert logo: -resize '@10000' wiz10000.png
    -
    - -

    In all the examples above and below, we have enclosed the geometry arguments within quotation marks. Doing so is optional in many cases, but not always. We must enclose the geometry specifications in quotation marks when using < or > to prevent these characters from being interpreted by the shell as file redirection. On Windows systems, the carat ^ needs to be within quotes, else it is ignored. To be safe, one should probably maintain a habit of enclosing all geometry arguments in quotes, as we have here. -

    - -

    Offsets in geometry

    -

    -Here are some examples to illustrate the use of offsets in geometry arguments. One typical use of offsets is in conjunction with the -‑region option. This option allows many other options to modify the pixels within a specified rectangular subregion of an image. As such, it needs to be given the width and height of that region, and also an offset into the image, which is a pair of coordinates that indicate the location of the region within the larger image. Below, in the first example, we specify a region of size 100x200 to be located at the xy–coordinates x=10, y=20. Let's use the usual algebraic notation (x,y)=(10,20), for convenience. -

    - -
    -convert logo: -region '100x200+10+20' -negate wizNeg1.png
    -convert logo: -region '100x200-10+20' -negate wizNeg2.png
    -convert logo: -gravity center -region '100x200-10+20' \
    -  -negate wizNeg3.png
    -
    - -

    Note that offsets always require +/− signs. The offset is not actually a true location within the image; its coordinates must be added to some other location. Let's refer to that as the current location. In the first two examples above, though, that location is the upper-left hand corner of the image, which has coordinates (0,0). (That is the default situation when there are no other directives given to change it.) The first example above puts the 100x200 rectangle's own upper-left corner at (10,20).

    - -

    A negative offset can make sense in many cases. In the second example above, the offset is (-10,20), specified by -10+20. In that case, only the portion of the (virtual) rectangle obtained that lies within the image can be negated; here it is equivalent to specifying the geometry as 90x200+0+20.

    - -

    In the third example above, the ‑gravity setting precedes the others and sets the current location within the image at the very center of the image. In this case that is at pixel (320,240), since the size of the image is 640x480. This means that the offsets apply to that location, which thereby gets moved, in this case, to (320-10,240+20)=(310,260). But the 100x200 region itself is affected by the ‑gravity setting, so instead of affecting its upper-left corner, the region's own center (at (+50,+100) within it) is determined. Therefore the center of the 100x200 rectangle is moved to (310,260). The negated rectangle's upper-left corner is now at (310-50,260-100)=(260,160). -

    - - -

    Image Stack

    - -

    In school, your teacher probably permitted you to work on problems on a scrap of paper and then copy the results to your test paper. An image stack is similar. It permits you to work on an image or image sequence in isolation and subsequently introduce the results back into the command-line. The image stack is delineated with parenthesis. Image operators only affect images in the current stack. For example, we can limit the image rotation to just the wizard image like this:

    - -
    -convert wand.gif \( wizard.gif -rotate 30 \) +append images.gif
    -
    - - -

    Notice again that the parentheses are escaped by preceding them with -backslashes. This is required under Unix, where parentheses are special -shell characters. The backslash tells the shell not to interpret -these characters, but to pass them directly to the command being executed. Do -not escape the parentheses under Windows. Each parenthesis (or escaped -parenthesis) must have spaces on either side, as in the example shown -above.

    - -

    In addition to the image operators already discussed, the following image operators are most useful when processing images in an image stack:

    - - - -

    The arguments to these operators are indexes into the image sequence by number, starting with zero, for the first image, and so on. However if you give a negative index, the images are indexed from the end (last image added). That is, an index of -1 is the last image in the current image sequence, -2 gives the second-to-last, and so on.

    - -

    Output Filename

    - -

    ImageMagick extends the concept of an output filename to include:

    - -
      -
    1. an explicit image format
    2. -
    3. write to standard out
    4. -
    5. filename references
    6. -
    - -

    Each of these extensions are explained in the next few paragraphs.

    - -

    Explicit Image Format

    -

    Images can be stored in a mryiad of image formats including the better known JPEG, PNG, TIFF and others. ImageMagick must know the desired format of the image before it is written. ImageMagick leverages the filename extension to determine the format. For example, image.jpg tells ImageMagick to write the image in the JPEG format. In some cases the filename does not identify the image format. In these cases, the image is written in the format it was originally read unless an explicit image format is specified. For example, suppose we want to write our image to a filename of image in the raw red, green, and blue intensity format: -

    - -
    -convert image.jpg rgb:image
    -
    - - -

    Standard Out

    -

    Unix permits the output of one command to be piped to another. ImageMagick permits piping one command to another with a filename of -. In this example we pipe the output of convert to the display program: -

    - -
    -convert logo: gif:- | display gif:-
    -
    - -

    Here the explicit format is optional. The GIF image format has a signature that uniquely identifies it so ImageMagick can readily recognize the format as GIF.

    - -

    Filename References

    -

    Optionally, use an embedded formatting character to write a sequential image list. Suppose our output filename is image-%d.jpg and our image list includes 3 images. You can expect these images files to be written: -

    - -
    -image-0.jpg
    -image-1.jpg
    -image-2.jpg
    -
    - -

    Or retrieve image properties to modify the image filename. For example, the command -

    - -
    -convert rose: -set filename:area '%wx%h' 'rose-%[filename:area].png'
    -
    - -

    writes an image with this filename: -

    - -
    -  rose-70x46.png
    -
    - -

    Finally to convert multiple JPEG images to individual PDF pages, use:

    - -
    -  convert *.jpg +adjoin page-%d.pdf
    -
    - -

    Stream Buffering

    - -

    By default, the output stream is buffered. To ensure information appears on the destination file or terminal as soon as written, set the buffer size to 0:

    - -
    -convert -define stream:buffer-size=0 logo: gif:- | display gif:-
    -
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/command-line-tools.html b/ImageMagick-7.0.0-0/www/command-line-tools.html deleted file mode 100644 index 65e01ac6f..000000000 --- a/ImageMagick-7.0.0-0/www/command-line-tools.html +++ /dev/null @@ -1,94 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    ImageMagick includes a number of command-line utilities for manipulating images. Most of you are probably accustomed to editing images one at a time with a graphical user interface (GUI) with such programs as gimp or Photoshop. However, a GUI is not always convenient. Suppose you want to process an image dynamically from a web script or you want to apply the same operations to many images or repeat a specific operation at different times to the same or different image. For these types of operations, the command-line image processing utility is appropriate.

    - -

    The ImageMagick command-line tools exit with a status of 0 if the command line arguments have a proper syntax and no problems are encountered. Expect a descriptive message and an exit status of 1 if any exception occurs such as improper syntax, a problem reading or writing an image, or any other problem that prevents the command from completing successfully.

    - -

    Here is a short description for each command-line tool. Click on the program name to get details about the program usage and a list of command-line options that alters how the program behaves. If you are just getting acquainted with ImageMagick, start with the convert program. Be sure to peruse Anthony Thyssen's tutorial on how to use ImageMagick utilities to create, edit, compose, or convert images from the command-line.

    - -
    -
    animate
    animate an image sequence on any X server.
    -
    compare
    mathematically and visually annotate the difference between an image and its reconstruction.
    -
    composite
    overlap one image over another.
    -
    conjure
    interpret and execute scripts written in the Magick Scripting Language (MSL).
    -
    convert
    convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more.
    -
    display
    display an image or image sequence on any X server.
    -
    identify
    describe the format and characteristics of one or more image files.
    -
    import
    save any visible window on an X server and outputs it as an image file. You can capture a single window, the entire screen, or any rectangular portion of the screen.
    -
    mogrify
    resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more. Mogrify overwrites the original image file, whereas, convert writes to a different image file.
    -
    montage
    create a composite image by combining several separate images. The images are tiled on the composite image optionally adorned with a border, frame, image name, and more.
    -
    stream
    a lightweight tool to stream one or more pixel components of the image or portion of the image to your choice of storage formats. It writes the pixel components as they are read from the input image a row at a time making stream desirable when working with large images or when you require raw pixel components.
    -
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/compare.html b/ImageMagick-7.0.0-0/www/compare.html deleted file mode 100644 index 9ac2a6a37..000000000 --- a/ImageMagick-7.0.0-0/www/compare.html +++ /dev/null @@ -1,346 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Compare - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    Use the compare program to mathematically and visually annotate the difference between an image and its reconstruction. See Command Line Processing for advice on how to structure your compare command or see below for example usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the compare command here to illustrate its usefulness and ease of use. To get started, lets compare an image to one thats been sharpened:

    - -
    -convert rose.jpg -sharpen 0x1 reconstruct.jpg
    -compare rose.jpg reconstruct.jpg difference.png
    -compare -compose src rose.jpg reconstruct.jpg difference.png
    -
    - -
      - rose - rose - ==> - rose -
    - -

    The red areas of the difference image emphasizes (highlight) pixels that are affected by the image sharpening, whereas white de-emphasizes (lowlight) pixels that are untouched by the sharpening process.

    - -

    In addition to the visual interpretation of the difference in an image and its reconstruction, we report a mathematical measure of the difference:

    - -
    --> compare -verbose -metric mae rose.jpg reconstruct.jpg difference.png
    -Image: rose.jpg
    - Channel distortion: MAE
    -  red: 2282.91 (0.034835)
    -  green: 1853.99 (0.0282901)
    -  blue: 2008.67 (0.0306503)
    -  all: 1536.39 (0.0234439)
    -
    -

    Or, if you just want the red channel distortion, use this command:

    - -
    --> compare -channel red -metric PSNR rose.jpg reconstruct.jpg difference.png
    -19.63
    -
    - -

    Or, if you just want the overall image distortion, use this command:

    - -
    --> compare -metric PSNR rose.jpg reconstruct.jpg difference.png
    -28.31
    -
    - -

    If the reconstructed image is a subimage of the image, the compare program returns the best match offset. In addition, it returns a similarity image such that an exact match location is completely white and if none of the pixels match, black, otherwise some gray level in-between:

    - -
    --> compare -metric RMSE -subimage-search logo.png wizard.jpg similarity.gif
    -85.05 (0.00129778) @ 353,157
    -
    - -

    You can find additional examples of using compare in Graphics from the Command Line. Further discussion is available in More Graphics from the Command Line and Examples of ImageMagick Usage.

    - -

    The compare program returns 2 on error otherwise 0 if the images are similar or 1 if they are dissimilar.

    - -

    Option Summary

    - -

    The compare command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
    -authenticate valuedecrypt image with this password
    -channel typeapply option to select image channels
    -colorspace typeset image colorspace
    -compose operatorset image composite operator
    -decipher filenameconvert cipher pixels to plain
    -debug eventsdisplay copious debugging information
    -define format:optiondefine one or more image format options
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -dissimilarity-threshold valuemaximum distortion for (sub)image match (default 0.2)
    -encipher filenameconvert plain pixels to cipher pixels
    -extract geometryextract area from image
    -fuzz distancecolors within this distance are considered equal
    -helpprint program options
    -highlight-color coloremphasize pixel differences with this color
    -identifyidentify the format and characteristics of the image
    -interlace typetype of image interlacing scheme
    -limit type valuepixel cache resource limit
    -log formatformat of debugging information
    -lowlight-color colorde-emphasize pixel differences with this color
    -metric typemeasure differences between images with this metric
    -profile filenameadd, delete, or apply an image profile
    -quality valueJPEG/MIFF/PNG compression level
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -regard-warningspay attention to warning messages.
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -sampling-factor geometryhorizontal and vertical sampling factor
    -seed valueseed a new sequence of pseudo-random numbers
    -set attribute valueset an image attribute
    -similarity-threshold valueminimum distortion for (sub)image match (default 0.0)
    -size geometrywidth and height of image
    -subimage-searchsearch for subimage
    -synchronizesynchronize image to storage device
    -taintmark the image as modified
    -transparent-color colortransparent color
    -verboseprint detailed information about the image
    -versionprint version information
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/compose.html b/ImageMagick-7.0.0-0/www/compose.html deleted file mode 100644 index 7b9d65406..000000000 --- a/ImageMagick-7.0.0-0/www/compose.html +++ /dev/null @@ -1,640 +0,0 @@ - - - - - - - - - ImageMagick: Alpha Compositing - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    This page descibed the Image composition methods that is used to define how -two images should be merged together in various image operations. For the -Command Line API it is typically set using the -compose setting option.

    - - -

    The description of composition uses abstract terminology in order to allow -the description to be more precise, while avoiding constant values which are -specific to a particular build configuration. Each image pixel is represented -by red, green, and blue levels (which are equal for a gray pixel). The -build-dependent value QuantumRange is the maximum integral -value which may be stored, per pixel, in the red, green, or blue channels of -the image. Each image pixel may also optionally (if the image matte channel is -enabled) have an associated level of opacity, ranging from opaque to -transparent, which may be used to determine the influence of the pixel -color when compositing the pixel with another image pixel. If the image matte -channel is disabled, then all pixels in the image are treated as opaque. The -color of an opaque pixel is fully visible while the color of a transparent -pixel color is entirely absent (pixel color is ignored).

    - -

    By definition, raster images have a rectangular shape. All image rows are of -equal length, as are all image columns. By treating the alpha channel as a -visual "mask" the rectangular image may be given a "shape" by treating the -alpha channel as a cookie-cutter for the image. This is done by setting the -pixels within the shape to be opaque, with pixels outside the shape set as -transparent. Pixels on the boundary of the shape may be between opaque and -transparent in order to provide antialiasing (visually smooth edges). The -description of the composition operators use this concept of image "shape" in -order to make the description of the operators easier to understand. While it -is convenient to describe the operators in terms of "shapes" they are by no -means limited to mask-style operations since they are based on continuous -floating-point mathematics rather than simple boolean operations.

    - -

    The following alpha blending (Duff-Porter) compose methods are available:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    clearBoth the color and the alpha of the destination are - cleared. Neither the source nor the destination are used (except for - destinations size and other meta-data which is always preserved.
    srcThe source is copied to the destination. The destination - is not used as input, though it is cleared.
    dstThe destination is left untouched. The source image is - completely ignored.
    src-overThe source is composited over the destination. this is - the default alpha blending compose method, when neither the compose - setting is set, nor is set in the image meta-data.
    dst-overThe destination is composited over the source and the - result replaces the destination.
    src-inThe part of the source lying inside of the destination - replaces the destination.
    dst-inThe part of the destination lying inside of the source - replaces the destination. Areas not overlaid are cleared.
    src-outThe part of the source lying outside of the destination - replaces the destination.
    dst-outThe part of the destination lying outside of the source - replaces the destination.
    src-atopThe part of the source lying inside of the destination is - composited onto the destination.
    dst-atopThe part of the destination lying inside of the source is - composited over the source and replaces the destination. Areas not - overlaid are cleared.
    xorThe part of the source that lies outside of the - destination is combined with the part of the destination that lies - outside of the source. Source or Destination, but not both.
    - -

    Any of the 'Src-*' methods can also be specified without the 'Src-' part. -For example the default compose method can be specified as just 'Over'.

    - -

    Many of these compose methods will clear the destination image which was -not overlaid by the source image. This is to be expected as part of that -specific composition methods defintion. You can disable this by setting the -special -define 'compose:outside-overlay' to a value of 'false' will turn off -this behavior.

    - -

    On top of the above 12 Duff-Porter Alpha Composition methods, one special -related method 'Copy' has been provided. This is equivalent to -using the 'Src' with the special -define option 'compose:outside-overlay' set to -'false', so as to only modify the overlaid area, without clearing -the rest of the image outside the overlaid area.

    - -

    The following mathematical composition methods are also available.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    multiplyThe source is multiplied by the destination and replaces - the destination. The resultant color is always at least as dark as - either of the two constituent colors. Multiplying any color with black - produces black. Multiplying any color with white leaves the original - color unchanged.
    screenThe source and destination are complemented and then - multiplied and then replace the destination. The resultant color is - always at least as light as either of the two constituent colors. - Screening any color with white produces white. Screening any color - with black leaves the original color unchanged.
    plusThe source is added to the destination and replaces the - destination. This operator is useful for averaging or a controlled - merger of two images, rather than a direct overlay.
    addAs per 'plus' but transparency data is treated as matte - values. As such any transparent areas in either image remain - transparent.
    minusSubtract the colors in the source image from the - destination image. When transparency is involved, opaque areas is - subtracted from any destination opaque areas.
    subtractSubtract the colors in the source image from the - destination image. When transparency is involved transparent areas are - subtracted, so only the opaque areas in the source remain opaque in - the destination image.
    differenceSubtracts the darker of the two constituent colors from - the lighter. Painting with white inverts the destination color. - Painting with black produces no change.
    exclusionProduces an effect similar to that of 'difference', but - appears as lower contrast. Painting with white inverts the - destination color. Painting with black produces no change.
    darkenSelects the darker of the destination and source colors. - The destination is replaced with the source when the source is darker, - otherwise it is left unchanged.
    lightenSelects the lighter of the destination and source colors. - The destination is replaced with the source when the source is - lighter, otherwise it is left unchanged.
    - -

    Typically these use the default 'Over' alpha blending when transparencies -are also involved, except for 'Plus' which uses a 'plus' alpha blending. This -means the alpha channel of both images will only be used to ensure that any -visible input remains visible even in parts not overlaid. It also means that -any values are weighted by the alpha channel of the input and output images. -This 'Over' alpha blending is also applied to the lighting composition methods -below.

    - -

    As of IM v6.6.1-6, if the special 'Sync' flag is not specified -(enabled by default) with the -channel setting, then the above mathematical compositions will nolonger -synchronise its actions with the alpha channel. Instead the math composition -will be applied on an individual channel basis as defined by the -channel. This includes the alpha channel. This special usage -allows you to perform true mathematics of the image channels, without alpha -composition effects, becoming involved.

    - -

    This special flag is not applied to the lighting composition methods (see -below) even though they are closely related to mathematical composition -methods.

    - -

    The following lighting composition methods are also available.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    linear-dodgeThis is equivalent to 'Plus' in that the color channels - are simply added, however it does not 'Plus' the alpha channel, but - uses the normal 'Over' alpha blending, which transparencies are - involved. Produces a sort of additive multiply-like result. Added - ImageMagick version 6.5.4-3.
    linear-burnAs 'Linear-Dodge', but also subtract one from the result. - Sort of a additive 'Screen' of the images. Added ImageMagick version - 6.5.4-3.
    color-dodgeBrightens the destination color to reflect the source - color. Painting with black produces no change.
    color-burnDarkens the destination color to reflect the source - color. Painting with white produces no change. Fixed in ImageMagick - version 6.5.4-3.
    overlayMultiplies or screens the colors, dependent on the - destination color. Source colors overlay the destination whilst - preserving its highlights and shadows. The destination color is not - replaced, but is mixed with the source color to reflect the lightness - or darkness of the destination.
    hard-lightMultiplies or screens the colors, dependent on the source - color value. If the source color is lighter than 0.5, the destination - is lightened as if it were screened. If the source color is darker - than 0.5, the destination is darkened, as if it were multiplied. The - degree of lightening or darkening is proportional to the difference - between the source color and 0.5. If it is equal to 0.5 the - destination is unchanged. Painting with pure black or white produces - black or white.
    linear-lightLike 'Hard-Light' but using linear-dodge and linear-burn - instead. Increases contrast slightly with an impact on the - foreground's tonal values.
    soft-lightDarkens or lightens the colors, dependent on the source - color value. If the source color is lighter than 0.5, the destination - is lightened. If the source color is darker than 0.5, the destination - is darkened, as if it were burned in. The degree of darkening or - lightening is proportional to the difference between the source color - and 0.5. If it is equal to 0.5, the destination is unchanged. Painting - with pure black or white produces a distinctly darker or lighter area, - but does not result in pure black or white. Fixed in ImageMagick - version 6.5.4-3.
    pegtop-lightAlmost equivalent to 'Soft-Light', but using a - continuous mathematical formula rather than two conditionally - selected formulae. Added ImageMagick version 6.5.4-3.
    vivid-lightA modified 'Linear-Light' designed to preserve very stong - primary and secondary colors in the image. Added ImageMagick version - 6.5.4-3.
    pin-lightSimilar to 'Hard-Light', but using sharp linear shadings, - to simulate the effects of a strong 'pinhole' light source. Added - ImageMagick version 6.5.4-3.
    - -

    Also included are these special purpose compose methods:

    - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    copyThis is equivalent to the Duff-Porter composition method - 'Src,' but without clearing the parts of the destination - image that is not overlaid.
    copy-*Copy the specified channel (Red, Green, Blue, Cyan, - Magenta, Yellow, Black, or Opacity) in the source image to the - same channel in the destination image. If the channel specified - does not exist in the source image, (which can only happen for methods, - 'copy-opacity' or 'copy-black') then it is - assumed that the source image is a special grayscale channel image - of the values that is to be copied.
    change-maskReplace any destination pixel that is the similar to the - source images pixel (as defined by the current -fuzz factor), with transparency. -
    - -

    On top of these composed methods are a few special ones that not only require -the two images that are being merged or overlaid, but have some extra numerical -arguments, which are tabled below.

    - -

    In the "composite" command these composition methods are -selected using special options with the arguments needed. They are usually, -but not always, the same name as the composite 'method' they use, and replaces -the normal use of the -compose -setting in the "composite" command. For example...

    - -
    -composite ... -blend 50x50 ...
    -
    - -

    As of IM v6.5.3-4 the "convert" command can now also supply -these extra arguments to its -composite operator, using the special -define -attribute of 'compose:args'. This means you can now -make use of these special augmented -compose methods, those the argument and the method both need to be set -separately. For example...

    - -
    -convert ... -compose blend  -define compose:args=50,50 -composite ...
    -
    - -

    The following is a table of these special 'argumented' compose methods, -with a brief summary of what they do. For more details see the equivalent -"composite" command option name.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    dissolveArguments: - src_percent[xdst_percent] -
    Equivalent to "composite" -dissolve -
    Dissolve the 'source' image by the percentage given before overlaying - 'over' the 'destination' image. If src_percent is - greater than 100, it starts dissolving the main image so it will - become transparent at a value of '200'. If - both percentages are given, each image are dissolved to the - percentages given. -
    blendArguments: - src_percent[xdst_percent] -
    Equivalent to "composite" -blend -
    Average the images together ('plus') according to the percentages - given and each pixels transparency. If only a single percentage value - is given it sets the weight of the composite or 'source' image, while - the background image is weighted by the exact opposite amount. That is - a -blend 30 merges 30% of the 'source' image with 70% of - the 'destination' image. Thus it is equivalent to -blend - 30x70. -
    mathematicsArguments: A, B, C, D -
    Not available in "composite" at this time. -
    Merge the source and destination images according to the formula -
    A*Sc*Dc + B*Sc + C*Dc + D -
    Can be used to generate a custom composition method that would - otherwise need to be implemented using the slow -fx DIY image operator. Added - to ImageMagick version 6.5.4-3. -
    As of IM v6.6.1-6 this method will do per-channel math compositions - if the 'Sync' flag is removed from -channel, just like all - the other mathematical composition methods above. -
    modulateArguments: - brightness[xsaturation] -
    Equivalent to "composite" -watermark -
    Take a grayscale image (with alpha mask) and modify the destination - image's brightness according to watermark image's grayscale value and - the brightness percentage. The destinations - color saturation attribute is just direct modified by the saturation percentage, which defaults to 100 percent - (no color change). - -
    displaceArguments: - X-scale[xY-scale][!][%] -
    Equivalent to "composite" -displace -
    With this option, the 'overlay' image, and optionally the 'mask' - image, is used as a relative displacement map, which is used to - displace the lookup of what part of the destination image is seen at - each point of the overlaid area. Much like the displacement map is a - 'lens' that distorts the original 'background' image behind it. -

    - The X-scale is modulated by the 'red' channel of the overlay image - while the Y-scale is modulated by the green channel, (the mask image - if given is rolled into green channel of the overlay image. This - separation allows you to modulate the X and Y lookup displacement - separately allowing you to do 2-dimensional displacements, rather - than 1-dimensional vectored displacements (using grayscale image). -

    - If the overlay image contains transparency this is used as a mask - of the resulting image to remove 'invalid' pixels. -

    - The '%' flag makes the displacement scale relative to the size of the - overlay image (100% = half width/height of image). Using '!' switches - percentage arguments to refer to the destination image size instead. -

    - Special flags were added Added to ImageMagick version 6.5.3-5. -
    distortArguments: - X-scale[xY-scale[+X-center+Y-center]][!][%] -
    Not available in "composite" at this time. -
    Exactly as per 'Displace' (above), but using absolute coordinates, - relative to the center of the overlay (or that given). Basically - allows you to generate absolute distortion maps where 'black' will - look up the left/top edge, and 'white' looks up the bottom/right - edge of the destination image, according to the scale given. -

    - The '!' flag not only switches percentage scaling, to use the - destination image, but also the image the center offset of the lookup. - This means the overlay can lookup a completely different region of the - destination image. -

    - Added to ImageMagick version 6.5.3-5. -
    blurArguments: - Width[xHeight[+Angle][+Angle2]] -
    Equivalent to "composite" -blur -
    A Variable Blur Mapping Composition method, where each pixel in the - overlaid region is replaced with an Elliptical Weighted Average (EWA), - with an ellipse (typically a circle) of the given sigma size, scaled - according to overlay (source image) grayscale mapping. -

    - As per 'Displace' and 'Distort', the red channel will modulate the - width of the ellipse, while the green channel will modulate the height - of the ellipse. If a single Angle value is given in the arguments, - then the ellipse will then be rotated by the angle specified. -

    - Normally the blue channel of the mapping overlay image is ignored. - However if a second ellipse angle is given, then it is assumed that - the blue channel defines a variable angle for the ellipse ranging from - the first angle to the second angle given. This allows to generate - radial blurs, or a rough approximation for rotational blur. Or any mix - of the two. -

    - Added to ImageMagick version 6.5.4-0. -
    - -

    To print a complete list of all the available compose operators, use -list compose.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/composite.html b/ImageMagick-7.0.0-0/www/composite.html deleted file mode 100644 index b8f4c7c12..000000000 --- a/ImageMagick-7.0.0-0/www/composite.html +++ /dev/null @@ -1,522 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Composite - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    Use the composite program to overlap one image over another. See Command Line Processing for advice on how to structure your composite command or see below for example usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the composite command here to illustrate its usefulness and ease of use. To get started, lets overlay a smiley face over a rose:

    - -
    -composite -gravity center smile.gif  rose: rose-over.png
    -
    - -
      - smile - over - rose - ==> - rose -
    - -

    You can create three-dimensional effect with the Atop:

    - -
    -convert -size 70x70 canvas:none -fill red -draw 'circle 35,35 10,30' red-circle.png
    -convert -size 70x70 canvas:none -draw 'circle 35,35 35,20' -negate \
    --channel A -gaussian-blur 0x8 white-highlight.png
    -composite -compose atop -geometry -13-17 white-highlight.png red-circle.png red-ball.png
    -
    - -
      - white highlight - atop - red circle - ==> - red ball -
    - -

    You can find additional examples of using composite in Examples of ImageMagick Usage. You can find out more about them and the mathematics by looking at SVG Alpha Compositing

    - -

    Option Summary

    - -

    The composite command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -affine matrixaffine transform matrix
    -alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
    -authenticate valuedecrypt image with this password
    -blend geometryblend images
    -blue-primary pointchromaticity blue primary point
    -border geometrysurround image with a border of color
    -bordercolor colorborder color
    -channel typeapply option to select image channels
    -colors valuepreferred number of colors in the image
    -colorspace typeset image colorspace
    -comment stringannotate image with comment
    -compose operatorset image composite operator
    -compress typeimage compression type
    -debug eventsdisplay copious debugging information
    -decipher filenameconvert cipher pixels to plain
    -define format:optiondefine one or more image format options
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -displace geometryshift image pixels defined by a displacement map
    -dissolve valuedissolve the two images a given percent
    -dither methodapply error diffusion to image
    -encipher filenameconvert plain pixels to cipher pixels
    -encoding typetext encoding type
    -endian typeendianness (MSB or LSB) of the image
    -extract geometryextract area from image
    -filter typeuse this filter when resizing an image
    -font namerender text with this font
    -geometry geometrypreferred size or location of the image
    -gravity typehorizontal and vertical text placement
    -green-primary pointchromaticity green primary point
    -helpprint program options
    -identifyidentify the format and characteristics of the image
    -interlace typetype of image interlacing scheme
    -interpolate methodpixel color interpolation method
    -label stringassign a label to an image
    -level valueadjust the level of image contrast
    -limit type valuepixel cache resource limit
    -log formatformat of debugging information
    -monitormonitor progress
    -monochrometransform image to black and white
    -negatereplace each pixel with its complementary color
    -page geometrysize and location of an image canvas (setting)
    -pointsize valuefont point size
    -profile filenameadd, delete, or apply an image profile
    -quality valueJPEG/MIFF/PNG compression level
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -red-primary pointchromaticity red primary point
    -regard-warningspay attention to warning messages.
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -rotate degreesapply Paeth rotation to the image
    -sampling-factor geometryhorizontal and vertical sampling factor
    -scene valueimage scene number
    -seed valueseed a new sequence of pseudo-random numbers
    -set attribute valueset an image attribute
    -sharpen geometrysharpen the image
    -shave geometryshave pixels from the image edges
    -size geometrywidth and height of image
    -stegano offsethide watermark within an image
    -stereo geometrycombine two image to create a stereo anaglyph
    -stripstrip image of all profiles and comments
    -swap indexesswap two images in the image sequence
    -synchronizesynchronize image to storage device
    -taintmark the image as modified
    -thumbnail geometrycreate a thumbnail of the image
    -tilerepeat composite operation across and down image
    -transformaffine transform image
    -transparent-color colortransparent color
    -treedepth valuecolor tree depth
    -type typeimage type
    -units typethe units of image resolution
    -unsharp geometrysharpen the image
    -verboseprint detailed information about the image
    -versionprint version information
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    -watermark geometrypercent brightness and saturation of a watermark
    -white-point pointchromaticity white point
    -white-threshold valueforce all pixels above the threshold into white
    -write filenamewrite images to this file
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/conjure.html b/ImageMagick-7.0.0-0/www/conjure.html deleted file mode 100644 index 4c15d0099..000000000 --- a/ImageMagick-7.0.0-0/www/conjure.html +++ /dev/null @@ -1,1134 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Conjure - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary • Magick Scripting Language (MSL)

    - -

    The conjure program gives you the ability to perform custom image processing tasks from a script written in the Magick Scripting Language (MSL). MSL is XML-based and consists of action statements with attributes. Actions include reading an image, processing an image, getting attributes from an image, writing an image, and more. An attribute is a key/value pair that modifies the behavior of an action. See Command Line Processing for advice on how to structure your conjure command or see below for example usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the conjure command here to illustrate its usefulness and ease of use. To get started, here is simple conjure command:

    - -
    -conjure -dimensions 400x400 incantation.msl
    -
    - -

    The MSL script incantation.msl used above is here:

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

    In this example, a family stayed home for their vacation but as far as their friends are concerned they went to a beautiful beach in the Caribbean:

    - -
    -<?xml version="1.0" encoding="UTF-8"?>
    -<group>
    -    <image id="family">
    -        <read filename="family.gif"/>
    -        <resize geometry="300x300"/>
    -    </image>
    -    <image id="palm-trees">
    -        <read filename="palm-trees.gif"/>
    -        <resize geometry="300x100"/>
    -    </image>
    -    <image>
    -        <read filename="beach.jpg"/>
    -        <composite image="family" geometry="+30+40"/>
    -        <composite image="palm-trees" geometry="+320+90"/>
    -    </image>
    -    <write filename="family-vacation.png"/>
    -</group>
    -
    - -

    Here we display the width in pixels of text for a particular font and pointsize.

    - -
    -<?xml version="1.0" encoding="UTF-8"?>
    -<image>
    -  <query-font-metrics text="ImageMagick" font="helvetica" pointsize="48" />
    -  <print output="Text width is %[msl:font-metrics.width] pixels.\n" />
    -</image>
    -
    - -

    The query-font-metrics tag supports these properties:

    - -
    -msl:font-metrics.pixels_per_em.x
    -msl:font-metrics.pixels_per_em.y
    -msl:font-metrics.ascent
    -msl:font-metrics.descent
    -msl:font-metrics.width
    -msl:font-metrics.height
    -msl:font-metrics.max_advance
    -msl:font-metrics.bounds.x1
    -msl:font-metrics.bounds.y1
    -msl:font-metrics.bounds.x2
    -msl:font-metrics.bounds.y2
    -msl:font-metrics.origin.x
    -msl:font-metrics.origin.y
    -
    - -

    MSL supports most methods and attributes discussed in the Perl API for ImageMagick. -

    - -

    In addition, MSL supports the swap element with a single indexes element.

    - -

    You can find additional examples of using conjure in Graphics from the Command Line. Further discussion is available in More Graphics from the Command Line and Examples of ImageMagick Usage.

    - - -

    Option Summary

    - -

    The conjure command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -debug eventsdisplay copious debugging information
    -helpprint program options
    -log formatformat of debugging information
    -monitormonitor progress
    -quietsuppress all warning messages
    -regard-warningspay attention to warning messages.
    -seed valueseed a new sequence of pseudo-random numbers
    -verboseprint detailed information about the image
    -versionprint version information
    - -

    Magick Scripting Language

    -

    The conjure command recognizes these MSL elements. Any element with a strike-thru is not supported yet.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Magick Scripting Language (MSL)
    MethodParametersDescription
    adaptiveblurgeometry="geometry", radius="double", sigma="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"adaptively blur the image with a Gaussian operator of the given radius and standard deviation (sigma). Decrease the effect near edges.
    adaptiveresizegeometry="geometry", width="integer", height="integer", filter="Point, Box, Triangle, Hermite, Hanning, Hamming, Blackman, Gaussian, Quadratic, Cubic, Catrom, Mitchell, Lanczos, Bessel, Sinc", support="double", blur="double"adaptively resize image using data dependant triangulation. Specify blur > 1 for blurry or < 1 for sharp
    adaptivesharpengeometry="geometry", radius="double", sigma="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"adaptively sharpen the image with a Gaussian operator of the given radius and standard deviation (sigma). Increase the effect near edges.
    adaptivethresholdgeometry="geometry", width="integer", height="integer", offset="integer"local adaptive thresholding.
    addnoisenoise="Uniform, Gaussian, Multiplicative, Impulse, Laplacian, Poisson", attenuate="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"add noise to an image
    affinetransformaffine="array of float values", translate="float, float", scale= "float, float", rotate="float", skewX="float", skewY="float", interpolate="Average, Bicubic, Bilinear, Filter, Integer, Mesh, NearestNeighbor", background="color name"affine transform image
    affinityimage="image-handle", method="None, FloydSteinberg, Riemersma"choose a particular set of colors from this image
    <annotate>text="string", font="string", family="string", style="Normal, Italic, Oblique, Any", stretch="Normal, UltraCondensed, ExtraCondensed, Condensed, SemiCondensed, SemiExpanded, Expanded, ExtraExpanded, UltraExpanded", weight="integer", pointsize="integer", density="geometry", stroke="color name", strokewidth="integer", fill="color name", undercolor="color name", kerning="float", geometry="geometry", gravity="NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast", antialias="true, false", x="integer", y="integer", affine="array of float values", translate="float, float", scale="float, float", rotate="float". skewX="float", skewY= "float", align="Left, Center, Right", encoding="UTF-8", interline-spacing="double", interword-spacing="double", direction="right-to-left, left-to-right"annotate an image with text. See QueryFontMetrics to get font metrics without rendering any text.
    autogammachannel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"automagically adjust gamma level of image
    autolevelchannel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"automagically adjust color levels of image
    autoorient adjusts an image so that its orientation is suitable for viewing (i.e. top-left orientation)
    blackthresholdthreshold="string", , channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"force all pixels below the threshold intensity into black
    blueshiftfactor="double",simulate a scene at nighttime in the moonlight. Start with a factor of 1.5.
    <blur>geometry="geometry", radius="double", sigma="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"reduce image noise and reduce detail levels with a Gaussian operator of the given radius and standard deviation (sigma).
    <border>geometry="geometry", width="integer", height="integer", bordercolor="color name", compose="Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor ",surround the image with a border of color
    <charcoal>geometry="geometry", radius="double", sigma="double"simulate a charcoal drawing
    <chop>geometry="geometry", width="integer", height="integer", x="integer", y="integer"chop an image
    clampchannel="Red, RGB, All, etc."set each pixel whose value is below zero to zero and any the pixel whose value is above the quantum range to the quantum range (e.g. 65535) otherwise the pixel value remains unchanged.
    clipid="name", inside=""true, false"",apply along a named path from the 8BIM profile.
    clipmaskmask="image-handle"clip image as defined by the image mask
    clutimage="image-handle", interpolate="Average, Bicubic, Bilinear, Filter, Integer, Mesh, NearestNeighbor", channel="Red, RGB, All, etc."apply a color lookup table to an image sequence
    coalesce merge a sequence of images
    colorcolor="color name"set the entire image to this color.
    colordecisionlistfilename="string",color correct with a color decision list.
    <colorize>fill="color name", blend="string"colorize the image with the fill color
    colormatrixmatrix="array of float values"apply color correction to the image. Although you can use variable sized matrices, typically you use a 5 x 5 for an RGBA image and a 6x6 for CMYKA. A 6x6 matrix is required for offsets (populate the last column with normalized values).
    <comment>stringadd a comment to your image
    comparelayersmethod="any, clear, overlay"compares each image with the next in a sequence and returns the minimum bounding region of any pixel differences it discovers. Images do not have to be the same size, though it is best that all the images are coalesced (images are all the same size, on a flattened canvas, so as to represent exactly how a specific frame should look).
    <composite>image="image-handle", compose="Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor ", mask="image-handle", geometry="geometry", x="integer", y="integer", gravity="NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast", opacity="integer", tile="True, False", rotate="double", color="color name", blend="geometry", interpolate="undefined, average, bicubic, bilinear, filter, integer, mesh, nearest-neighbor, spline"composite one image onto another. Use the rotate parameter in concert with the tile parameter.
    <contrast>sharpen="True, False"enhance or reduce the image contrast
    contraststretchlevels="string", 'black-point'="double", 'white-point'="double", channel="Red, RGB, All, etc."improve the contrast in an image by `stretching' the range of intensity values
    convolvecoefficients="array of float values", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", bias="double"apply a convolution kernel to the image. Given a kernel "order" , you would supply "order*order" float values (e.g. 3x3 implies 9 values).
    <crop>geometry="geometry", width="integer", height="integer", x="integer", y="integer", fuzz="double", gravity="NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast"crop an image
    cyclecolormapamount="integer"displace image colormap by amount
    decipherpassphrase="string"convert cipher pixels to plain pixels
    deconstruct break down an image sequence into constituent parts
    deskewgeometry="string",threshold="double"straighten the image
    <despeckle> reduce the speckles within an image
    differenceimage="image-handle"compute the difference metrics between two images
    distortpoints="array of float values", method="Affine, AffineProjection, Bilinear, Perspective, Resize, ScaleRotateTranslate", virtual-pixel="Background Black Constant Dither Edge Gray Mirror Random Tile Transparent White", best-fit="True, False"distort image
    <draw>primitive="point, line, rectangle, arc, ellipse, circle, path, polyline, polygon, bezier, color, matte, text, @"filename"", points="string" , method=""Point, Replace, Floodfill, FillToBorder, Reset"", stroke="color name", fill="color name", font="string", pointsize="integer", strokewidth="float", antialias="true, false", bordercolor="color name", x="float", y="float", dash-offset="float", dash-pattern="array of float values", affine="array of float values", translate="float, float", scale="float, float", rotate="float", skewX="float", skewY="float", interpolate="undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline", kerning="float", text="string", vector-graphics="string", interline-spacing="double", interword-spacing="double", direction="right-to-left, left-to-right"annotate an image with one or more graphic primitives.
    encipherpassphrase="string"convert plain pixels to cipher pixels
    <edge>radius="double"enhance edges within the image with a convolution filter of the given radius.
    <emboss>geometry="geometry", radius="double", sigma="double"emboss the image with a convolution filter of the given radius and standard deviation (sigma).
    <enhance> apply a digital filter to enhance a noisy image
    <equalize>channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow" perform histogram equalization to the image
    extentgeometry="geometry", width="integer", height="integer", x="integer", y="integer", fuzz="double", background="color name", gravity="NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast"set the image size
    evaluatevalue="double", operator=""Add, And, Divide, LeftShift, Max, Min, Multiply, Or, Rightshift, Subtract, Xor"", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow" apply an arithmetic, relational, or logical expression to the image
    filterkernel="string", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", bias="double"apply a convolution kernel to the image.
    <flip> reflect the image scanlines in the vertical direction
    <flop> reflect the image scanlines in the horizontal direction
    floodfillpaintgeometry="geometry", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", x="integer", y="integer" , fill="color name", bordercolor="color name", fuzz="double", invert="True, False"changes the color value of any pixel that matches the color of the target pixel and is a neighbor. If you specify a border color, the color value is changed for any neighbor pixel that is not that color.
    forwardfouriertransformmagnitude="True, False"implements the forward discrete Fourier transform (DFT)
    <frame>geometry="geometry", width="integer", height="integer", inner="integer", outer="integer", fill="color name", compose="Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor ",surround the image with an ornamental border
    functionparameters="array of float values", function="Sin", virtual-pixel="Background Black Constant Dither Edge Gray Mirror Random Tile Transparent White"apply a function to the image
    <gamma>gamma="string", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"gamma correct the image
    gaussianblurgeometry="geometry", radius="double", sigma="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"reduce image noise and reduce detail levels with a Gaussian operator of the given radius and standard deviation (sigma).
    getpixelgeometry="geometry", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", normalize="true, false", x="integer", y="integer"get a single pixel. By default normalized pixel values are returned.
    getpixelsgeometry="geometry", width="integer", height="integer", x="integer", y="integer", map="string", normalize="true, false"get image pixels as defined by the map (e.g. "RGB", "RGBA", etc.). By default non-normalized pixel values are returned.
    grayscalechannel="Average, Brightness, Lightness, Rec601Luma, Rec601Luminance, Rec709Luma, Rec709Luminance, RMS"convert image to grayscale
    haldclutimage="image-handle", channel="Red, RGB, All, etc."apply a Hald color lookup table to an image sequence
    identifyfile="file", features="distance", unique="True, False"identify the attributes of an image
    <implode>amount="double", interpolate="undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline"implode image pixels about the center
    inversediscretefouriertransformmagnitude="True, False"implements the inverse discrete Fourier transform (DFT)
    <label>stringassign a label to an image
    layersmethod="coalesce, compare-any, compare-clear, compare-over, composite, dispose, flatten, merge, mosaic, optimize, optimize-image, optimize-plus, optimize-trans, remove-dups, remove-zero", compose="Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, LinearLight, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor ", dither="true, false"compare each image the GIF disposed forms of the previous image in the sequence. From this, attempt to select the smallest cropped image to replace each frame, while preserving the results of the animation.
    <level>levels="string", 'black-point'="double", 'gamma'="double", 'white-point'="double", channel="Red, RGB, All, etc."adjust the level of image contrast
    levelcolorsinvert=>"True, False", 'black-point'="string", 'white-point'="string", channel="Red, RGB, All, etc."level image with the given colors
    linearstretchlevels="string", 'black-point'="double", 'white-point'="double"linear with saturation stretch
    liquidresizegeometry="geometry", width="integer", height="integer", delta-x="double", rigidity="double"rescale image with seam-carving.
    <magnify> double the size of the image with pixel art scaling
    maskmask="image-handle"composite image pixels as defined by the mask
    mattefloodfillgeometry="geometry", x="integer", y="integer" , matte="integer", bordercolor="color name", fuzz="double", invert="True, False"changes the matte value of any pixel that matches the color of the target pixel and is a neighbor. If you specify a border color, the matte value is changed for any neighbor pixel that is not that color.
    medianfiltergeometry="geometry", width="integer", height="integer", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"replace each pixel with the median intensity pixel of a neighborhood.
    <minify> half the size of an image
    modegeometry="geometry", width="integer", height="integer", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"make each pixel the "predominant color" of the neighborhood.
    <modulate>factor="geometry", brightness="double", saturation="double", hue="double", lightness="double", whiteness="double", blackness="double" vary the brightness, saturation, and hue of an image by the specified percentage
    morphologykernel="string", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", iterations="integer"apply a morphology method to the image.
    motionblurgeometry="geometry", radius="double", sigma="double", angle="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"reduce image noise and reduce detail levels with a Gaussian operator of the given radius and standard deviation (sigma) at the given angle to simulate the effect of motion
    <negate>gray="True, False", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"replace each pixel with its complementary color (white becomes black, yellow becomes blue, etc.)
    <normalize>channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow" transform image to span the full range of color values
    oilpaintradius="integer"simulate an oil painting
    <opaque>color="color name", -fill="color name", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", invert="True, False"change this color to the fill color within the image
    orderedditherthreshold="threshold, checks, o2x2, o3x3, o4x4, o8x8, h4x4a, h6x6a, h8x8a, h4x4o, h6x6o, h8x8o, h16x16o, hlines6x4", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"order dither image
    perceptibleepsilon="double", channel="Red, RGB, All, etc."set each pixel whose value is less than |"epsilon"| to "-epsilon" or "epsilon" (whichever is closer) otherwise the pixel value remains unchanged..
    polaroidcaption="string", angle="double", pointsize="double", font="string", stroke= "color name", strokewidth="integer", fill="color name", gravity="NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast", background="color name"simulate a Polaroid picture.
    posterizelevels="integer", dither="True, False"reduce the image to a limited number of color level
    <profile>name="string", profile="blob", rendering-intent="Undefined, Saturation, Perceptual, Absolute, Relative", black-point-compensation="True, False"add or remove ICC or IPTC image profile; name is formal name (e.g. ICC or filename; set profile to '' to remove profile
    <quantize>colors="integer", colorspace="RGB, Gray, Transparent, OHTA, XYZ, YCbCr, YIQ, YPbPr, YUV, CMYK, sRGB, HSL, HSB", treedepth= "integer", dither="True, False", dither-method="Riemersma, Floyd-Steinberg", measure_error="True, False", global_colormap="True, False", transparent-color="color"preferred number of colors in the image
    radialblurgeometry="geometry", angle="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"radial blur the image.
    <raise>geometry="geometry", width="integer", height="integer", x="integer", y="integer", raise="True, False"lighten or darken image edges to create a 3-D effect
    reducenoisegeometry="geometry", width="integer", height="integer", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"reduce noise in the image with a noise peak elimination filter
    remapimage="image-handle", dither="true, false", dither-method="Riemersma, Floyd-Steinberg"replace the colors of an image with the closest color from a reference image.
    <resample>density="geometry", x="double", y="double", filter="Point, Box, Triangle, Hermite, Hanning, Hamming, Blackman, Gaussian, Quadratic, Cubic, Catrom, Mitchell, Lanczos, Bessel, Sinc", support="double"resample image to desired resolution. Specify blur > 1 for blurry or < 1 for sharp
    <resize>geometry="geometry", width="integer", height="integer", filter="Point, Box, Triangle, Hermite, Hanning, Hamming, Blackman, Gaussian, Quadratic, Cubic, Catrom, Mitchell, Lanczos, Bessel, Sinc", support="double", blur="double"scale image to desired size. Specify blur > 1 for blurry or < 1 for sharp
    <roll>geometry="geometry", x="integer", y="integer"roll an image vertically or horizontally
    <rotate>degrees="double", background="color name"rotate an image
    <sample>geometry="geometry", width="integer", height="integer"scale image with pixel sampling.
    <scale>geometry="geometry", width="integer", height="integer"scale image to desired size
    <segment>colorspace="RGB, Gray, Transparent, OHTA, XYZ, YCbCr, YCC, YIQ, YPbPr, YUV, CMYK", verbose="True, False", cluster-threshold="double", smoothing-threshold="double"segment an image by analyzing the histograms of the color components and identifying units that are homogeneous
    selectiveblurgeometry="geometry", radius="double", sigma="double", threshold="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"selectively blur pixels within a contrast threshold.
    separatechannel="Red, RGB, All, etc."separate a channel from the image into a grayscale image
    <shade>geometry="geometry", azimuth="double", elevation="double", gray="true, false"shade the image using a distant light source
    setpixelgeometry="geometry", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", color="array of float values", x="integer", y="integer", color="array of float values"set a single pixel. By default normalized pixel values are expected.
    <shadow>geometry="geometry", opacity="double", sigma="double", x="integer", y="integer"simulate an image shadow
    <sharpen>geometry="geometry", radius="double", sigma="double", bias="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"sharpen the image with a Gaussian operator of the given radius and standard deviation (sigma).
    <shave>geometry="geometry", width="integer", height="integer"shave pixels from the image edges
    <shear>geometry="geometry", x="double", y="double" fill="color name"shear the image along the X or Y axis by a positive or negative shear angle
    sigmoidalcontrastgeometry="string", 'contrast'="double", 'mid-point'="double" channel="Red, RGB, All, etc.", sharpen="True, False"sigmoidal non-lineraity contrast control. Increase the contrast of the image using a sigmoidal transfer function without saturating highlights or shadows. Contrast" indicates how much to increase the contrast (0 is none; 3 is typical; 20 is a lot); mid-point" indicates where midtones fall in the resultant image (0 is white; 50% is middle-gray; 100% is black). To decrease contrast, set sharpen to False.
    <signature> generate an SHA-256 message digest for the image pixel stream
    sketchgeometry="geometry", radius="double", sigma="double", angle="double"sketch the image with a Gaussian operator of the given radius and standard deviation (sigma) at the given angle
    <solarize>geometry="string", threshold="double", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"negate all pixels above the threshold level
    sparsecolorpoints="array of float values", method="Barycentric, Bilinear, Shepards, Voronoi", virtual-pixel="Background Black Constant Dither Edge Gray Mirror Random Tile Transparent White"interpolate the image colors around the supplied points
    splicegeometry="geometry", width="integer", height="integer", x="integer", y="integer", fuzz="double", background="color name", gravity="NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast"splice an image
    <spread>radius="double", interpolate="undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline"displace image pixels by a random amount
    statisticgeometry="geometry", width="integer", height="integer", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow", type="Median, Mode, Mean, Maximum, Minimum, ReduceNoise"replace each pixel with corresponding statistic from the neighborhood.
    <stegano>image="image-handle", offset="integer"hide a digital watermark within the image
    <stereo>image="image-handle", x="integer", y="integer"composites two images and produces a single image that is the composite of a left and right image of a stereo pair
    <strip> strip an image of all profiles and comments.
    <swirl>degrees="double", interpolate="undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline"swirl image pixels about the center
    texturetexture="image-handle"name of texture to tile onto the image background
    thumbnailgeometry="geometry", width="integer", height="integer"changes the size of an image to the given dimensions and removes any associated profiles.
    <threshold>threshold="string", channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"threshold the image
    tintfill="color name", blend="string"tint the image with the fill color.
    <transparent>color="color name", invert="True, False"make this color transparent within the image
    transpose flip image in the vertical direction and rotate 90 degrees
    transverse flop image in the horizontal direction and rotate 270 degrees
    <trim> remove edges that are the background color from the image
    unsharpmaskgeometry="geometry", radius="double", sigma="double", gain="double", threshold="double"sharpen the image with the unsharp mask algorithm.
    vignettegeometry="geometry", radius="double", sigma="double", x="integer", y="integer", background="color name"offset the edges of the image in vignette style
    wavegeometry="geometry", amplitude="double", wavelength="double", interpolate="undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline"alter an image along a sine wave
    whitethresholdthreshold="string", , channel="All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow"force all pixels above the threshold intensity into white
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/connected-components.html b/ImageMagick-7.0.0-0/www/connected-components.html deleted file mode 100644 index 821cac0d3..000000000 --- a/ImageMagick-7.0.0-0/www/connected-components.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - - - ImageMagick: Connected Components Labeling - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Connected-component labeling (alternatively connected-component analysis, blob extraction, region labeling, blob discovery, or region extraction) uniquely labels connected components in an image. The labeling process scans the image, pixel-by-pixel from top-left to bottom-right, in order to identify connected pixel regions, i.e. regions of adjacent pixels which share the same set of intensity values. For example, let's find the objects in this image:

    -
      - purse -
    -

    To identify the objects in this image, use this command:

    -
    -convert objects.gif -connected-components 4 -auto-level -depth 8 objects.png
    -
    -

    The detected objects are uniquely labeled. Use auto leveling to visualize the detected objects:

    -
      - Objects -
    -

    Object statistics is useful to review. To display them, use this command:

    -
    -convert objects.gif -define connected-components:verbose=true -connected-components 4 objects.png
    -
    -

    Five objects were detected in the source image with these statistics:

    -
    -Objects (id: bounding-box centroid area mean-color):
    -  0: 256x171+0+0 119.2,80.8 33117 srgb(0,0,0)
    -  2: 120x135+104+18 159.5,106.5 8690 srgb(255,255,255)
    -  3: 50x36+129+44 154.2,63.4 1529 srgb(0,0,0)
    -  4: 21x23+0+45 8.8,55.9 409 srgb(255,255,255)
    -  1: 4x10+252+0 253.9,4.1 31 srgb(255,255,255)
    -
    -

    Use -connected-components 8 to visit 8 neighbors rather than 4. By default, neighbor colors must be exact to be part of a unique object. Use the -fuzz option to include pixels as part of an object that are close in color.

    -

    You might want to eliminate small objects by merging them with their larger neighbors. If so, use this command:

    -
    -convert objects.gif -define connected-components:area-threshold=410 -connected-components 4 \
    -  -auto-level objects.jpg
    -
    -

    Here are the expected results. Notice, how the small objects are now merged with the background.

    -
      - Objects -
    -

    Notice how two of the objects were merged leaving three remaining objects:

    -
    -Objects (id: bounding-box centroid area mean-color):
    -  0: 256x171+0+0 118.0,80.4 33557 srgb(0,0,0)
    -  2: 120x135+104+18 159.5,106.5 8690 srgb(255,255,255)
    -  3: 50x36+129+44 154.2,63.4 1529 srgb(0,0,0)
    -
    -

    By default, the labeled image is grayscale. You can instead replace the object color in the labeled image with the mean-color from the source image. Simply add this setting, -define connected-components:mean-color=true, to your command line.

    -

    You may want to remove certain objects by making them transparent. Use -define connected-components:remove=list-of-ids (e.g. -define connected-components:remove=2,4-5). Or use -define connected-components:keep=list-of-ids to keep these objects and make all others transparent.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/contact.html b/ImageMagick-7.0.0-0/www/contact.html deleted file mode 100644 index 57998dec1..000000000 --- a/ImageMagick-7.0.0-0/www/contact.html +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - - - - ImageMagick: Contact the Development Team - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -
    -

    Post here for any of the issues listed below. You can expect a response if your issue is a sponsorship, license, security, or paid support issue. To get a response for any other issue, post to the ImageMagick public forums. For bug reports, post to the issues forum. Note, we do not offer sponsored links nor do we respond to solicitations.

    -
    -

    Contact the Wizards

    -

    Enter this code, -040d70, in the Authenticate field and fill in the remaining fields. Press Send to forward your message to the ImageMagick wizards:

    -
    -
    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

    - - -
    -
    -
    -
    -
    -
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/convert.html b/ImageMagick-7.0.0-0/www/convert.html deleted file mode 100644 index 60a3fce1d..000000000 --- a/ImageMagick-7.0.0-0/www/convert.html +++ /dev/null @@ -1,1307 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Convert - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Use the convert program to convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more. See Command Line Processing for advice on how to structure your convert command or see below for example usages of the command.

    - -

    We list a few examples of the convert command here to illustrate its usefulness and ease of use. To get started, lets convert an image in the JPEG format to PNG:

    - -
    -convert rose.jpg rose.png
    -
    - -

    Next, we reduce the image size before it is written to the PNG format:

    - -
    -convert rose.jpg -resize 50% rose.png
    -
    - - - -

    You can combine multiple image-processing operations to produce complex results:

    - -
    -convert -size 320x85 canvas:none -font Bookman-DemiItalic -pointsize 72 \
    -  -draw "text 25,60 \'Magick\'" -channel RGBA -blur 0x6 -fill darkred -stroke magenta \
    -  -draw "text 20,55 \'Magick\'" fuzzy-magick.png
    -
    - -
      - fuzzy-magick -
    - -

    or here we resize an image with improved quality:

    - -
    -convert input.png -colorspace RGB +sigmoidal-contrast 11.6933 \
    -  -define filter:filter=Sinc -define filter:window=Jinc -define filter:lobes=3 \
    -  -resize 400% -sigmoidal-contrast 11.6933 -colorspace sRGB output.png');
    -
    - -

    You can find additional examples of using convert in Examples of ImageMagick Usage.

    - -

    Option Summary

    - -

    The convert command recognizes these options. Click on an option to get more details about how that option works.

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    -adaptive-blur geometryadaptively blur pixels; decrease effect near edges
    -adaptive-resize geometryadaptively resize image with data dependent triangulation.
    -adaptive-sharpen geometryadaptively sharpen pixels; increase effect near edges
    -adjoinjoin images into a single multi-image file
    -affine matrixaffine transform matrix
    -alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
    -annotate geometry textannotate the image with text
    -antialiasremove pixel-aliasing
    -appendappend an image sequence
    -authenticate valuedecipher image with this password
    -auto-gammaautomagically adjust gamma level of image
    -auto-levelautomagically adjust color levels of image
    -auto-orientautomagically orient image
    -background colorbackground color
    -bench iterationsmeasure performance
    -bias valueadd bias when convolving an image
    -black-threshold valueforce all pixels below the threshold into black
    -blue-primary pointchromaticity blue primary point
    -blue-shift factorsimulate a scene at nighttime in the moonlight
    -blur geometryreduce image noise and reduce detail levels
    -border geometrysurround image with a border of color
    -bordercolor colorborder color
    -brightness-contrast geometryimprove brightness / contrast of the image
    -canny geometryuse a multi-stage algorithm to detect a wide range of edges in the image
    -caption stringassign a caption to an image
    -cdl filenamecolor correct with a color decision list
    -channel typeapply option to select image channels
    -charcoal radiussimulate a charcoal drawing
    -chop geometryremove pixels from the image interior
    -clampset each pixel whose value is below zero to zero and any the pixel whose value is above the quantum range to the quantum range (e.g. 65535) otherwise the pixel value remains unchanged.
    -clipclip along the first path from the 8BIM profile
    -clip-mask filenameassociate clip mask with the image
    -clip-path idclip along a named path from the 8BIM profile
    -clone indexclone an image
    -clutapply a color lookup table to the image
    -connected-components connectivityconnected-components uniquely labeled, choose from 4 or 8 way connectivity
    -contrast-stretch geometryimprove the contrast in an image by `stretching' the range of intensity value
    -coalescemerge a sequence of images
    -colorize valuecolorize the image with the fill color
    -color-matrix matrixapply color correction to the image.
    -colors valuepreferred number of colors in the image
    -colorspace typeset image colorspace
    -combinecombine a sequence of images
    -comment stringannotate image with comment
    -comparecompare image
    -complexoperatorperform complex mathematics on an image sequence
    -compose operatorset image composite operator
    -compositecomposite image
    -compress typeimage compression type
    -contrastenhance or reduce the image contrast
    -convolve coefficientsapply a convolution kernel to the image
    -copy geometry offsetcopy pixels from one area of an image to another
    -crop geometrycrop the image
    -cycle amountcycle the image colormap
    -decipher filenameconvert cipher pixels to plain
    -debug eventsdisplay copious debugging information
    -define format:optiondefine one or more image format options
    -deconstructbreak down an image sequence into constituent parts
    -delay valuedisplay the next image after pausing
    -delete indexdelete the image from the image sequence
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -despecklereduce the speckles within an image
    -direction typerender text right-to-left or left-to-right
    -display serverget image or font from this X server
    -dispose methodlayer disposal method
    -distribute-cache portlaunch a distributed pixel cache server
    -distort type coefficientsdistort image
    -dither methodapply error diffusion to image
    -draw stringannotate the image with a graphic primitive
    -duplicate count,indexesduplicate an image one or more times
    -edge radiusapply a filter to detect edges in the image
    -emboss radiusemboss an image
    -encipher filenameconvert plain pixels to cipher pixels
    -encoding typetext encoding type
    -endian typeendianness (MSB or LSB) of the image
    -enhanceapply a digital filter to enhance a noisy image
    -equalizeperform histogram equalization to an image
    -evaluate operator valueevaluate an arithmetic, relational, or logical expression
    -evaluate-sequence operatorevaluate an arithmetic, relational, or logical expression for an image sequence
    -extent geometryset the image size
    -extract geometryextract area from image
    -family namerender text with this font family
    -features distanceanalyze image features (e.g. contract, correlations, etc.).
    -fftimplements the discrete Fourier transform (DFT)
    -fill colorcolor to use when filling a graphic primitive
    -filter typeuse this filter when resizing an image
    -flattenflatten a sequence of images
    -flipflip image in the vertical direction
    -floodfill geometry colorfloodfill the image with color
    -flopflop image in the horizontal direction
    -font namerender text with this font
    -format stringoutput formatted image characteristics
    -frame geometrysurround image with an ornamental border
    -function nameapply a function to the image
    -fuzz distancecolors within this distance are considered equal
    -fx expressionapply mathematical expression to an image channel(s)
    -gamma valuelevel of gamma correction
    -gaussian-blur geometryreduce image noise and reduce detail levels
    -geometry geometrypreferred size or location of the image
    -gravity typehorizontal and vertical text placement
    -grayscale methodconvert image to grayscale
    -green-primary pointchromaticity green primary point
    -helpprint program options
    -hough-lines geometryidentify lines in the image
    -identifyidentify the format and characteristics of the image
    -iftimplements the inverse discrete Fourier transform (DFT)
    -implode amountimplode image pixels about the center
    -insert indexinsert last image into the image sequence
    -intensity methodmethod to generate an intensity value from a pixel
    -intent typetype of rendering intent when managing the image color
    -interlace typetype of image interlacing scheme
    -interline-spacing valuethe space between two text lines
    -interpolate methodpixel color interpolation method
    -interword-spacing valuethe space between two words
    -kerning valuethe space between two characters
    -kuwahara geometryedge preserving noise reduction filter
    -label stringassign a label to an image
    -lat geometrylocal adaptive thresholding
    -layers methodoptimize or compare image layers
    -level valueadjust the level of image contrast
    -limit type valuepixel cache resource limit
    -linear-stretch geometrylinear with saturation histogram stretch
    -liquid-rescale geometryrescale image with seam-carving
    -list typeColor, Configure, Delegate, Format, Magic, Module, Resource, or Type
    -log formatformat of debugging information
    -loop iterationsadd Netscape loop extension to your GIF animation
    -mask filenameassociate a mask with the image
    -mattecolor colorframe color
    -median radiusapply a median filter to the image
    -mean-shift geometrydelineate arbitrarily shaped clusters in the image
    -metric typemeasure differences between images with this metric
    -mode radiusmake each pixel the 'predominant color' of the neighborhood
    -modulate valuevary the brightness, saturation, and hue
    -momentsdisplay image moments.
    -monitormonitor progress
    -monochrometransform image to black and white
    -morph valuemorph an image sequence
    -morphology method kernelapply a morphology method to the image
    -motion-blur geometrysimulate motion blur
    -negatereplace each pixel with its complementary color
    -noise radiusadd or reduce noise in an image
    -normalizetransform image to span the full range of colors
    -opaque colorchange this color to the fill color
    -ordered-dither NxNordered dither the image
    -orient typeimage orientation
    -page geometrysize and location of an image canvas (setting)
    -paint radiussimulate an oil painting
    -perceptibleset each pixel whose value is less than |epsilon| to -epsilon or epsilon (whichever is closer) otherwise the pixel value remains unchanged.
    -pingefficiently determine image attributes
    -pointsize valuefont point size
    -polaroid anglesimulate a Polaroid picture
    -poly termsbuild a polynomial from the image sequence and the corresponding terms (coefficients and degree pairs).
    -posterize levelsreduce the image to a limited number of color levels
    -precision valueset the maximum number of significant digits to be printed
    -preview typeimage preview type
    -print stringinterpret string and print to console
    -process image-filterprocess the image with a custom image filter
    -profile filenameadd, delete, or apply an image profile
    -quality valueJPEG/MIFF/PNG compression level
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -radial-blur angleradial blur the image
    -raise valuelighten/darken image edges to create a 3-D effect
    -random-threshold low,highrandom threshold the image
    -red-primary pointchromaticity red primary point
    -regard-warningspay attention to warning messages.
    -region geometryapply options to a portion of the image
    -remap filenametransform image colors to match this set of colors
    -renderrender vector graphics
    -repage geometrysize and location of an image canvas
    -resample geometrychange the resolution of an image
    -resize geometryresize the image
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -roll geometryroll an image vertically or horizontally
    -rotate degreesapply Paeth rotation to the image
    -sample geometryscale image with pixel sampling
    -sampling-factor geometryhorizontal and vertical sampling factor
    -scale geometryscale the image
    -scene valueimage scene number
    -seed valueseed a new sequence of pseudo-random numbers
    -segment valuessegment an image
    -selective-blur geometryselectively blur pixels within a contrast threshold
    -separateseparate an image channel into a grayscale image
    -sepia-tone thresholdsimulate a sepia-toned photo
    -set attribute valueset an image attribute
    -shade degreesshade the image using a distant light source
    -shadow geometrysimulate an image shadow
    -sharpen geometrysharpen the image
    -shave geometryshave pixels from the image edges
    -shear geometryslide one edge of the image along the X or Y axis
    -sigmoidal-contrast geometryincrease the contrast without saturating highlights or shadows
    -smush offsetsmush an image sequence together
    -size geometrywidth and height of image
    -sketch geometrysimulate a pencil sketch
    -solarize thresholdnegate all pixels above the threshold level
    -splice geometrysplice the background color into the image
    -spread radiusdisplace image pixels by a random amount
    -statistic type geometryreplace each pixel with corresponding statistic from the neighborhood
    -stripstrip image of all profiles and comments
    -stroke colorgraphic primitive stroke color
    -strokewidth valuegraphic primitive stroke width
    -stretch typerender text with this font stretch
    -style typerender text with this font style
    -swap indexesswap two images in the image sequence
    -swirl degreesswirl image pixels about the center
    -synchronizesynchronize image to storage device
    -taintmark the image as modified
    -texture filenamename of texture to tile onto the image background
    -threshold valuethreshold the image
    -thumbnail geometrycreate a thumbnail of the image
    -tile filenametile image when filling a graphic primitive
    -tile-offset geometryset the image tile offset
    -tint valuetint the image with the fill color
    -transformaffine transform image
    -transparent colormake this color transparent within the image
    -transparent-color colortransparent color
    -transposeflip image in the vertical direction and rotate 90 degrees
    -transverseflop image in the horizontal direction and rotate 270 degrees
    -treedepth valuecolor tree depth
    -trimtrim image edges
    -type typeimage type
    -undercolor colorannotation bounding box color
    -unique-colorsdiscard all but one of any pixel color.
    -units typethe units of image resolution
    -unsharp geometrysharpen the image
    -verboseprint detailed information about the image
    -versionprint version information
    -viewFlashPix viewing transforms
    -vignette geometrysoften the edges of the image in vignette style
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    -wave geometryalter an image along a sine wave
    -weight typerender text with this font weight
    -white-point pointchromaticity white point
    -white-threshold valueforce all pixels above the threshold into white
    -write filenamewrite images to this file
    -
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/display.html b/ImageMagick-7.0.0-0/www/display.html deleted file mode 100644 index d68e7671a..000000000 --- a/ImageMagick-7.0.0-0/www/display.html +++ /dev/null @@ -1,565 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Display - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    Use the display program to display an image or image sequence on any X server. See Command Line Processing for advice on how to structure your display command or see below for example usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the display command here to illustrate its usefulness and ease of use. To get started, lets display an image in the JPEG format:

    - -
    -display rose.jpg
    -
    - -

    To tile a slate texture onto the root window, use:

    - -
    -display -size 1280x1024 -window root slate.png
    -
    - -

    To display a visual image directory of all your JPEG images, use:

    - -
    -display 'vid:*.jpg'
    -
    - -

    The display program defaults to the X screen resolution. To display vecotr formats at their intended size, override the default resolution:

    - -
    -display -density 72 drawing.svg
    -
    - -

    You can find additional examples of using display in Graphics from the Command Line. Further discussion is available in More Graphics from the Command Line and Examples of ImageMagick Usage.

    - - -

    Option Summary

    - -

    The display command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
    -antialiasremove pixel-aliasing
    -authenticate valuedecrypt image with this password
    -backdropdisplay image centered on a backdrop
    -background colorbackground color
    -border geometrysurround image with a border of color
    -bordercolor colorborder color
    -channel typeapply option to select image channels
    -clipclip along the first path from the 8BIM profile
    -clip-path idclip along a named path from the 8BIM profile
    -coalescemerge a sequence of images
    -colormap typeShared or Private
    -colors valuepreferred number of colors in the image
    -colorspace typeset image colorspace
    -comment stringannotate image with comment
    -compress typeimage compression type
    -contrastenhance or reduce the image contrast
    -crop geometrypreferred size and location of the cropped image
    -debug eventsdisplay copious debugging information
    -decipher filenameconvert cipher pixels to plain
    -define format:optiondefine one or more image format options
    -delay valuedisplay the next image after pausing
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -despecklereduce the speckles within an image
    -display serverget image or font from this X server
    -dispose methodlayer disposal method
    -dither methodapply error diffusion to image
    -edge radiusapply a filter to detect edges in the image
    -endian typeendianness (MSB or LSB) of the image
    -enhanceapply a digital filter to enhance a noisy image
    -equalizeperform histogram equalization to an image
    -extract geometryextract area from image
    -filter typeuse this filter when resizing an image
    -flattenflatten a sequence of images
    -flipflip image in the vertical direction
    -flopflop image in the horizontal direction
    -frame geometrysurround image with an ornamental border
    -fuzz distancecolors within this distance are considered equal
    -gamma valuelevel of gamma correction
    -geometry geometrypreferred size or location of the image
    -gravity geometryhorizontal and vertical backdrop placement
    -helpprint program options
    -identifyidentify the format and characteristics of the image
    -immutable typeprohibit image edits
    -interlace typetype of image interlacing scheme
    -interpolate methodpixel color interpolation method
    -label nameassign a label to an image
    -limit type valuepixel cache resource limit
    -log formatformat of debugging information
    -map filenametransform image colors to match this set of colors
    -mattecolor colorframe color
    -monitormonitor progress
    -monochrometransform image to black and white
    -negatereplace each pixel with its complementary color
    -normalizetransform image to span the full range of colors
    -page geometrysize and location of an image canvas (setting)
    -profile filenameadd, delete, or apply an image profile
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -raise valuelighten/darken image edges to create a 3-D effect
    -regard-warningspay attention to warning messages.
    -remote commandexecute a command in an remote display process
    -resample geometrychange the resolution of an image
    -resize geometryresize the image
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -roll geometryroll an image vertically or horizontally
    -rotate degreesapply Paeth rotation to the image
    -sample geometryscale image with pixel sampling
    -sampling-factor geometryhorizontal and vertical sampling factor
    -scene valueimage scene number
    -seed valueseed a new sequence of pseudo-random numbers
    -segment valuessegment an image
    -set attribute valueset an image attribute
    -sharpen geometrysharpen the image
    -size geometrywidth and height of image
    -stripstrip image of all profiles and comments
    -thumbnail geometrycreate a thumbnail of the image
    -transparent-color colortransparent color
    -black-threshold valueforce all pixels below the threshold into black
    -trimtrim image edges
    -update secondsdetect when image file is modified and redisplay
    -verboseprint detailed information about the image
    -versionprint version information
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    -visualdisplay image using this visual type
    -window iddisplay image to background of this window
    -window-group idexit program when this window id is destroyed
    -write filenamewrite images to this file
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/distribute-pixel-cache.html b/ImageMagick-7.0.0-0/www/distribute-pixel-cache.html deleted file mode 100644 index 438d2c19c..000000000 --- a/ImageMagick-7.0.0-0/www/distribute-pixel-cache.html +++ /dev/null @@ -1,85 +0,0 @@ - - - - - - - - - ImageMagick: Distributed Pixel Cache - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    A distributed pixel cache is an extension of the traditional pixel cache available on a single host. The distributed pixel cache may span multiple servers so that it can grow in size and transactional capacity to support very large images or large image sequences. Start up the pixel cache server on one or more hosts. When you read or operate on an image and the local pixel cache resources are exhausted, ImageMagick contacts one or more of these remote pixel servers to store or retrieve pixels.

    -

    For really large images or large image sequences, or if there is limited resources on your host, you can utilize a distributed pixel cache on one or more remote hosts. Here we create two distributed pixel caches and utilize them from our desktop:

    -
    -convert -distribute-cache 6668 &  # start on 192.168.100.50
    -convert -distribute-cache 6668 &  # start on 192.168.100.51
    -convert -limit memory 1GiB -limit map 2GiB -limit disk 4GiB \
    -  -define registry:cache:hosts=192.168.100.50:6668,192.168.100.51:6668 \
    -  myhugeimage.jpg -sharpen 5x2 myhugeimage.png
    -
    -

    For large image sequences, the servers are contacted in a round-robin fashion to distribute the load over multiple distributed pixel caches (assuming you have a host list rather than a single host). In our example, some modest resources are available on the desktop as defined by the -limit option. For smaller images, they are allocated on the desktop up to the specified limits.

    -

    Your image processing tasks are likely to perform slower when utilizing a distributed pixel cache due to pixels shuffling between the client and the server over a network. Algorithms that access virtual pixels (e.g. -sharpen) are noticeably slower, up to 3 times slower, than algorithms that only access authentic pixels (e.g. -negate) due to increased network traffic.

    -

    A client can only contact a compatible distributed pixel cache server. Compatibility requires the same ImageMagick library interface, quantum depth, HDRI status, OS word size, and endianness. The distributed pixel cache checks these attributes and exits if these requirements are not met.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/download.html b/ImageMagick-7.0.0-0/www/download.html deleted file mode 100644 index d11d0d8ed..000000000 --- a/ImageMagick-7.0.0-0/www/download.html +++ /dev/null @@ -1,110 +0,0 @@ - - - - - - - - - ImageMagick: Downloads - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    ImageMagick source and binary distributions are available from a variety of FTP and Web mirrors around the world listed below. ImageMagick stable and development source releases are also available from Git. Before you download, you may want to review recent changes to the ImageMagick distribution. The authoritative source code repository is http://git.imagemagick.org/repos/ImageMagick.

    -

    The latest release of ImageMagick is version 7.0.0-0.

    -
    -
    Germany
    -
    http://mirror.checkdomain.de/imagemagick/
    -
    ftp://mirror.checkdomain.de/imagemagick/
    -
    Japan
    -
    ftp://ftp.kddlabs.co.jp/graphics/ImageMagick/
    -
    ftp://ftp.u-aizu.ac.jp/pub/graphics/images/ImageMagick/imagemagick.org
    -
    Netherlands
    -
    ftp://ftp.nluug.nl/pub/ImageMagick
    -
    http://ftp.nluug.nl/ImageMagick/
    -
    Poland
    -
    ftp://sunsite.icm.edu.pl/packages/ImageMagick/
    -
    ftp://ftp.tpnet.pl/pub/graphics/ImageMagick/
    -
    rsync://ftp.tpnet.pl/pub/graphics/ImageMagick/
    -
    Sweden
    -
    ftp://ftp.sunet.se/pub/multimedia/graphics/ImageMagick
    -
    South Africa
    -
    http://imagemagick.afri.cc/
    -
    United States
    -
    http://www.imagemagick.org/download
    -
    http://transloadit.imagemagick.org/download
    -
    ftp://transloadit.imagemagick.org/pub/ImageMagick (ftp)
    -
    ftp://ftp.fifi.org/pub/ImageMagick/ (ftp)
    -
    http://git.imagemagick.org/repos/ImageMagick (Git)
    -
    https://github.com/ImageMagick/ImageMagick (Git Mirror)
    -
    Select Binaries
    -
    http://www.macports.org/ports.html?by=name&substr=imagemagick (Mac OS X)
    -
    http://hpux.connect.org.uk/hppd/hpux/X11/Viewers/ (HP-UX 10.20 and 11.00)
    -
    Rsync Mirrors
    -
    rsync://rsync.is.co.za/IS-Mirror/mirror.imagemagick.org/
    -
    rsync://rsync.fifi.org/ImageMagick
    -
    rsync://mirror.imagemagick.org/magick_html/ (Web site mirror)
    -
    rsync://mirror.imagemagick.org/magick_ftp/ (FTP mirror)
    -
    -

    If you want to add a new mirror, please contact us.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/escape.html b/ImageMagick-7.0.0-0/www/escape.html deleted file mode 100644 index 6d2d71e9d..000000000 --- a/ImageMagick-7.0.0-0/www/escape.html +++ /dev/null @@ -1,851 +0,0 @@ - - - - - - - - - ImageMagick: Format and Print Image Properties - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    There are copious amounts of extra data associated with images (metadata), beyond the actual image pixels. This metadata can be useful, either for display, or for various calculations, or in modifying the behavior of later image processing operations. You can utilize percent escapes in a number of options, for example in -format or in montage -label, to print various properties and other settings associated with an image.

    - -
    - - - - - - - - - - - - - - - - -
    Profile DataSuch as EXIF: data, containing focal lengths, exposures, dates, and in - come cases GPS locations. -
    AttributesThese are directly involved with image data, and more commonly - modified as part of normal image processing. These include - width, height, depth, image type (colorspace), timing delays, and - background color. Most specific percent escapes is to access this - information. -
    PropertiesThese are stored as a table of free form strings, and are (if possible) - saved with the image (especially in MIFF and PNG image file formats). - These include: Labels, Captions, Comments. -
    ArtifactsThese are various operational (expert) settings that are saved for - use by various operators, or by the user for future use. It is just - a table of free-form strings. They are not saved with the image when - written. See Artifacts and Options below for details. -
    OptionsAlso operational (expert) settings that are saved for - use by various operators, but are set globally for use by a whole - image list (also not saved). See Artifacts and Options below. -
    - -

    Percent Escape Handling

    - -

    If you request a percent escape such as %[key] the setting -is looked for in the following order until the first match has been -found...

    - -
      -
    1. Handle special prefixes such as 'artifact:' 'option:' 'exif:', or - 'fx:'. This includes and calculations and or globs of those prefixes such - as 'exif:*' or 'artifact:*' (see below).
    2. - -
    3. If key contains a glob pattern (but no known prefix) - search free-form properties table.
    4. - -
    5. If key is a special image 'attribute' name (see list - above) return the associated or calculated image attribute.
    6. - -
    7. Search for setting as a free-form 'property'
    8. -
    9. Search for setting as a free-form 'artifact'
    10. -
    11. Search for setting as a free-form 'option'
    12. - -
    13. Replace escape with empty string, and perhaps produce a warning.
    14. -
    - -

    Remember, all long name forms of percent escapes are handled in a is case -insensitive manner.

    - -

    As of IM v6.8.0-5 you can now access the Artifact and Option -free-form string tables directly, allowing you to override the above sequence, -and avoid accessing an attribute or property of the same name.

    - -
    -%[artifact:setting]
    -%[option:setting]
    -
    - - -

    Single Letter Attribute Percent Escapes

    - -

    Here are common single letter escapes (short form) is used to report the most -common attributes and properties of an image, such as: the image filename -filename, type, width, height.

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    \nnewline
    \rcarriage return
    <less-than character.
    >greater-than character.
    &ampersand character.
    %%a percent sign
    %bfile size of image read in
    %ccomment meta-data property
    %ddirectory component of path
    %efilename extension or suffix
    %ffilename (including suffix)
    %glayer canvas page geometry (equivalent to "%Wx%H%X%Y")
    %hcurrent image height in pixels
    %iimage filename (note: becomes output filename for "info:")
    %kCALCULATED: number of unique colors
    %llabel meta-data property
    %mimage file format (file magic)
    %nnumber of images in current image sequence
    %ooutput filename (used for delegates)
    %pindex of image in current image list
    %qquantum depth (compile-time constant)
    %rimage class and colorspace
    %sscene number (from input unless re-assigned)
    %tfilename without directory or extension (suffix)
    %uunique temporary filename (used for delegates)
    %wcurrent width in pixels
    %xx resolution (density)
    %yy resolution (density)
    %zimage depth (as read in unless modified, image save depth)
    %Aimage transparency channel enabled (true/false)
    %Cimage compression type
    %Dimage GIF dispose method
    %Goriginal image size (%wx%h; before any resizes)
    %Hpage (canvas) height
    %MMagick filename (original file exactly as given, including read mods)
    %Opage (canvas) offset ( = %X%Y )
    %Ppage (canvas) size ( = %Wx%H )
    %Qimage compression quality ( 0 = default )
    %S?? scenes ??
    %Timage time delay (in centi-seconds)
    %Uimage resolution units
    %Wpage (canvas) width
    %Xpage (canvas) x offset (including sign)
    %Ypage (canvas) y offset (including sign)
    %Zunique filename (used for delegates)
    %@CALCULATED: trim bounding box (without actually trimming)
    %#CALCULATED: 'signature' hash of image values
    - -

    Here is a sample command and its output for an image with filename -bird.miff and whose width is 512 and height is 480.

    - -
    --> identify -format "%m:%f %wx%h" bird.miff
    -MIFF:bird.miff 512x480
    -
    - -

    Note that all single letter percent escapes can also be used using long -form (from IM version 6.7.6-9, see next). For example %[f] is -equivalent to the %f short form.

    - -

    WARNING: short form percent escapes are NOT performed when the percent -is after a number. For example, 10%x10 does not expand the -%x as a percent escape. If you specifically want to expand the -'x', use the long form which overrides this special case. EG: -10%[x]10.

    - -

    Also be warned that calculated attributes can take some time to generate, -especially for large images.

    - -

    Long Form Attribute Percent Escapes

    - -

    In addition to the above specific and calculated attributes are recognized -when enclosed in braces (long form):

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    %[base]base filename, no suffixes (as %t)
    %[channels]??? channels in use - colorspace ???
    %[colorspace]Colorspace of Image Data (excluding transparency)
    %[copyright]ImageMagick Copyright String
    %[depth]depth of image for write (as input unless changed)
    %[deskew:angle]The deskew angle in degrees of rotation
    %[directory]directory part of filename (as %d)
    %[distortion]how well an image resembles a reference image (-compare)
    %[entropy]CALCULATED: entropy of the image
    %[extension]extension part of filename (as %e)
    %[gamma]value of image gamma
    %[group]??? window group ???
    %[height]original height of image (when it was read in)
    %[kurtosis]CALCULATED: kurtosis statistic of image
    %[label]label meta-data property
    %[magick]coder used to read image (not the file suffix)
    %[max]CALCULATED: maximum value statistic of image
    %[mean]CALCULATED: average value statistic of image
    %[min]CALCULATED: minimum value statistic of image
    %[name]The original name of the image
    %[opaque]CALCULATED: is image fully-opaque?
    %[orientation]image orientation
    %[page]Virtual canvas (page) geometry
    %[profile:icc]ICC profile info
    %[profile:icm]ICM profile info
    %[profiles]list of any embedded profiles
    %[resolution.x]X density (resolution) without units
    %[resolution.y]Y density (resolution) without units
    %[scene]original scene number of image in input file
    %[size]original size of image (when it was read in)
    %[skewness]CALCULATED: skewness statistic of image
    %[standard-deviation]CALCULATED: standard deviation statistic of image
    %[type]CALCULATED: image type
    %[unique]unique temporary filename ???
    %[units]image resolution units
    %[version]Version Information of this running ImageMagick
    %[width]original width of image (when it was read in)
    %[zero]zero (unique filename for delegate use)
    - -

    Properties

    - -

    All other long forms of percent escapes (not single letter long form) are -handled in a case insensitive manner. Such escapes will will attempt to look -up that name specific data sources.

    - -

    The primary search space (if not a specific attribute listed above) is -a free-form property string. Such strings are associated and saved with -images, and are typically set using either the -set -CLI option (or API equivalent), or from special convenience options -(such as -label, -comment, -caption).

    - -

    These convenience options are globally saved (as 'global options' so thay can -be set before images are read), and later are transfered to the property of -individual images, only when they are read in. At that time any internal -percent escape present is then handled.

    - -

    To change a property of an image already in memory, you need to use -set. -

    - -

    Note that properties, like attributes (and profiles), are saved with -images when write, if the image file format allows.

    - - -

    Artifacts and Options

    - -

    The previous percent escapes are associated with the primary Attributes and -Properties. Which is the original and primary focus of such percent escapes. -

    - -

    However there are many operational settings that are used by various -ImageMagick operators that can be useful to set and later access. These -consist of per-image Artifacts, and Global options (associated with a list of -images, typically the current image list).

    - -

    Note that the major difference between an artifact and a property is that -artifacts, being an internal operational setting, is not saved with images (if -such is possible).

    - -

    For example when you use -define 'distort:viewport=100x100' you -are in fact generating a global option, which the -distort operator will use to modify its behavior (distorted output -image 'view').

    - -

    An Option is essentually a Artifact that has been stored globally as part -of a list of images (specifically a 'Wand' of images). As such they are -identical, in that a Option, is simply a global Artifact for all the -associated images.

    - -

    As such you can use -set 'option:distort:viewport' '100x100' to -achieve the same result of setting a Artifact for the disort operation to use. -

    - -

    Internal Handling of a Global Option...

    - -

    The Core library ('MagickCore') does not generally directly understand -Global Options. As such, continuing the previous example, the -DistortImages() function only looks up an artifact to discover if -a 'viewport' has been provided to it.

    - -

    How Global Options are used when a library function requests an Artifact is -one of the key differences between IMv6 and IMv7.

    - -

    In ImageMagick version 6... before each operator, any global Options -are copied to per-image Artifacts, for every image in the current image list. -This allows various operators to find its operational 'defines' or Artifacts. -

    - -

    In ImageMagick version 7... sets a link back to the global options -data, so that if a specific per-image Artifact is not found , then it will -look for a equivalent global Option for that image list. directly. This -saves coping these free-form options into artifacts repeatally, and means you -can now separately define a global option for a list, and a individual -overriding artifact for a specific image in that list.

    - -

    Note that many API's that do not use Wands (PerlMagick for example using -arrays of images rather than a Wand). In these API's you will not have Global -Options, only per-image Artifacts.

    - -

    In summery a Global Option, if available, is equivalent to a per-image -Artifact.

    - - -

    Glob-Pattern Listing of Properties, Artifacts and Options

    - -

    The setting can contain a glob pattern. As such you can -now list all free-form string properties, artifacts, and options, (but not -specific image attributes) using...

    - -
    -convert ... \
    -   -print "__Properties__\n%[*]" \
    -   -print "__Artifacts__\n%[artifact:*]" \
    -   -print "__Options__\n%[option:*]" \
    -   ...
    -
    - -

    The format of glob patterns are very specific and as such is generally -only used to list specific settings, such as when debugging, rather than being -used for image processing use.

    - - -

    Calculated Percent Escape Prefixes

    - -

    There are some special prefixes (before the first ':') which performs -calculations based on the user provided string that follows that prefix. For -example you can do a numerical calculation use %[fx:...] to -evaluate the given FX expressions:

    - -
    -%[fx:expression]
    -
    - -

    Use pixel: to evaluate a pixel color as defined by the FX -expression:

    - -
    -%[pixel:expression]
    -
    - -

    Specific Profile Percent Escape Prefixes

    - -

    You can also use the following special formatting syntax to print EXIF -mage meta-data that was included in the image read in:

    - -
    -%[EXIF:tag]
    -
    - -

    Choose tag from the following:

    - -
    -*  (print all EXIF tags, in keyword=data format)
    -!  (print all EXIF tags, in tag_number data format)
    -#hhhh (print data for EXIF tag #hhhh)
    -ImageWidth
    -ImageLength
    -BitsPerSample
    -Compression
    -PhotometricInterpretation
    -FillOrder
    -DocumentName
    -ImageDescription
    -Make
    -Model
    -StripOffsets
    -Orientation
    -SamplesPerPixel
    -RowsPerStrip
    -StripByteCounts
    -XResolution
    -YResolution
    -PlanarConfiguration
    -ResolutionUnit
    -TransferFunction
    -Software
    -DateTime
    -Artist
    -WhitePoint
    -PrimaryChromaticities
    -TransferRange
    -JPEGProc
    -JPEGInterchangeFormat
    -JPEGInterchangeFormatLength
    -YCbCrCoefficients
    -YCbCrSubSampling
    -YCbCrPositioning
    -ReferenceBlackWhite
    -CFARepeatPatternDim
    -CFAPattern
    -BatteryLevel
    -Copyright
    -ExposureTime
    -FNumber
    -IPTC/NAA
    -EXIFOffset
    -InterColorProfile
    -ExposureProgram
    -SpectralSensitivity
    -GPSInfo
    -ISOSpeedRatings
    -OECF
    -EXIFVersion
    -DateTimeOriginal
    -DateTimeDigitized
    -ComponentsConfiguration
    -CompressedBitsPerPixel
    -ShutterSpeedValue
    -ApertureValue
    -BrightnessValue
    -ExposureBiasValue
    -MaxApertureValue
    -SubjectDistance
    -MeteringMode
    -LightSource
    -Flash
    -FocalLength
    -MakerNote
    -UserComment
    -SubSecTime
    -SubSecTimeOriginal
    -SubSecTimeDigitized
    -FlashPixVersion
    -ColorSpace
    -EXIFImageWidth
    -EXIFImageLength
    -InteroperabilityOffset
    -FlashEnergy
    -SpatialFrequencyResponse
    -FocalPlaneXResolution
    -FocalPlaneYResolution
    -FocalPlaneResolutionUnit
    -SubjectLocation
    -ExposureIndex
    -SensingMethod
    -FileSource
    -SceneType
    -
    -
    -

    Surround the format specification with quotation marks to prevent your -shell from misinterpreting any spaces and square brackets.

    - -

    The following special formatting syntax can be used to print IPTC -information contained in the file:

    - -
    -%[IPTC:dataset:record]
    -
    - -

    Select dataset and record from the following:

    - -
    -  Envelope Record
    -  1:00  Model Version
    -  1:05  Destination
    -  1:20  File Format
    -  1:22  File Format Version
    -  1:30  Service Identifier
    -  1:40  Envelope Number
    -  1:50  Product ID
    -  1:60  Envelope Priority
    -  1:70  Date Sent
    -  1:80  Time Sent
    -  1:90  Coded Character Set
    -  1:100  UNO (Unique Name of Object)
    -  1:120  ARM Identifier
    -  1:122  ARM Version
    -
    -Application Record
    -  2:00  Record Version
    -  2:03  Object Type Reference
    -  2:05  Object Name (Title)
    -  2:07  Edit Status
    -  2:08  Editorial Update
    -  2:10  Urgency
    -  2:12  Subject Reference
    -  2:15  Category
    -  2:20  Supplemental Category
    -  2:22  Fixture Identifier
    -  2:25  Keywords
    -  2:26  Content Location Code
    -  2:27  Content Location Name
    -  2:30  Release Date
    -  2:35  Release Time
    -  2:37  Expiration Date
    -  2:38  Expiration Time
    -  2:40  Special Instructions
    -  2:42  Action Advised
    -  2:45  Reference Service
    -  2:47  Reference Date
    -  2:50  Reference Number
    -  2:55  Date Created
    -  2:60  Time Created
    -  2:62  Digital Creation Date
    -  2:63  Digital Creation Time
    -  2:65  Originating Program
    -  2:70  Program Version
    -  2:75  Object Cycle
    -  2:80  By-Line (Author)
    -  2:85  By-Line Title (Author Position) [Not used in Photoshop 7]
    -  2:90  City
    -  2:92  Sub-Location
    -  2:95  Province/State
    -  2:100  Country/Primary Location Code
    -  2:101  Country/Primary Location Name
    -  2:103  Original Transmission Reference
    -  2:105  Headline
    -  2:110  Credit
    -  2:115  Source
    -  2:116  Copyright Notice
    -  2:118  Contact
    -  2:120  Caption/Abstract
    -  2:122  Caption Writer/Editor
    -  2:125  Rasterized Caption
    -  2:130  Image Type
    -  2:131  Image Orientation
    -  2:135  Language Identifier
    -  2:150  Audio Type
    -  2:151  Audio Sampling Rate
    -  2:152  Audio Sampling Resolution
    -  2:153  Audio Duration
    -  2:154  Audio Outcue
    -  2:200  ObjectData Preview File Format
    -  2:201  ObjectData Preview File Format Version
    -  2:202  ObjectData Preview Data
    -
    -Pre-ObjectData Descriptor Record
    -  7:10   Size Mode
    -  7:20   Max Subfile Size
    -  7:90   ObjectData Size Announced
    -  7:95   Maximum ObjectData Size
    -
    -ObjectData Record
    -  8:10   Subfile
    -
    -Post ObjectData Descriptor Record
    -  9:10   Confirmed ObjectData Size
    -
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/examples.html b/ImageMagick-7.0.0-0/www/examples.html deleted file mode 100644 index fb4f574fa..000000000 --- a/ImageMagick-7.0.0-0/www/examples.html +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - ImageMagick: Examples of ImageMagick Usage - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Here are a few examples of what you can do with an image using ImageMagick from the command line, a program interface, or script. You can generate this image yourself with this PerlMagick script, examples.pl.

    - -

    [ImageMagick Examples]

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/exception.html b/ImageMagick-7.0.0-0/www/exception.html deleted file mode 100644 index a7a4b2364..000000000 --- a/ImageMagick-7.0.0-0/www/exception.html +++ /dev/null @@ -1,265 +0,0 @@ - - - - - - - - - ImageMagick: Exceptions - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    ImageMagick returns a status of 0 whenever a command or algorithm successfully complete without complaint. A warning code generally is typically just a notice that something unusual occurred but the command or algorithm still completed and most likely the results are still usable. An error means the command or algorithm could not complete as expected and any results are unreliable. A fatal error means the command or algorithm could not complete and the process exits prematurely and no results are returned.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    ImageMagick Error and Warning Codes
    DomainDescriptionWarningErrorFatal Error
    Successthe command or algorithm completed successfully without complaint000
    Resource Limita program resource is exhausted (e.g. not enough memory)300400700
    TypeA font is unavailable; a substitution may have occurred305405705
    Optiona command-line option was malformed310410710
    Delegatean ImageMagick delegate failed to complete315415715
    Missing Delegatethe image type can not be read or written because the appropriate Delegate is missing320420720
    Corrupt Imagethe image file may be corrupt325425725
    FileOpenthe image file could not be opened for reading or writing330430730
    Bloba binary large object could not be allocated, read, or written335435735
    Streamthere was a problem reading or writing from a stream340440740
    Cachepixels could not be read or written to the pixel cache345445745
    Coderthere was a problem with an image coder350450750
    Modulethere was a problem with an image module355455755
    Drawa drawing operation failed360460760
    Imagethe operation could not complete due to an incompatible image365465765
    Wandthere was a problem specific to the MagickWand API370470770
    Randomthere is a problem generating a true or pseudo-random number375475775
    XServeran X resource is unavailable380480780
    Monitorthere was a problem activating the progress monitor385485785
    Registrythere was a problem getting or setting the registry390490790
    Configurethere was a problem getting a configuration file395495795
    Policya policy denies access to a delegate, coder, filter, path, or resource.399499799
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/export.html b/ImageMagick-7.0.0-0/www/export.html deleted file mode 100644 index 5f974a238..000000000 --- a/ImageMagick-7.0.0-0/www/export.html +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - ImageMagick: Export Classification - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    ImageMagick Studio LLC is a limited liability corporation based in the United States of America. All of our products are developed via online collaboration in public forums and distributed from a central server within the U.S. Therefore, U.S. export laws and regulations apply to our distributions and remain in force as products and technology are re-exported to different parties and places around the world. Information on export control classifications and associated restrictions may be required for exporting, re-exporting, record keeping, bundling/embedding of ImageMagick products, encryption reporting, and shipping documentation. More information on U.S. Export Regulations can be found at the U. S. Bureau of Industry and Security.

    - -

    The ImageMagick software distribution is classified as ECCN 5D002. However, ImageMagick Studio LLC makes no warranty or representation that this classification is accurate, current, or complete. ImageMagick is exported under the TSU exception in EAR 740.13(e) which applies to software containing or designed for use with encryption software that is publicly available as open source. TSU further provides that Posting encryption source code and corresponding object code on the Internet (e.g., FTP or World Wide Web site) where it may be downloaded by anyone neither establishes "knowledge" of a prohibited export or reexport for purposes of this paragraph, nor triggers any "red flags" necessitating the affirmative duty to inquire[...]. It is your obligation as the exporter to comply with the current applicable requirements of United States export rules and regulations.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/formats.html b/ImageMagick-7.0.0-0/www/formats.html deleted file mode 100644 index 1cb0f8072..000000000 --- a/ImageMagick-7.0.0-0/www/formats.html +++ /dev/null @@ -1,1928 +0,0 @@ - - - - - - - - - ImageMagick: Formats - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    A Word about Colorspaces • Supported Formats • Pseudo Formats • Built-in Images • Built-in Patterns • Embedded Profiles

    - -

    ImageMagick uses an ASCII string known as magick (e.g. GIF) to identify file formats, algorithms acting as formats, built-in patterns, and embedded profile types. Support for some of the formats are delegated to libraries or external programs. The Installation Guide describes where to find these distributions and any special configuration options required.

    - -

    To get a complete listing of which image formats are supported on your system, type

    - -
    -identify -list format
    -
    - -

    On some platforms, ImageMagick automagically processes these extensions: .gz for Zip compression, .Z for Unix compression, .bz2 for block compression, and .pgp for PGP encryption. For example, a PNM image called image.pnm.gz is automagically uncompressed.

    - -

    A Word about Colorspaces

    -

    A majority of the image formats assume an sRGB -colorspace (e.g. JPEG, PNG, etc.). A few support only linear RGB (e.g. EXR, -DPX, CIN, HDR) or only linear GRAY (e.g. PGM). A few formats support CMYK. -Then there is the occasional format that also supports LAB (that is CieLAB) -(e.g. TIFF, PSD, JPG, JP2). To determine the colorspace of your image, use -this command:

    - -
    --> identify -verbose image.jpg
    -Image: image.jpg
    -Format: JPEG (Joint Photographic Experts Group JFIF format)
    -...
    -Colorspace: sRGB
    -
    - -OR use the appropriate percent escape -
    --> convert image.jpg -print "%[colorspace]\n" null:
    -sRGB
    -
    - - -

    When processing an image, be aware of the colorspace. Many image -processing algorithms assume a linear RGB colorspace. Although you may get -satisfactory results processing in the sRGB colorspace, you may get improved -results in linear RGB (essentially sRGB with the gamma function removed). For -example,

    - -
    -convert image.jpg -colorspace RGB -resize 50% -colorspace sRGB resize.jpg
    -
    - -

    As of IM 6.7.8-2 one can properly work in LAB colorspace whether or not -Imagemagick is HDRI-enabled. Essentually the A and -B channels are stored with a 50% gray bias, to allow it to handle the -negatives required by the format.

    - -
    -convert lab.tif -resize 50% resize.jpg
    -
    - -

    Again, it may not make sense for some image processing operators to work -directly in LAB space, but ImageMagick permits it and generally returns -reasonable results.

    - -

    Prior to IM 6.7.8-2, the A and B channels has a discontinuity, making them -non-linear. As such to process such images, you needed to first convert the -colorspace some other linear colorspace, before apply your processing -operator. Afterward you can transform back to the LAB colorspace. For -example,

    - -
    -  convert lab.tif -colorspace RGB -resize 50% -colorspace Lab resize.jpg
    -
    - -

    Supported Image Formats

    - -

    ImageMagick supports reading over 100 major file formats (not -including sub-formats). The following table provides a summary of -the supported image formats.

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TagModeDescriptionNotes
    AAIRWAAI Dune image
    ARTRWPFS: 1st PublisherFormat originally used on the Macintosh (MacPaint?) and later used for PFS: 1st Publisher clip art.
    ARWRSony Digital Camera Alpha Raw Image Format
    AVIRMicrosoft Audio/Visual Interleaved
    AVSRWAVS X image
    BPGRWBetter Portable GraphicsUse -quality to specify the image compression quality. To meet the requirements of BPG, the quality argument divided by 2 (e.g. -quality 92 assigns 46 as the BPG compression.
    BMP, BMP2, BMP3RWMicrosoft Windows bitmapBy default the BMP format is version 4. Use BMP3 and BMP2 to write versions 3 and 2 respectively.
    CALSRContinuous Acquisition and Life-cycle Support Type 1 imageSpecified in MIL-R-28002 and MIL-PRF-28002. Standard blueprint archive format as used by the US military to replace microfiche.
    CGMRComputer Graphics MetafileRequires ralcgm to render CGM files.
    CINRWKodak Cineon Image FormatUse -set to specify the image gamma or black and white points (e.g. -set gamma 1.7, -set reference-black 95, -set reference-white 685). Properties include cin:file.create_date, cin:file.create_time, cin:file.filename, cin:file.version, cin:film.count, cin:film.format, cin:film.frame_id, cin:film.frame_position, cin:film.frame_rate, cin:film.id, cin:film.offset, cin:film.prefix, cin:film.slate_info, cin:film.type, cin:image.label, cin:origination.create_date, cin:origination.create_time, cin:origination.device, cin:origination.filename, cin:origination.model, cin:origination.serial, cin:origination.x_offset, cin:origination.x_pitch, cin:origination.y_offset, cin:origination.y_pitch, cin:user.data.
    CMYKRWRaw cyan, magenta, yellow, and black samplesUse -size and -depth to specify the image width, height, and depth. To specify a single precision floating-point format, use -define quantum:format=floating-point. Set the depth to 32 for single precision floats, 64 for double precision, and 16 for half-precision.
    CMYKARWRaw cyan, magenta, yellow, black, and alpha samplesUse -size and -depth to specify the image width, height, and depth. To specify a single precision floating-point format, use -define quantum:format=floating-point. Set the depth to 32 for single precision floats, 64 for double precision, and 16 for half-precision.
    CR2RCanon Digital Camera Raw Image FormatRequires an explicit image format otherwise the image is interpreted as a TIFF image (e.g. cr2:image.cr2).
    CRWRCanon Digital Camera Raw Image Format
    CURRMicrosoft Cursor Icon
    CUTRDR Halo
    DCMRDigital Imaging and Communications in Medicine (DICOM) imageUsed by the medical community for images like X-rays. ImageMagick sets the initial display range based on the Window Center (0028,1050) and Window Width (0028,1051) tags. Use -define dcm:display-range=reset to set the display range to the minimum and maximum pixel values.
    DCRRKodak Digital Camera Raw Image File
    DCXRWZSoft IBM PC multi-page Paintbrush image
    DDSRWMicrosoft Direct Draw SurfaceUse -define to specify the compression (e.g. -define dds:compression={dxt1, dxt5, none}). Other defines include dds:cluster-fit={true,false}, dds:weight-by-alpha={true,false}, and use dds:mipmaps to set the number of mipmaps.
    DIBRWMicrosoft Windows Device Independent BitmapDIB is a BMP file without the BMP header. Used to support embedded images in compound formats like WMF.
    DJVUR
    DNGRDigital NegativeRequires an explicit image format otherwise the image is interpreted as a TIFF image (e.g. dng:image.dng).
    DOTRGraph VisualizationUse -define to specify the layout engine (e.g. -define dot:layout-engine=twopi).
    DPXRWSMPTE Digital Moving Picture Exchange 2.0 (SMPTE 268M-2003)Use -set to specify the image gamma or black and white points (e.g. -set gamma 1.7, -set reference-black 95, -set reference-white 685).
    EMFRMicrosoft Enhanced Metafile (32-bit)Only available under Microsoft Windows.
    EPDFRWEncapsulated Portable Document Format
    EPIRWAdobe Encapsulated PostScript Interchange formatRequires Ghostscript to read.
    EPSRWAdobe Encapsulated PostScriptRequires Ghostscript to read.
    EPS2WAdobe Level II Encapsulated PostScriptRequires Ghostscript to read.
    EPS3WAdobe Level III Encapsulated PostScriptRequires Ghostscript to read.
    EPSFRWAdobe Encapsulated PostScriptRequires Ghostscript to read.
    EPSIRWAdobe Encapsulated PostScript Interchange formatRequires Ghostscript to read.
    EPTRWAdobe Encapsulated PostScript Interchange format with TIFF previewRequires Ghostscript to read.
    EXRRWHigh dynamic-range (HDR) file format developed by Industrial Light & MagicSee High Dynamic-Range Images for details on this image format. To specify the output color type, use -define exr:color-type={RGB,RGBA,YC,YCA,Y,YA,R,G,B,A}. Use -sampling-factor to specify the sampling rate for YC(A) (e.g. 2x2 or 4:2:0). Requires the OpenEXR delegate library.
    FAXRWGroup 3 TIFFThis format is a fixed width of 1728 as required by the standard. See TIFF format. Note that FAX machines use non-square pixels which are 1.5 times wider than they are tall but computer displays use square pixels so FAX images may appear to be narrow unless they are explicitly resized using a resize specification of 100x150%.
    FIGRFIG graphics formatRequires TransFig.
    FITSRWFlexible Image Transport SystemTo specify a single-precision floating-point format, use -define quantum:format=floating-point. Set the depth to 64 for a double-precision floating-point format.
    FPXRWFlashPix FormatFlashPix has the option to store mega- and giga-pixel images at various resolutions in a single file which permits conservative bandwidth and fast reveal times when displayed within a Web browser. Requires the FlashPix SDK.
    GIFRWCompuServe Graphics Interchange Format8-bit RGB PseudoColor with up to 256 palette entries. Specify the format GIF87 to write the older version 87a of the format. Use -transparent-color to specify the GIF transparent color (e.g. -transparent-color wheat).
    GPLTRGnuplot plot filesRequires gnuplot4.0.tar.Z or later.
    GRAYRWRaw gray samplesUse -size and -depth to specify the image width, height, and depth. To specify a single precision floating-point format, use -define quantum:format=floating-point. Set the depth to 32 for single precision floats, 64 for double precision, and 16 for half-precision.
    HDRRWRadiance RGBE image format
    HPGLRHP-GL plotter languageRequires hp2xx-3.4.4.tar.gz
    HRZRWSlow Scane TeleVision
    HTMLRWHypertext Markup Language with a client-side image mapAlso known as HTM. Requires html2ps to read.
    ICORMicrosoft iconAlso known as ICON.
    INFOWFormat and characteristics of the image
    INLINERWBase64-encoded inline imageThe inline image look similar to inline:data:;base64,/9j/4AAQSk...knrn//2Q==. If the inline image exceeds 5000 characters, reference it from a file (e.g. inline:inline.txt). You can also write a base64-encoded image. Embed the mime type in the filename, for example, convert myimage inline:jpeg:myimage.txt.
    JBIGRWJoint Bi-level Image experts Group file interchange formatAlso known as BIE and JBG. Requires jbigkit-1.6.tar.gz.
    JNGRWMultiple-image Network GraphicsJPEG in a PNG-style wrapper with transparency. Requires libjpeg and libpng-1.0.11 or later, libpng-1.2.5 or later recommended.
    JP2RWJPEG-2000 JP2 File Format SyntaxSpecify the encoding options with the -define option See JP2 Encoding Options for more details.
    JPTRWJPEG-2000 Code Stream SyntaxSpecify the encoding options with the -define option See JP2 Encoding Options for more details.
    J2CRWJPEG-2000 Code Stream SyntaxSpecify the encoding options with the -define option See JP2 Encoding Options for more details.
    J2KRWJPEG-2000 Code Stream SyntaxSpecify the encoding options with the -define option See JP2 Encoding Options for more details.
    JPEGRWJoint Photographic Experts Group JFIF formatNote, JPEG is a lossy compression. In addition, you cannot create black and white images with JPEG nor can you save transparency.

    Requires jpegsrc.v8c.tar.gz. You can set quality scaling for luminance and chrominance separately (e.g. -quality 90,70). You can optionally define the DCT method, for example to specify the float method, use -define jpeg:dct-method=float. By default we compute optimal Huffman coding tables. Specify -define jpeg:optimize-coding=false to use the default Huffman tables. Two other options include -define jpeg:block-smoothing and -define jpeg:fancy-upsampling. Set the sampling factor with -define jpeg:sampling-factor. You can size the image with jpeg:size, for example -define jpeg:size=128x128. To restrict the maximum file size, use jpeg:extent, for example -define jpeg:extent=400KB. To define one or more custom quantization tables, use -define jpeg:q-table=filename. To avoid reading a particular associated image profile, use -define profile:skip=name (e.g. profile:skip=ICC).
    JXRRWJPEG extended rangeRequires the jxrlib delegate library. Put the JxrDecApp and JxrEncApp applications in your execution path.
    JSONWJavaScript Object Notation, a lightweight data-interchange formatInclude additional attributes about the image with these defines: -define json:locate, -define json:limit, -define json:moments, or -define json:features.
    MANRUnix reference manual pagesRequires that GNU groff and Ghostcript are installed.
    MATRMATLAB image format
    MIFFRWMagick image file formatThis format persists all image attributes known to ImageMagick. To specify a single precision floating-point format, use -define quantum:format=floating-point. Set the depth to 32 for single precision floats, 64 for double precision, and 16 for half-precision.
    MONORWBi-level bitmap in least-significant-byte first order
    MNGRWMultiple-image Network GraphicsA PNG-like Image Format Supporting Multiple Images, Animation and Transparent JPEG. Requires libpng-1.0.11 or later, libpng-1.2.5 or later recommended. An interframe delay of 0 generates one frame with each additional layer composited on top. For motion, be sure to specify a non-zero delay.
    M2VRWMotion Picture Experts Group file interchange format (version 2)Requires ffmpeg.
    MPEGRWMotion Picture Experts Group file interchange format (version 1)Requires ffmpeg.
    MPCRWMagick Persistent Cache image file formatThe most efficient data processing pattern is a write-once, read-many-times pattern. The image is generated or copied from source, then various analyses are performed on the image pixels over time. MPC supports this pattern. MPC is the native in-memory ImageMagick uncompressed file format. This file format is identical to that used by ImageMagick to represent images in memory and is read by mapping the file directly into memory. The MPC format is not portable and is not suitable as an archive format. It is suitable as an intermediate format for high-performance image processing. The MPC format requires two files to support one image. Image attributes are written to a file with the extension .mpc, whereas, image pixels are written to a file with the extension .cache.
    MPRRWMagick Persistent RegistryThis format permits you to write to and read images from memory. The image persists until the program exits. For example, let's use the MPR to create a checkerboard: -
    -convert \( -size 15x15 canvas:black canvas:white -append \) \
    -  \( +clone -flip \) +append -write mpr:checkers +delete \
    -  -size 240x240 tile:mpr:checkers board.png
    -
    MRWRSony (Minolta) Raw Image File
    MSLRWMagick Scripting LanguageMSL is the XML-based scripting language supported by the conjure utility. MSL requires the libxml2 delegate library.
    MTVRWMTV Raytracing image format
    MVGRWMagick Vector Graphics.The native ImageMagick vector metafile format. A text file containing vector drawing commands accepted by convert's -draw option.
    NEFRNikon Digital SLR Camera Raw Image File
    ORFROlympus Digital Camera Raw Image File
    OTBRWOn-the-air Bitmap
    P7RWXv's Visual Schnauzer thumbnail format
    PALMRWPalm pixmap
    PAMWCommon 2-dimensional bitmap format
    CLIPBOARDRWWindows ClipboardOnly available under Microsoft Windows.
    PBMRWPortable bitmap format (black and white)
    PCDRWPhoto CDThe maximum resolution written is 768x512 pixels since larger images require huffman compression (which is not supported).
    PCDSRWPhoto CDDecode with the sRGB color tables.
    PCLWHP Page Control LanguageUse -define to specify fit to page option (e.g. -define pcl:fit-to-page=true).
    PCXRWZSoft IBM PC Paintbrush file
    PDBRWPalm Database ImageViewer Format
    PDFRWPortable Document FormatRequires Ghostscript to read. By default, ImageMagick sets the page size to the MediaBox. Some PDF files, however, have a CropBox or TrimBox that is smaller than the MediaBox and may include white space, registration or cutting marks outside the CropBox or TrimBox. To force ImageMagick to use the CropBox or TrimBox rather than the MediaBox, use -define (e.g. -define pdf:use-cropbox=true or -define pdf:use-trimbox=true). Use -density to improve the appearance of your PDF rendering (e.g. -density 300x300). Use -alpha remove to remove transparency. To specify direct conversion from Postscript to PDF, use -define delegate:bimodel=true. Use -define pdf:fit-page=true to scale to the page size. To immediately stop processing upon an error, set -define pdf:stop-on-error to true.
    PEFRPentax Electronic FileRequires an explicit image format otherwise the image is interpreted as a TIFF image (e.g. pef:image.pef).
    PFARPostscript Type 1 font (ASCII)Opening as file returns a preview image.
    PFBRPostscript Type 1 font (binary)Opening as file returns a preview image.
    PFMRWPortable float map format
    PGMRWPortable graymap format (gray scale)
    PICONRWPersonal Icon
    PICTRWApple Macintosh QuickDraw/PICT file
    PIXRAlias/Wavefront RLE image format
    PNGRWPortable Network GraphicsRequires libpng-1.0.11 or later, libpng-1.2.5 or later recommended. The PNG specification does not support pixels-per-inch units, only pixels-per-centimeter. To avoid reading a particular associated image profile, use -define profile:skip=name (e.g. profile:skip=ICC).
    PNG8RWPortable Network Graphics8-bit indexed with optional binary transparency
    PNG00RWPortable Network GraphicsPNG inheriting subformat from original if possible
    PNG24RWPortable Network Graphicsopaque or binary transparent 24-bit RGB
    PNG32RWPortable Network Graphicsopaque or transparent 32-bit RGBA
    PNG48RWPortable Network Graphicsopaque or binary transparent 48-bit RGB
    PNG64RWPortable Network Graphicsopaque or transparent 64-bit RGB
    PNMRWPortable anymapPNM is a family of formats supporting portable bitmaps (PBM) , graymaps (PGM), and pixmaps (PPM). There is no file format associated with pnm itself. If PNM is used as the output format specifier, then ImageMagick automagically selects the most appropriate format to represent the image. The default is to write the binary version of the formats. Use -compress none to write the ASCII version of the formats.
    PPMRWPortable pixmap format (color)
    PSRWAdobe PostScript fileRequires Ghostscript to read. To force ImageMagick to respect the crop box, use -define (e.g. -define eps:use-cropbox=true). Use -density to improve the appearance of your Postscript rendering (e.g. -density 300x300). Use -alpha remove to remove transparency. To specify direct conversion from PDF to Postscript, use -define delegate:bimodel=true.
    PS2RWAdobe Level II PostScript fileRequires Ghostscript to read.
    PS3RWAdobe Level III PostScript fileRequires Ghostscript to read.
    PSBRWAdobe Large Document Format
    PSDRWAdobe Photoshop bitmap fileUse -define psd:alpha-unblend=off to disable alpha blenning in the merged image.
    PTIFRWPyramid encoded TIFFMulti-resolution TIFF containing successively smaller versions of the image down to the size of an icon.
    PWPRSeattle File Works multi-image file
    RADRRadiance image fileRequires that ra_ppm from the Radiance software package be installed.
    RAFRFuji CCD-RAW Graphic File
    RGBRWRaw red, green, and blue samplesUse -size and -depth to specify the image width, height, and depth. To specify a single precision floating-point format, use -define quantum:format=floating-point. Set the depth to 32 for single precision floats, 64 for double precision, and 16 for half-precision.
    RGBARWRaw red, green, blue, and alpha samplesUse -size and -depth to specify the image width, height, and depth. To specify a single precision floating-point format, use -define quantum:format=floating-point. Set the depth to 32 for single precision floats, 64 for double precision, and 16 for half-precision.
    RFGRWLEGO Mindstorms EV3 Robot Graphics File
    RLARAlias/Wavefront image file
    RLERUtah Run length encoded image file
    SCTRScitex Continuous Tone Picture
    SFWRSeattle File Works image
    SGIRWIrix RGB image
    SHTMLWHypertext Markup Language client-side image mapUsed to write HTML clickable image maps based on a the output of montage or a format which supports tiled images such as MIFF.
    SID, MrSIDRMultiresolution seamless imageRequires the mrsidgeodecode command line utility that decompresses MG2 or MG3 SID image files.
    SPARSE-COLORWRaw text fileFormat compatible with the -sparse-color option. Lists only non-fully-transparent pixels.
    SUNRWSUN Rasterfile
    SVGRWScalable Vector GraphicsImageMagick utilizes inkscape if its in your execution path otherwise RSVG. If neither are available, ImageMagick reverts to its internal SVG renderer. The default resolution is 90dpi.
    TGARWTruevision Targa imageAlso known as formats ICB, VDA, and VST.
    TIFFRWTagged Image File FormatAlso known as TIF. Requires tiff-v3.6.1.tar.gz or later. Use -define to specify the rows per strip (e.g. -define tiff:rows-per-strip=8). To define the tile geometry, use for example, -define tiff:tile-geometry=128x128. To specify a signed format, use -define quantum:format=signed. To specify a single-precision floating-point format, use -define quantum:format=floating-point. Set the depth to 64 for a double-precision floating-point format. Use -define quantum:polarity=min-is-black or -define quantum:polarity=min-is-white toggle the photometric interpretation for a bilevel image. Specify the extra samples as associated or unassociated alpha with, for example, -define tiff:alpha=unassociated. Set the fill order with -define tiff:fill-order=msb|lsb. Set the TIFF endianess with -define tiff:endian=msb|lsb. Use -define tiff:exif-properties=false to skip reading the EXIF properties. You can set a number of TIFF software attributes including document name, host computer, artist, timestamp, make, model, software, and copyright. For example, -set tiff:software "My Company". If you want to ignore certain TIFF tags, use this option: -define tiff:ignore-tags=comma-separated-list-of-tag-IDs. Since version 6.9.1-4 there is support for reading photoshop layers in TIFF files, this can be disabled with -define tiff:ignore-layers=true
    TIMRPSX TIM file
    TTFRTrueType font fileRequires freetype 2. Opening as file returns a preview image. Use -set if you do not want to hint glyph outlines after their scaling to device pixels (e.g. -set type:hinting off).
    TXTRWRaw text fileUse -define to specify the color compliance (e.g. -define txt:compliance=css).
    UILWX-Motif UIL table
    UYVYRWInterleaved YUV raw imageUse -size and -depth command line options to specify width and height. Use -sampling-factor to set the desired subsampling (e.g. -sampling-factor 4:2:2).
    VICARRWVICAR rasterfile format
    VIFFRWKhoros Visualization Image File Format
    WBMPRWWireless bitmapSupport for uncompressed monochrome only.
    WDPRWJPEG extended rangeRequires the jxrlib delegate library. Put the JxrDecApp and JxrEncApp applications in your execution path.
    WEBPRWWeppy image formatRequires the WEBP delegate library. Specify the encoding options with the -define option See WebP Encoding Options for more details.
    WMFRWindows MetafileRequires libwmf. By default, renders WMF files using the dimensions specified by the metafile header. Use the -density option to adjust the output resolution, and thereby adjust the output size. The default output resolution is 72DPI so -density 144 results in an image twice as large as the default. Use -background color to specify the WMF background color (default white) or -texture filename to specify a background texture image.
    WPGRWord Perfect Graphics File
    XRWdisplay or import an image to or from an X11 serverUse -define to obtain the image from the root window (e.g. -define x:screen=true). Set x:silent=true to turn off the beep when importing an image.
    XBMRWX Windows system bitmap, black and white onlyUsed by the X Windows System to store monochrome icons.
    XCFRGIMP image
    XPMRWX Windows system pixmapAlso known as PM. Used by the X Windows System to store color icons.
    XWDRWX Windows system window dumpUsed by the X Windows System to save/display screen dumps.
    X3FRSigma Camera RAW Picture File
    YCbCrRWRaw Y, Cb, and Cr samplesUse -size and -depth to specify the image width, height, and depth.
    YCbCrARWRaw Y, Cb, Cr, and alpha samplesUse -size and -depth to specify the image width, height, and depth.
    YUVRWCCIR 601 4:1:1Use -size and -depth command line options to specify width, height, and depth. Use -sampling-factor to set the desired subsampling (e.g. -sampling-factor 4:2:2).
    -
    - -

    Pseudo-image Formats

    - -

    ImageMagick supports a number of image format specifications which refer to images prepared via an algorithm, or input/output targets. The following table lists these pseudo-image formats:

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TagModeDescriptionNotes
    CANVASRCanvas image of specified colorUseful to create solid color canvas images. Use - -size and -depth to specify the - image width, height, and depth. Example canvas color specifications - include canvas:red and canvas:#FF0000.
    - - If no color is specified a 'white' canvas image is - generated. If no -size is specified - a single pixel image of the specified color is generated.
    CAPTIONRImage caption
    CLIPRWClip path of image
    CLIPBOARDRWWindows ClipboardOnly available under Microsoft Windows.
    FRACTALRPlasma fractal image
    GRADIENTRGradual passing from one shade to anotherReturns a rendered linear top-to-bottom gradient image using the specified image size.
    HALDRIdentity Hald CLUT ImageSelect order with filename, e.g. hald:5 for order 5.
    HISTOGRAMWHistogram of the imageThe histogram includes the unique colors of the image as an image comment. If you have no need for the unique color list, use -define histogram:unique-colors=false to forego this expensive operation.
    LABELRText image formatSpecify the desired text as the filename (e.g. label:"This a label").
    MAPRWColormap intensities and indicesSet -depth to set the sample size of the intensities; indices are 16-bit if colors > 256.
    MASKRWImage mask
    MATTEWMATTE formatWrite only.
    NULLRWNULL imageUseful for creating blank tiles with montage (use NULL:). Also useful as an output format when evaluating image read performance.
    PANGORImage captionYou can configure the caption layout with these defines: -define pango:auto-dir=true/false, -define pango:ellipsize=start/middle/end, -define pango:gravity-hint=natural/strong/line, -define pango:hinting=none/auto/full, -define pango:indent=points, -define pango:justify=true/false, -define pango:language=en_US/etc, -define pango:markup=true/false, -define pango:single-paragraph=true/false and -define pango:wrap=word/char/word-char.
    PLASMARPlasma fractal image
    PREVIEWWShow a preview an image enhancement, effect, or f/xCreates a preview montage of images prepared over a parametric range in order to assist with parameter selection. Specify the desired - preview type via the -preview option).
    PRINTWSend image to your computer printerUnix users may set the PRINTER (for 'lpr') or LPDEST (for 'lp') environment variables to select the desired printer.
    SCANRImport image from a scanner deviceRequires SANE Specify the device name and path as the filename (e.g. scan:'hpaio:/usb/Officejet_6200_series?serial=CN4ATCE3G20453').
    RADIAL_GRADIENTRGradual radial passing from one shade to anotherReturns a rendered radial top-to-bottom gradient image using the specified image size.
    SCANXRImport image from the default scanner device
    SCREENSHOTRan image that shows the contents of a computer display
    STEGANORSteganographic imageUse -size command line option to specify width, height, and offset of the steganographic image
    TILERTiled imageCreate a tiled version of an image at by tiling a image. Use -size to specify the tiled image size. Tiles are composited on an image background and therefore is responsive to the -compose option. The image is specified similar to - TILE:image.miff.
    UNIQUEWWrite only unique pixels to the image file.
    VIDRWVisual Image DirectoryUsed to create a thumbnailed directory (tiled thumbnails) of a set of images which may be used to select images to view via the display program, or saved to a MIFF or SHTML file.
    WINRWSelect image from or display image to your computer screenOnly supported under Microsoft Windows.
    XRWSelect image from or display image to your X server screenAlso see the import and display - programs.
    XCRCanvas image of specified colorAn backward compatible alias for the 'canvas:' - psuedo-file format, used to create a solid color canvas image. -
    -
    - -

    Built-in Images

    - -

    ImageMagick includes a number of built-in (embedded) images which may be referenced as if they were an image file. The magick: format tag may be used via the syntax magick:name to request an embedded image (e.g. magick:logo). For backwards compatibility, the image specifications GRANITE:, LOGO:, NETSCAPE:, and ROSE: may also be used to request images with those names.

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TagModeDescriptionNotes
    GRANITER128x128 granite texture patternGRANITE
    LOGORImageMagick Logo, 640x480Logo
    NETSCAPERimage using colors in Netscape 216 (6x6x6 ) color cube, 216x144Most commonly used with the convert and mogrify programs with the -map option to create web safe images.
    ROSERPicture of a rose, 70x46ROSE
    WIZARDRImageMagick Wizard, 480x640Logo
    - -

    Built-in Patterns

    - -

    ImageMagick includes a number of built-in (embedded) patterns which may be referenced as if they were an image file. The pattern: format tag may be used via the syntax pattern:name to request an embedded pattern (e.g. pattern:checkerboard). The pattern size is controlled with the -size command line option.

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TagModeDescriptionNotes
    BRICKSRbrick pattern, 16x16BRICKS
    CHECKERBOARDRcheckerboard pattern, 30x30CHECKERBOARD
    CIRCLESRcircles pattern, 16x16CIRCLES
    CROSSHATCHRcrosshatch pattern, 8x4CROSSHATCH
    CROSSHATCH30Rcrosshatch pattern with lines at 30 degrees, 8x4CROSSHATCH30
    CROSSHATCH45Rcrosshatch pattern with lines at 45 degrees, 8x4CROSSHATCH45
    FISHSCALESRfish scales pattern, 16x8FISHSCALES
    GRAY0R0% intensity gray, 32x32GRAY0
    GRAY5R5% intensity gray, 32x32GRAY5
    GRAY10R10% intensity gray, 32x32 GRAY10
    GRAY15R15% intensity gray, 32x32GRAY15
    GRAY20R20% intensity gray, 32x32GRAY20
    GRAY25R25% intensity gray, 32x32GRAY25
    GRAY30R30% intensity gray, 32x32GRAY30
    GRAY35R35% intensity gray, 32x32GRAY35
    GRAY40R40% intensity gray, 32x32GRAY40
    GRAY45R45% intensity gray, 32x32GRAY45
    GRAY50R50% intensity gray, 32x32GRAY50
    GRAY55R55% intensity gray, 32x32GRAY55
    GRAY60R60% intensity gray, 32x32GRAY60
    GRAY65R65% intensity gray, 32x32GRAY65
    GRAY70R70% intensity gray, 32x32GRAY70
    GRAY75R75% intensity gray, 32x32GRAY75
    GRAY80R80% intensity gray, 32x32 GRAY80
    GRAY85R85% intensity gray, 32x32GRAY85
    GRAY90R100% intensity gray, 32x32GRAY90
    GRAY95R100% intensity gray, 32x32GRAY95
    GRAY100R100% intensity gray, 32x32GRAY100
    HEXAGONSRhexagon pattern, 30x18HEXAGONS
    HORIZONTALRhorizontal line pattern, 8x4HORIZONTAL
    HORIZONTAL2Rhorizontal line pattern, 8x8HORIZONTAL2
    HORIZONTAL3Rhorizontal line pattern, 9x9HORIZONTAL3
    HORIZONTALSAWRhorizontal saw-tooth pattern, 16x8HORIZONTALSAW
    HS_BDIAGONALRbackward diagonal line pattern (45 degrees slope), 8x8HS_BDIAGONAL
    HS_CROSSRcross line pattern, 8x8HS_CROSS
    HS_DIAGCROSSRdiagonal line cross pattern (45 degrees slope), 8x8HS_DIAGCROSS
    HS_FDIAGONALRforward diagonal line pattern (45 degrees slope), 8x8HS_FDIAGONAL
    HS_HORIZONTALRhorizontal line pattern, 8x8HS_HORIZONTAL
    HS_VERTICALRvertical line pattern, 8x8HS_VERTICAL
    LEFT30Rforward diagonal pattern (30 degrees slope), 8x4LEFT0
    LEFT45Rforward diagonal line pattern (45 degrees slope), 8x8LEFT45
    LEFTSHINGLERleft shingle pattern, 24x24LEFTSHINGLE
    OCTAGONSRoctagons pattern, 16x16OCTAGONS
    RIGHT30Rbackward diagonal line pattern (30 degrees) 8x4RIGHT30
    RIGHT45Rbackward diagonal line pattern (30 degrees), 8x8RIGHT45
    RIGHTSHINGLERright shingle pattern, 24x24RIGHTSHINGLE
    SMALLFISHSCALESRsmall fish scales pattern, 8x8SMALLFISHSCALES
    VERTICALRvertical line pattern, 8x8VERTICAL
    VERTICAL2Rvertical line pattern, 8x8VERTICAL2
    VERTICAL3Rvertical line pattern, 9x9VERTICAL3
    VERTICALBRICKSRvertical brick pattern, 16x16VERTICALBRICKS
    VERTICALLEFTSHINGLERvertical left shingle pattern, 24x24VERTICALLEFTSHINGLE
    VERTICALRIGHTSHINGLERvertical right shingle pattern, 24x24VERTICALRIGHTSHINGLE
    VERTICALSAWRvertical saw-tooth pattern, 8x16VERTICALSAW
    - -

    Embedded Image Profiles

    - -

    ImageMagick provides a number of format identifiers which are used to add, remove, and save embedded profiles for images which can support embedded profiles. Image types which may contain embedded profiles are TIFF, JPEG, and PDF.

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TagModeDescriptionNotes
    8BIMRWPhotoshop resource format (binary)
    8BIMTEXTRWPhotoshop resource format (ASCII)An ASCII representation of the 8BIM format.
    APP1RWRaw application information
    APP1JPEGRWRaw JPEG binary dataProfile in JPEG wrapper.
    ICCRWInternational Color Consortium color profileAlso known as ICM. To read, use -profile with - convert.
    IPTCRWIPTC Newsphoto (binary)To read, use -profile with convert
    IPTCTEXTRWIPTC Newsphoto (ASCII)An ASCII representation of the IPTC format.
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/fx.html b/ImageMagick-7.0.0-0/www/fx.html deleted file mode 100644 index 5524b92a2..000000000 --- a/ImageMagick-7.0.0-0/www/fx.html +++ /dev/null @@ -1,415 +0,0 @@ - - - - - - - - - ImageMagick: The Fx Special Effects Image Operator - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    The Fx Special Effects Image Operator • The Anatomy of an Fx Expression

    - - - -

    Use the Fx special effects image operator to apply a mathematical expression to an image or image channels. Use Fx to:

    - -
      -
    • create canvases, gradients, mathematical colormaps
    • -
    • move color values between images and channels
    • -
    • translate, flip, mirror, rotate, scale, shear and generally distort images
    • -
    • merge or composite multiple images together
    • -
    • convolve or merge neighboring pixels together
    • -
    • generate image metrics or 'fingerprints'
    • -
    - -

    The expression can be simple:

    - -
    -convert -size 64x64 canvas:black -channel blue -fx "1/2" fx_navy.png
    -
    - -

    Here, we convert a black to a navy blue image:

    - -
      - black - ==> - navy -
    - -

    Or the expression can be complex:

    - -
    -convert rose.jpg \  
    -  -fx "(1.0/(1.0+exp(10.0*(0.5-u)))-0.006693)*1.0092503" \ 
    -  rose-sigmoidal.png'
    -
    - -

    This expression results in a high contrast version of the image:

    - -
      - rose - ==> - rose-sigmoidal -
    - -

    The expression can include variable assignments. Assignments, in most cases, reduce the complexity of an expression and permit some operations that might not be possible any other way. For example, lets create a radial gradient:

    - -
    -convert -size 70x70 canvas: \
    -  -fx "Xi=i-w/2; Yj=j-h/2; 1.2*(0.5-hypot(Xi,Yj)/70.0)+0.5" 
    -  radial-gradient.png'
    -
    - -

    The command above returns this image:

    - -
      - radial-gradient -
    - -

    This FX expression adds random noise to an image:

    - -
    -convert photo.jpg -fx \'iso=32; rone=rand(); rtwo=rand(); \
    -  myn=sqrt(-2*ln(rone))*cos(2*Pi*rtwo); myntwo=sqrt(-2*ln(rtwo))* \
    -  cos(2*Pi*rone); pnoise=sqrt(p)*myn*sqrt(iso)* \ 
    -  channel(4.28,3.86,6.68,0)/255; max(0,p+pnoise)\' noisy.png
    -
    - -

    See Using FX, The Special Effects Image Operator for more examples.

    - -

    The next section discusses the Fx expression language.

    - -

    The Anatomy of an Fx Expression

    - -

    The Fx Expression Language

    - -

    The formal Fx expression language is defined here:

    - -
    -
    numbers:
    -
    integer, floating point, scientific notation (+/- required, e.g. 3.81469e-06), International System number postfixes (.e.g KB, Mib, GB, etc.)
    -
    constants:
    -
    E (Euler's number), Epsilon, QuantumRange, QuantumScale, Opaque, Phi (golden ratio), Pi, Transparent
    -
    Fx operators (in order of precedence):
    -
    ^ (power), unary -, *, /, % (modulo), +, -, - <<, >>, <, <=, >, >=, ==, !=, - & (bitwise AND), | (bitwise OR), - && (logical AND), || (logical OR), - ~ (logical NOT), ?: (ternary conditional)
    -
    math functions:
    -
    abs(), acos(), acosh(), airy(), alt(), asin(), asinh(), atan(), atanh(), atan2(), ceil(), clamp(), cos(), cosh(), debug(), drc(), exp(), floor(), gauss(), gcd(), hypot(), int(), isnan(), j0(), j1(), jinc(), ln(), log(), logtwo(), max(), min(), mod(), not(), pow(), rand(), round(), sign(), sin(), sinc(), sinh(), sqrt(), squish(), tan(), tanh(), trunc()
    -
    channel functions:
    -
    channel(r,g,b,a), channel(c,m,y,k,a)
    -
    color names:
    -
    red, cyan, black, etc.
    -
    color functions:
    -
    srgb(), srgba(), rgb(), rgba(), cmyk(), cmyka(), hsl(), hsla(), etc.
    -
    color hex values:
    -
    #ccc, #cbfed0, #b9e1cc00, etc.
    -
    symbols:
    -
  • u=> first image in list
  • -
  • v=> second image in list
  • -
  • s=> current image in list (for %[fx:] otherwise = u)
  • -
  • t=> index of current image (s) in list
  • -
  • n=> number of images in list
  • - -
  • i=> column offset
  • -
  • j=> row offset
  • -
  • p=> pixel to use (absolute or relative to current pixel)
  • - -
  • w=> width of this image
  • -
  • h=> height of this image
  • -
  • z=> channel depth
  • - -
  • r=> red value (from RGBA), of a specific or current pixel
  • -
  • g=> green ''
  • -
  • b=> blue ''
  • -
  • a=> alpha ''
  • -
  • o=> opacity ''
  • - -
  • c=> cyan value of CMYK color of pixel
  • -
  • y=> yellow ''
  • -
  • m=> magenta ''
  • -
  • k=> black ''
  • - -
  • intensity=> pixel intensity
  • - -
  • hue=> pixel hue
  • -
  • saturation=> pixel saturation
  • -
  • lightness=> pixel lightness
  • -
  • luma=> pixel luma
  • - -
  • page.width=> page width
  • -
  • page.height=> page height
  • -
  • page.x=> page x offset
  • -
  • page.y=> page y offset
  • - -
  • resolution.x=> x resolution
  • -
  • resolution.y=> y resolution
  • - -
  • depth=> image depth
  • -
  • minima=> image minima
  • -
  • maxima=> image maxima
  • -
  • mean=> image mean
  • -
  • standard_deviation=> image standard deviation
  • -
  • kurtosis=> image kurtosis
  • -
  • skewness=> image skewness (add a channel specifier to compute a statistic for that channel, e.g. depth.r)
  • -
    iterators:
    -
    while()
    -
    - - -

    The Fx Expression

    - -

    An Fx expression may include any combination of the following:

    -
    -
    x ^ y
    exponentiation (xy)
    -
    ( ... )
    grouping
    -
    x * y
    multiplication (the asterisk * is optional, for example, 2u or 2(x+y) are acceptable)
    -
    x / y
    division
    -
    x % y
    modulo
    -
    x + y
    addition
    -
    x - y
    subtraction
    -
    x << y
    left shift
    -
    x >> y
    right shift
    -
    x < y
    boolean relation, return value 1.0 if x < y, otherwise 0.0
    -
    x <= y
    boolean relation, return value 1.0 if x <= y, otherwise 0.0
    -
    x > y
    boolean relation, return value 1.0 if x > y, otherwise 0.0
    -
    x >= y
    boolean relation, return value 1.0 if x >= y, otherwise 0.0
    -
    x == y
    boolean relation, return value 1.0 if x == y, otherwise 0.0
    -
    x != y
    boolean relation, return value 1.0 if x != y, otherwise 0.0
    -
    x & y
    binary AND
    -
    x | y
    binary OR
    -
    x && y
    logical AND connective, return value 1.0 if x > 0 and y > 0, otherwise 0.0
    -
    x || y
    logical OR connective (inclusive), return value 1.0 if x > 0 or y > 0 (or both), otherwise 0.0
    -
    ~x
    logical NOT operator, return value 1.0 if not x > 0, otherwise 0.0
    -
    +x
    unary plus, return 1.0*value
    -
    -x
    unary minus, return -1.0*value
    -
    x ? y
    z: ternary conditional expression, return value y if x != 0, otherwise z; only one ternary conditional permitted per statement
    -
    x = y
    assignment; assignment variables are restricted to letter combinations only (e.g. Xi not X1)
    -
    x ; y
    statement separator
    -
    phi
    constant (1.618034...)
    -
    pi
    constant (3.141659...)
    -
    e
    constant (2.71828...)
    -
    QuantumRange
    constant maximum pixel value (255 for Q8, 65535 for Q16)
    -
    QuantumScale
    constant 1.0/QuantumRange
    -
    intensity
    pixel intensity; equivalent to 0.299*red+0.587*green+0.114*blue
    -
    hue
    pixel hue
    -
    saturation
    pixel saturation
    -
    lightness
    pixel lightness; equivalent to 0.5*max(red,green,blue) + 0.5*min(red,green,blue)
    -
    luminance
    pixel luminance; equivalent to 0.212656*red + 0.715158*green + 0.072186*blue
    -
    red, green, blue, etc.
    color names
    -
    #ccc, #cbfed0, #b9e1cc00, etc.
    color hex values
    -
    rgb(), rgba(), cmyk(), cmyka(), hsl(), hsla()
    color functions
    -
    s, t, u, v, n, i, j, w, h, z, r, g, b, a, o, c, y, m, k
    symbols
    -
    abs(x)
    absolute value function
    -
    acos(x)
    arc cosine function
    -
    acosh(x)
    inverse hyperbolic cosine function
    -
    airy(x)
    Airy function (max=1, min=0); airy(x)=[jinc(x)]2=[2*j1(pi*x)/(pi*x)]2
    -
    alt(x)
    sign alternation function (return 1.0 if int(x) is even, -1.0 if int(x) is odd)
    -
    asin(x)
    arc sine function
    -
    asinh(x)
    inverse hyperbolic sine function
    -
    atan(x)
    arc tangent function
    -
    atanh(x)
    inverse hyperbolic tangent function
    -
    atan2(x,y)
    arc tangent function of two variables
    -
    ceil(x)
    smallest integral value not less than argument
    -
    channel(r,g,b,a)
    select numeric argument based on current channel
    -
    channel(c,m,y,k,a)
    select numeric argument based on current channel
    -
    clamp(x)
    clamp value
    -
    cos(x)
    cosine function
    -
    cosh(x)
    hyperbolic cosine function
    -
    debug(x)
    print x (useful for debugging your expression)
    -
    drc(x,y)
    dynamic range compression (knee curve); drc(x,y)=(x)/(y*(x-1)+1); -1<y<1
    -
    exp(x)
    natural exponential function (ex)
    -
    floor(x)
    largest integral value not greater than argument
    -
    gauss(x)
    gaussian function; gauss(x)=exp(-x*x/2)/sqrt(2*pi)
    -
    gcd(x,y)
    greatest common denominator
    -
    hypot(x,y)
    the square root of x2+y2
    -
    int(x)
    greatest integer function (return greatest integer less than or equal to x)
    -
    isnan(x)
    return 1.0 if x is NAN, 0.0 otherwise
    -
    j0(x)
    Bessel functions of x of the first kind of order 0
    -
    j1(x)
    Bessel functions of x of the first kind of order 1
    -
    jinc(x)
    jinc function (max=1, min=-0.1323); jinc(x)=2*j1(pi*x)/(pi**x)
    -
    ln(x)
    natural logarithm function
    -
    log(x)
    logarithm base 10
    -
    logtwo(x)
    logarithm base 2
    -
    ln(x)
    natural logarithm
    -
    max(x, y)
    maximum of x and y
    -
    min(x, y)
    minimum of x and y
    -
    mod(x, y)
    floating-point remainder function
    -
    not(x)
    return 1.0 if x is zero, 0.0 otherwise
    -
    pow(x,y)
    power function (xy)
    -
    rand()
    value uniformly distributed over the interval [0.0, 1.0) with a 2 to the 128th-1 period
    -
    round()
    round to integral value, regardless of rounding direction
    -
    sign(x)
    return -1.0 if x is less than 0.0 otherwise 1.0
    -
    sin(x)
    sine function
    -
    sinc(x)
    sinc function (max=1, min=-0.21); sinc(x)=sin(pi*x)/(pi*x)
    -
    squish(x)
    squish function; squish(x)=1.0/(1.0+exp(-x))
    -
    sinh(x)
    hyperbolic sine function
    -
    sqrt(x)
    square root function
    -
    tan(x)
    tangent function
    -
    tanh(x)
    hyperbolic tangent function
    -
    trunc(x)
    round to integer, towards zero
    -
    while(condition,expression)
    iterate while the condition is not equal to 0
    -
    -
    -

    The expression semantics include these rules:

    - -
      -
    • symbols are case insensitive
    • -
    • only one ternary conditional (e.g. x ? y : z) per statement
    • -
    • statements are assignments or the final expression to return
    • -
    • an assignment starts a statement, it is not an operator
    • -
    • assignments to built-ins do not throw an exception and have no effect; e.g. r=3.0; r returns the pixel red color value, not 3.0
    • -
    • Unary operators have a lower priority than binary operators, that is, the unary minus (negation) has lower precedence than exponentiation, so -3^2 is interpreted as -(3^2) = -9. Use parentheses to clarify your intent (e.g. (-3)^2 = 9).
    • -
    • Similarly, care must be exercised when using the slash ('/') symbol. The string of characters 1/2x is interpreted as (1/2)x. The contrary interpretation should be written explicitly as 1/(2x). Again, the use of parentheses helps clarify the meaning and should be used whenever there is any chance of misinterpretation.
    • -
    -
    - - -

    Source Images

    - -

    The symbols u and v refer to the first and second images, respectively, in the current image sequence. Refer to a particular image in a sequence by appending its index to any image reference (usually u), with a zero index for the beginning of the sequence. A negative index counts from the end. For example, u[0] is the first image in the sequence, u[2] is the third, u[-1] is the last image, and u[t] is the current image. The current image can also be referenced by s. If the sequence number exceeds the length of the sequence, the count is wrapped. Thus in a 3-image sequence, u[-1], u[2], and u[5] all refer to the same (third) image.

    - -

    As an example, we form an image by averaging the first image and third images (the second (index 1) image is ignored and just junked):

    - -
    -convert image1.jpg image2.jpg image3.jpg -fx "(u+u[2])/2.0" image.jpg
    -
    - -

    By default, the image to which p, r, g, b, a, etc., are applied is the current image s in the image list. This is equivalent to u except when used in an escape sequence %[fx:...].

    - -

    It is important to note the special role played by the first image. This is the only image in the image sequence that is modified, other images are used only for their data. As an illustrative example, consider the following, and note that the setting -channel red instructs -fx to modify only the red channel; nothing in the green or blue channels will change. It is instructive to ponder why the result is not symmetric.

    - -
    -convert -channel red logo: -flop logo: -resize "20%" -fx "(u+v)/2" image.jpg
    -
    - -
      - logo-sm-flop.png - logo-sm.png -==> - logo-sm-fx.png -
    - -
    -

    Accessing Pixels

    - -

    All color values are normalized to the range of 0.0 to 1.0. The alpha channel ranges from 0.0 (fully transparent) to 1.0 (fully opaque).

    - -

    The pixels are processed one at a time, but a different pixel of an image can be specified using a pixel index represented by p. For example,

    - -
    -p[-1].g      green value of pixel to the immediate left of the current pixel
    -p[-1,-1].r   red value of the pixel diagonally left and up from current pixel
    -
    - -

    To specify an absolute position, use braces, rather than brackets.

    - -
    -p{0,0}.r     red value of the pixel in the upper left corner of the image
    -p{12,34}.b   blue pixel value at column number 12, row 34 of the image
    -
    - -

    Integer values of the position retrieve the color of the pixel referenced, while non-integer position values return a blended color according to the current -interpolate setting.

    - -

    A position outside the boundary of the image retrieves a value dictated by the -virtual-pixel option setting.

    - -

    Apply an Expression to Select Image Channels

    - -

    Use the -channel setting to specify the output channel of the result. If no output channel is given, the result is set over all channels except the opacity channel. For example, to replace the red channel of alpha.png with the average of the green channels from the images alpha.png and beta.png, use:

    - -
    -convert alpha.png beta.png -channel red -fx "(u.g+v.g)/2" gamma.png
    -
    - - -

    Results

    - -

    The -fx operator evaluates the given expression for each channel (set by -channel) of each pixel in the first image (u) in the sequence. The computed values are temporarily stored in a copy (clone) of that first image until all the pixels have been processed, after which this single new image replaces the list of images in the current image sequence. As such, in the previous example the updated version of alpha.png replaces both of the original images, alpha.png and beta.png, before being saved as gamma.png.

    - -

    The current image s is set to the first image in the sequence (u), and t to its index, 0. The symbols i and j reference the current pixel being processed.

    - - -

    For use with -format, the value-escape %[fx:] is evaluated just once for each image in the current image sequence. As each image in the sequence is being evaluated, s and t successively refer to the current image and its index, while i and j are set to zero, and the current channel set to red (-channel is ignored). An example:

    - -
    -convert  canvas:'rgb(25%,50%,75%)' rose: -colorspace rgb  \ 
    -  -format 'Red channel of NW corner of image #%[fx:t] is %[fx:s]' info:
    -Red channel of NW corner of image #0 is 0.453758 
    -Red channel of NW corner of image #1 is 0.184588
    -
    - -

    Here we use the image indexes to rotate each image differently, and use -set with the image index to set a different pause delay on the first image in the animation:

    - -
    -convert rose: -duplicate 29 -virtual-pixel Gray -distort SRT '%[fx:360.0*t/n]' \
    -  -set delay '%[fx:t == 0 ? 240 : 10]' -loop 0 rose.gif"
    -
    - -

    The color-escape %[pixel:] is evaluated once per image and per color channel in that image (-channel is ignored), The values generated are then converted into a color string (a named color or hex color value). The symbols i and j are set to zero, and s and t refer to each successively current image and index.

    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/gradient.html b/ImageMagick-7.0.0-0/www/gradient.html deleted file mode 100644 index 3adca7d6f..000000000 --- a/ImageMagick-7.0.0-0/www/gradient.html +++ /dev/null @@ -1,237 +0,0 @@ - - - - - - - - - ImageMagick: Image Gradients - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    An image gradient creates a gradual blend between two colors formed into a shape that is linear, circular, or ellipical.

    - -

    For a linear gradient, the operator is either:

    - -
    -gradient:
    -gradient:color1-color2
    -
    - -

    The for a radial gradient, the operator is either:

    - -
    -radial-gradient:
    -radial-gradient:color1-color2
    -
    - -

    In the above, color1 is the fromColor and color2 is the toColor, as described in more detail below. The default is white for color1 and black for color2, i.e., white-black.

    - -

    The default for a linear gradient has color1 at the top of the image and color2 at the bottom of the image. Similarly, the default for a radial gradient has color1 at the center of the image and color2 at the boundary of the image.

    - -

    Gradient colors may be any valid color defined per http://www.imagemagick.org/www/color.html. The named colors of black/white/grayXX are non-linear gray gradients; whereas gray(XX[%]) is a linear gray gradient. For Unix systems, enclose rgb(a) and hex colors in quotes. Use double quotes, if using variables for the values.

    - -

    Here is an example linear gradient:

    - -
    -convert -size 256x256 gradient: linear_gradient.png
    -convert -size 256x256 gradient:white-black linear_gradient.png
    -
    -

    - -

    If you want a radial gradient, try:

    - -
    -convert -size 256x256 radial-gradient: radial_gradient.png
    -convert -size 256x256 radial-gradient:white-black radial_gradient.png
    -
    -

    - -

    As of IM 6.9.2.5, gradients have been enhanced through the use of several -defines.

    - - - - - - - - - - - - - - - - - - - - - - - - - - -
    -define gradient:vector=x1,y1, x2,y2 Specifies the direction of the linear gradient going from vector1 - (x1,y1) to vector2 (x2,y2). Color1 (fromColor) will be located at vector - position x1,y1 and color2 (toColor) will be located at vector position - x2,y2.
    -define gradient:center=x,ySpecifies the coordinates of the center point for the radial gradient. - The default is the center of the image.
    -define gradient:radii=x,ySpecifies the x and y radii of the gradient. If the x radius and the y - radius are equal, the shape of the radial gradient will be a circle. If - they differ, then the shape will be an ellipse. The default values are the - maximum of the half width and half height of the image.
    -define gradient:angle=angle in degreesFor a linear gradient, this specifies the direction of the gradient - going from color1 to color2 in a clockwise positive manner relative to - north (up). For a radial gradient, this specifies the rotation of the - gradient in a clockwise positive manner from its normal X-Y - orientation.
    -define gradient:bounding-box=widthxheight+x+yLimits the gradient to a larger or smaller region than the image - dimensions. If the region defined by the bounding box is smaller than the - image, then color1 will be the color of the background.
    - - -

    We also support two convenience defines for setting the linear gradient direction and the radial gradient shape.

    - - - - - - - - - - - -
    -define gradient:direction={NorthWest, North, Northeast, West, East, SouthWest, South, SouthEast}Specifies the direction of the linear gradient towards the - top/bottom/left/right or diagonal corners.
    -define gradient:extent={Circle, Diagonal, Ellipse, Maximum, Minimum}Specifies the shape of an image centered radial gradient. Circle and - Maximum draw a circular radial gradient even for rectangular shaped images - of radius equal to the larger of the half-width and half-height of the - image. The Circle and Maximum options are both equivalent to the default - radial gradient. The Minimum option draws a circular radial gradient - even for rectangular shaped images of radius equal to the smaller of the - half-width and half-height of the image. The Diagonal option draws a - circular radial gradient even for rectangular shaped images of radius equal - to the half-diagonal of the image. The Ellipse options draws an elliptical - radial gradient for rectangular shaped images of radii equal to half the - width and half the height of the image.
    - -

    Examples

    - -

    The default linear gradient may also be generated in any of the following ways (or by reversing the direction and swapping color1 and color2):

    - -
    -convert -size 256x128 -define gradient:direction=north gradient:black-white linear_gradient_default.png
    -convert -size 256x128 -define gradient:angle=0 gradient:black-white linear_gradient_default.png
    -
    -

    - -

    The equivalent of

    - -
    -convert -size 128x256 gradient: -rotate 90 linear_gradient_east.png
    -
    - -

    can be generate by either of the following (or by reversing the direction and swapping color1 and color2):

    - -
    -convert -size 256x128 -define gradient:direction=east gradient:black-white linear_gradient_east.png
    -convert -size 256x128 -define gradient:angle=90 gradient:black-white linear_gradient_east.png
    -
    -

    - - -

    Examples of radial gradients going from black in the center to white at the boundary for the cases of "maximum/circle/default", "minimum", "diagonal", "ellipse" and 45 degree rotated ellipse, respectively, follow below.

    - - -
    -convert -size 256x128 radial-gradient:black-white radial_gradient_maximum.png
    -convert -size 256x128 -define gradient:radii=128,128 radial-gradient:black-white radial_gradient_maximum.png
    -
    -

    - -
    -convert -size 256x128 -define gradient:extent=minimum radial-gradient:black-white radial_gradient_minimum.png
    -convert -size 256x128 -define gradient:radii=64,64 radial-gradient:black-white radial_gradient_minimum.png
    -
    -

    - -
    -convert -size 256x128 -define gradient:extent=diagonal radial-gradient:black-white radial_gradient_diagonal.png
    -
    -

    - -
    -convert -size 256x128 -define gradient:extent=ellipse radial-gradient:black-white radial_gradient_ellipse.png
    -convert -size 256x128 -define gradient:radii=128,64 radial-gradient:black-white radial_gradient_ellipse.png
    -
    -

    - -
    -convert -size 256x256 -define gradient:radii=128,64 -define gradient:angle=45 radial-gradient:black-white radial_gradient_ellipse_angle45.png
    -
    -

    - -
    - - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/high-dynamic-range.html b/ImageMagick-7.0.0-0/www/high-dynamic-range.html deleted file mode 100644 index 99b4808d3..000000000 --- a/ImageMagick-7.0.0-0/www/high-dynamic-range.html +++ /dev/null @@ -1,103 +0,0 @@ - - - - - - - - - ImageMagick: High Dynamic-Range Images - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    High dynamic-range imaging (HDRI) permits a far greater dynamic range of exposures (i.e. a large difference between light and dark areas) than standard digital imaging techniques. HDRI accurately represents the wide range of intensity levels found in real scenes ranging from the brightest direct sunlight to the deepest darkest shadows. The HDR imaging approach includes:

    - -
      -
    • render/capture floating-point color space
    • -
    • encompass the entire perceivable gamut (extend values outside [0,1] range)
    • -
    • post-process in extended color space
    • -
    • apply tone-mapping for specific display
    • -
    - -

    Enabling HDRI in ImageMagick

    - -

    By default, image pixels in ImageMagick are stored as unsigned values that range from 0 to the quantum depth, which is typically 16-bits (Q16). With HDRI enabled, the pixels are stored in a floating-point representation and can include negative values as well as values that exceed the quantum depth. A majority of digital image formats do not support HDRI, and for those images any pixels outside the quantum range are clamped before they are stored.

    - -

    The most promising HDR image format is EXR. You must have the OpenEXR delegate library installed to read or write this format. Other HDR formats include TIFF 48-bit integer and 96-bit float formats, HDR, PFM, and ImageMagick's own MIFF format.

    - -

    To enable the HDRI version of ImageMagick, use this Unix/Linux command:

    - -
    -./configure --enable-hdri
    -
    - -

    Under Windows, set the MAGICKCORE_HDRI_SUPPORT definition in the magick-baseconfig.h configuration file and build.

    - -

    To verify HDRI is properly configured, look for "HDRI" as a feature:

    - -
    -identify -version
    -Features: HDRI
    -
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/history.html b/ImageMagick-7.0.0-0/www/history.html deleted file mode 100644 index 4dc1cebca..000000000 --- a/ImageMagick-7.0.0-0/www/history.html +++ /dev/null @@ -1,91 +0,0 @@ - - - - - - - - - ImageMagick: History - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -
    -I swear by my life and my love of it that I will never live for the sake of another man, nor ask another man to live for mine.
    -- John Galt in "Atlas Shrugged", by Ayn Rand
    - -

    ImageMagick started with a request from my DuPont supervisor, Dr. David Pensak, to display computer-generated images on a monitor only capable of showing 256 unique colors simultaneously. In 1987, monitors that could display 24-bit true color images were rare and quite expensive. There were a plethora of chemists and biologists at DuPont, but very were few computer scientists to confer with. Instead, I turned to Usenet for help, and posted a request for an algorithm to reduce 24-bit images to 256 colors. Paul Raveling of the USC Information Sciences Institute responded, with not only a solution, but one that was already in source code and available from USC's FTP site. Over the course of the next few years, I had frequent opportunities to get help with other vexing computer science problems I encountered in the course of doing my job at DuPont. Eventually I felt compelled to give thanks for the help I received from the knowledgeable folks on Usenet. I decided to freely release the image processing tools I developed to the world so that others could benefit from my efforts.

    - -

    In 1990 there were few freely available image processing tools so I expected an enthusiastic reception. Before a release was possible, Dr. Pensak had to convince upper management at DuPont to give away what they what they might perceive as valuable intellectual property. I suspect they agreed simply because ImageMagick was not chemically or biologically based, so they did not understand its value to the company. Either way, ImageMagick would not be available today without DuPont transferring the copyright to ImageMagick Studio LLC. ImageMagick was posted to Usenet's comp.archives group on August 1st, 1990.

    - -

    After ImageMagick's release, I got the occasional request for an enhancement, a report of a bug, or a contribution to the source base. In the mid 90's, I released the culmination of these efforts as ImageMagick 4.2.9. At the time, I thought ImageMagick was complete. It was utilized by thousands of users world-wide, and it was even showing up as part of a new operating system distributed freely called "Linux".

    - -

    The next generation of ImageMagick, version 5, started when Bob Friesenhahn contacted me and suggested I improve the application programming interface so users could leverage the image-processing algorithms from other languages or scripts. Bob also wrote a C++ wrapper for ImageMagick called Magick++, and began contributing enhancements such as the module loader facility, automatic file identification, and test suites. In the mean-time, the project picked up a few other notable contributors: Glenn Randers-Pehrson, William Radcliffe, and Leonard Rosenthol. By now, ImageMagick was utilized by tens of thousands of users, who reacted gruffly when a new release broke an existing API call or script. The other members of the group wanted to freeze the API and command line, but I felt ImageMagick was not quite what I had envisioned it could be. Bob and the others created a fork of ImageMagick while I continued to develop ImageMagick.

    - -

    I did not work alone for long. Anthony Thyssen contacted me about deficiencies in the ImageMagick command line programs. He pointed out that the command line was confusing when dealing with more than one image. He suggested an orderly, well-defined method for dealing with the command line, and this became ImageMagick version 6 (the current release). His efforts are detailed on his web pages, Examples of ImageMagick Usage. I highly recommend that you peruse his site. He has illustrated the power of ImageMagick in ways that even I did not know were possible.

    - -

    Another notable contributor, Fred Weinhaus, makes available a plethora of command-line scripts that perform geometric transforms, blurs, sharpens, edging, noise removal, and color manipulations. Glenn Randers-Pehrson is our PNG guru and makes other valuable contributions. Dirk Lemstra made, and continues to make, numerous improvements to make ImageMagick more robust under Windows and distributes a .Net wrapper, Magick.NET.

    - -

    It has been more than 25 years since ImageMagick was first conceived, and it looks likely that it will be here for another 25 and beyond. The command line and the application programming interface are stable, but there is still work to do. The design of ImageMagick is an evolutionary process, with the design and implementation efforts serving to influence and guide further progress in the other. We are currently working on ImageMagick version 7, where we aim to improve the design based on lessons learned from the version 6 implementation.

    - -

    Cristy
    Principal ImageMagick Architect

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/identify.html b/ImageMagick-7.0.0-0/www/identify.html deleted file mode 100644 index 3db8c2fa1..000000000 --- a/ImageMagick-7.0.0-0/www/identify.html +++ /dev/null @@ -1,429 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Identify - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    The identify program describes the format and characteristics of one or more image files. It also reports if an image is incomplete or corrupt. The information returned includes the image number, the file name, the width and height of the image, whether the image is colormapped or not, the number of colors in the image, the number of bytes in the image, the format of the image (JPEG, PNM, etc.), and finally the number of seconds it took to read and process the image. Many more attributes are available with the verbose option. See Command Line Processing for advice on how to structure your identify command or see below for example usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the identify command here to illustrate its usefulness and ease of use. To get started, lets identify an image in the JPEG format:

    - -
    --> identify rose.jpg
    -rose.jpg JPEG 70x46 70x46+0+0 8-bit sRGB 2.36KB 0.000u 0:00.000
    -
    - -

    Next, we look at the same image in greater detail:

    - -
    -> identify -verbose rose.jpg
    -Image: rose.jpg
    -  Format: JPEG (Joint Photographic Experts Group JFIF format)
    -  Mime type: images/jpeg
    -  Class: DirectClass
    -  Geometry: 70x46+0+0
    -  Units: Undefined
    -  Type: TrueColor
    -  Endianess: Undefined
    -  Colorspace: sRGB
    -  Depth: 8-bit
    -  Channel depth:
    -    red: 8-bit
    -    green: 8-bit
    -    blue: 8-bit
    -  Channel statistics:
    -    Pixels: 3220
    -    Red:
    -      min: 35 (0.137255)
    -      max: 255 (1)
    -      mean: 145.57 (0.570865)
    -      standard deviation: 67.2976 (0.263912)
    -      kurtosis: -1.37971
    -      skewness: 0.0942169
    -      entropy: 0.974889
    -    Green:
    -      min: 33 (0.129412)
    -      max: 255 (1)
    -      mean: 89.2193 (0.349879)
    -      standard deviation: 52.0803 (0.204236)
    -      kurtosis: 2.70722
    -      skewness: 1.82562
    -      entropy: 0.877139
    -    Blue:
    -      min: 11 (0.0431373)
    -      max: 255 (1)
    -      mean: 80.3742 (0.315193)
    -      standard deviation: 53.8536 (0.21119)
    -      kurtosis: 2.90978
    -      skewness: 1.92617
    -      entropy: 0.866692
    -  Image statistics:
    -    Overall:
    -      min: 11 (0.0431373)
    -      max: 255 (1)
    -      mean: 105.055 (0.411979)
    -      standard deviation: 58.1422 (0.228008)
    -      kurtosis: 1.25759
    -      skewness: 1.4277
    -      entropy: 0.90624
    -  Rendering intent: Perceptual
    -  Gamma: 0.454545
    -  Chromaticity:
    -    red primary: (0.64,0.33)
    -    green primary: (0.3,0.6)
    -    blue primary: (0.15,0.06)
    -    white point: (0.3127,0.329)
    -  Background color: white
    -  Border color: srgb(223,223,223)
    -  Matte color: grey74
    -  Transparent color: black
    -  Interlace: None
    -  Intensity: Undefined
    -  Compose: Over
    -  Page geometry: 70x46+0+0
    -  Dispose: Undefined
    -  Iterations: 0
    -  Compression: JPEG
    -  Quality: 92
    -  Orientation: Undefined
    -  Properties:
    -    date:create: 2014-11-09T09:00:35-05:00
    -    date:modify: 2014-11-09T09:00:35-05:00
    -    jpeg:colorspace: 2
    -    jpeg:sampling-factor: 2x2,1x1,1x1
    -    signature: 22a99838bd5594250f706d1d9383b2830f439fcbaf1455cbe2f7f59a4deb065a
    -  Artifacts:
    -    filename: rose.jpg
    -    verbose: true
    -  Tainted: False
    -  Filesize: 2.36KB
    -  Number pixels: 3.22K
    -  Pixels per second: 3.22EB
    -  User time: 0.000u
    -  Elapsed time: 0:01.000
    -  Version: ImageMagick Q16 http://www.imagemagick.org
    -
    - -

    To get the print size in inches of an image at 72 DPI, use:

    - -
    --> identify -format "%[fx:w/72] by %[fx:h/72] inches" document.png
    -8.5 x 11 inches
    -
    - -

    The depth and dimensions of a raw image must be specified on the command line:

    - -
    --> identify -depth 8 -size 640x480 image.raw
    -image.raw RGB 640x480 sRGB 9kb 0.000u 0:01
    -
    - -

    Here we display the image texture features, moments, perceptual hash, and the number of unique colors in the image:

    - -
    --> identify -verbose -features 1 -moments -unique image.png
    -
    - -

    Here is a special define that outputs the location of the minimum or maximum pixel of the image:

    - -
    -identify -precision 5 -define identify:locate=maximum -define identify:limit=3 image.png
    -
    - -

    You can find additional examples of using identify in Examples of ImageMagick Usage.

    - -

    Option Summary

    - -

    The identify command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
    -antialiasremove pixel-aliasing
    -authenticate valuedecrypt image with this password
    -channel typeapply option to select image channels
    -clipclip along the first path from the 8BIM profile
    -clip-mask filenameassociate clip mask with the image
    -clip-path idclip along a named path from the 8BIM profile
    -colorspace typeset image colorspace
    -crop geometrycrop the image
    -debug eventsdisplay copious debugging information
    -define format:optiondefine one or more image format options
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -endian typeendianness (MSB or LSB) of the image
    -extract geometryextract area from image
    -features distanceanalyze image features (e.g. contract, correlations, etc.).
    -format stringoutput formatted image characteristics
    -gamma valuelevel of gamma correction
    -grayscale methodconvert image to grayscale
    -helpprint program options
    -interlace typetype of image interlacing scheme
    -interpolate methodpixel color interpolation method
    -limit type valuepixel cache resource limit
    -list typeColor, Configure, Delegate, Format, Magic, Module, Resource, or Type
    -log formatformat of debugging information
    -mask filenameassociate a mask with the image
    -momentsdisplay image moments and perceptual hash.
    -monitormonitor progress
    -negatereplace each pixel with its complementary color
    -precision valueset the maximum number of significant digits to be printed
    -quietsuppress all warning messages
    -regard-warningspay attention to warning messages.
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -sampling-factor geometryhorizontal and vertical sampling factor
    -set attribute valueset an image attribute
    -size geometrywidth and height of image
    -stripstrip image of all profiles and comments
    -uniquedisplay image the number of unique colors in the image.
    -units typethe units of image resolution
    -verboseprint detailed information about the image
    -versionprint version information
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/import.html b/ImageMagick-7.0.0-0/www/import.html deleted file mode 100644 index 685ca9d2c..000000000 --- a/ImageMagick-7.0.0-0/www/import.html +++ /dev/null @@ -1,423 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Import - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    Use the import program to capture some or all of an X server screen and save the image to a file. See Command Line Processing for advice on how to structure your import command or see below for example usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the import command here to illustrate its usefulness and ease of use. To get started, lets import an image in the JPEG format:

    - -
    -import rose.jpg
    -
    - -

    To capture the entire X server screen in the Postscript image format:

    - -
    -import -window root screen.ps
    -
    - -

    You can find additional examples of using import in Graphics from the Command Line. Further discussion is available in More Graphics from the Command Line and Examples of ImageMagick Usage.

    - - -

    Option Summary

    - -

    The import command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -adjoinjoin images into a single multi-image file
    -annotate geometry textannotate the image with text
    -borderinclude window border in the output image
    -channel typeapply option to select image channels
    -colors valuepreferred number of colors in the image
    -colorspace typeset image colorspace
    -comment stringannotate image with comment
    -compress typeimage compression type
    -contrastenhance or reduce the image contrast
    -crop geometrypreferred size and location of the cropped image
    -debug eventsimport copious debugging information
    -define format:optiondefine one or more image format options
    -delay valueimport the next image after pausing
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -descendobtain image by descending window hierarchy
    -display serverget image or font from this X server
    -dispose methodlayer disposal method
    -dither methodapply error diffusion to image
    -encipher filenameconvert plain pixels to cipher pixels
    -encoding typetext encoding type
    -endian typeendianness (MSB or LSB) of the image
    -filter typeuse this filter when resizing an image
    -frameinclude window manager frame
    -geometry geometrypreferred size or location of the image
    -gravity typehorizontal and vertical text placement
    -helpprint program options
    -identifyidentify the format and characteristics of the image
    -interlace typetype of image interlacing scheme
    -interpolate methodpixel color interpolation method
    -label nameassign a label to an image
    -limit type valuepixel cache resource limit
    -log formatformat of debugging information
    -monitormonitor progress
    -monochrometransform image to black and white
    -negatereplace each pixel with its complementary color
    -page geometrysize and location of an image canvas (setting)
    -pause secondsseconds delay between snapshots
    -quality valueJPEG/MIFF/PNG compression level
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -quietsuppress all warning messages
    -regard-warningspay attention to warning messages.
    -repage geometrysize and location of an image canvas
    -resize geometryresize the image
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -rotate degreesapply Paeth rotation to the image
    -sampling-factor geometryhorizontal and vertical sampling factor
    -scene valueimage scene number
    -screenselect image from root window
    -seed valueseed a new sequence of pseudo-random numbers
    -set attribute valueset an image attribute
    -silentoperate silently, i.e. don't ring any bells
    -stripstrip image of all profiles and comments
    -synchronizesynchronize image to storage device
    -taintmark the image as modified
    -transparent-color colortransparent color
    -trimtrim image edges
    -type typeimage type
    -verboseprint detailed information about the image
    -versionprint version information
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    -window idselect window with this id or name
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/index.html b/ImageMagick-7.0.0-0/www/index.html deleted file mode 100644 index b542070dd..000000000 --- a/ImageMagick-7.0.0-0/www/index.html +++ /dev/null @@ -1,227 +0,0 @@ - - - - - - - - - ImageMagick: Convert, Edit, Or Compose Bitmap Images - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Features and Capabilities • News • Community

    - -

    -ImageMagick® is a software suite to create, edit, compose, or convert bitmap images. It can read and write images in a variety of formats (over 200) including PNG, JPEG, JPEG-2000, GIF, TIFF, DPX, EXR, WebP, Postscript, PDF, and SVG. Use ImageMagick to resize, flip, mirror, rotate, distort, shear and transform images, adjust image colors, apply various special effects, or draw text, lines, polygons, ellipses and Bézier curves.

    - -

    The functionality of ImageMagick is typically utilized from the command-line or you can use the features from programs written in your favorite language. Choose from these interfaces: G2F (Ada), MagickCore (C), MagickWand (C), ChMagick (Ch), ImageMagickObject (COM+), Magick++ (C++), JMagick (Java), L-Magick (Lisp), Lua (LuaJIT), NMagick (Neko/haXe), Magick.NET (.NET), PascalMagick (Pascal), PerlMagick (Perl), MagickWand for PHP (PHP), IMagick (PHP), PythonMagick (Python), RMagick (Ruby), or TclMagick (Tcl/TK). With a language interface, use ImageMagick to modify or create images dynamically and automagically.

    -

    ImageMagick utilizes multiple computational threads to increase performance and can read, process, or write mega-, giga-, or tera-pixel image sizes.

    -

    ImageMagick is free software delivered as a ready-to-run binary distribution or as source code that you may use, copy, modify, and distribute in both open and proprietary applications. It is distributed under the Apache 2.0 license.

    - -

    The ImageMagick development process ensures a stable API and ABI. Before each ImageMagick release, we perform a comprehensive security assessment that includes memory error and thread data race detection to prevent security vulnerabilities.

    - -

    The current release is ImageMagick 7.0.0-0. It runs on Linux, Windows, Mac Os X, iOS, Android OS, and others.

    - -

    The authoritative ImageMagick web site is http://www.imagemagick.org. The authoritative source code repository is http://git.imagemagick.org/repos/ImageMagick. We maintain a source code mirror at GitLab and GitHub.

    - -

    Features and Capabilities

    -

    Here are just a few examples of what ImageMagick can do for you:

    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Animationcreate a GIF animation sequence from a group of images.
    Color managementaccurate color management with color profiles or in lieu of-- built-in gamma compression or expansion as demanded by the colorspace.
    Command-line processingutilize ImageMagick from the command-line.
    Compositeoverlap one image over another.
    Connected component labelinguniquely label connected regions in an image.
    Decorateadd a border or frame to an image.
    Delineate image featuresCanny edge detection, Hough lines.
    Discrete Fourier transformimplements the forward and inverse DFT.
    Distributed pixel cacheoffload intermediate pixel storage to one or more remote servers.
    Drawadd shapes or text to an image.
    Encipher or decipher an imageconvert ordinary images into unintelligible gibberish and back again.
    Format conversionconvert an image from one format to another (e.g. PNG to JPEG).
    Generalized pixel distortioncorrect for, or induce image distortions including perspective.
    Heterogeneous distributed processingcertain algorithms are OpenCL-enabled to take advantage of speed-ups offered by executing in concert across heterogeneous platforms consisting of CPUs, GPUs, and other processors.
    High dynamic-range imagesaccurately represent the wide range of intensity levels found in real scenes ranging from the brightest direct sunlight to the deepest darkest shadows.
    Image calculatorapply a mathematical expression to an image or image channels.
    Image gradientscreate a gradual blend of two colors whose shape is horizontal, vertical, circular, or elliptical.
    Image identificationdescribe the format and attributes of an image.
    ImageMagick on the iPhoneconvert, edit, or compose images on your iOS device such as the iPhone or iPad.
    Large image supportread, process, or write mega-, giga-, or tera-pixel image sizes.
    Montagejuxtapose image thumbnails on an image canvas.
    Morphology of shapesextract features, describe shapes, and recognize patterns in images.
    Motion picture supportread and write the common image formats used in digital film work.
    Noise and color reductionKuwahara Filter, mean-shift.
    Perceptual hashmap visually identical images to the same or similar hash-- useful in image retrieval, authentication, indexing, or copy detection as well as digital watermarking.
    Special effectsblur, sharpen, threshold, or tint an image.
    Text & commentsinsert descriptive or artistic text in an image.
    Threads of execution supportImageMagick is thread safe and most internal algorithms execute in parallel to take advantage of speed-ups offered by multicore processor chips.
    Transformresize, rotate, deskew, crop, flip or trim an image.
    Transparencyrender portions of an image invisible.
    Virtual pixel supportconvenient access to pixels outside the image region.
    -
    - -

    Examples of ImageMagick Usage shows how to use ImageMagick from the command-line to accomplish any of these tasks and much more. Also, see Fred's ImageMagick Scripts: a plethora of command-line scripts that perform geometric transforms, blurs, sharpens, edging, noise removal, and color manipulations. With Magick.NET, use ImageMagick without having to install ImageMagick on your server or desktop.

    - -

    News

    - -

    The design of ImageMagick is an evolutionary process, with the design and implementation efforts serving to influence and guide further progress in the other. With ImageMagick version 7, we aim to improve the design based on lessons learned from the version 6 implementation. See the porting guide to track the progress of the version 7 development effort.

    - -

    Community

    -

    To join the ImageMagick community, try the discourse server. You can review questions or comments (with informed responses) posed by ImageMagick users or ask your own questions. If you want to contribute image processing algorithms, other enhancements, or bug fixes, open an issue.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/install-source.html b/ImageMagick-7.0.0-0/www/install-source.html deleted file mode 100644 index c2ac2ffaa..000000000 --- a/ImageMagick-7.0.0-0/www/install-source.html +++ /dev/null @@ -1,158 +0,0 @@ - - - - - - - - - ImageMagick: Install from Source - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Install from Unix Source • Install from Windows Source

    - -

    Chances are, ImageMagick is already installed on your computer if you are using some flavor of Unix, and its likely not installed if you are using some form of Windows. In either case, you can type the following to find out:

    - -
    -identify -version
    -
    - -

    If the identify program executes and identifies itself as ImageMagick, you may not need to install ImageMagick from source unless you want to add support for additional image formats or upgrade to a newer version. You also have the option of installing a pre-compiled binary release. However, if you still want to install from source, choose a platform, Unix or Windows. Before installing from source, you may want to review recent changes to the ImageMagick distribution.

    - -

    The authoritative source code repository is http://git.imagemagick.org/repos/ImageMagick. We maintain a source code mirror at GitHub. We test and deploy ImageMagick with Travis CI.

    - -

    Install from Unix Source

    - -

    ImageMagick builds on a variety of Unix and Unix-like operating systems including Linux, Solaris, FreeBSD, Mac OS X, and others. A compiler is required and fortunately almost all modern Unix systems have one. Download ImageMagick.tar.gz from www.imagemagick.org or a mirrors and verify its message digest.

    - -

    Unpack the distribution with this command:

    - -
    -tar xvzf ImageMagick.tar.gz
    -
    - -

    Next configure and compile ImageMagick:

    - -
     cd ImageMagick-7.0.0
    ./configure
    make
    -

    If ImageMagick configured and compiled without complaint, you are ready to install it on your system. Administrator privileges are required to install. To install, type

    - -
    -sudo make install
    -
    - -

    You may need to configure the dynamic linker run-time bindings:

    - -
    -sudo ldconfig /usr/local/lib
    -
    - -

    Finally, verify the ImageMagick install worked properly, type

    - -
    -/usr/local/bin/convert logo: logo.gif
    -
    - -

    For a more comprehensive test, run the ImageMagick validation suite. Ghostscript is a prerequisite, otherwise the EPS, PS, and PDF tests will fail.

    - -
    -make check
    -
    - -

    Congratulations, you have a working ImageMagick distribution and you are ready to use ImageMagick to convert, compose, or edit your images or perhaps you'll want to use one of the Application Program Interfaces for C, C++, Perl, and others.

    - -

    The above instructions will satisfy a great number of ImageMagick users, but we suspect a few will have additional questions or problems to consider. For example, what does one do if ImageMagick fails to configure or compile? Or what if you don't have administrator privileges and what if you don't want to install ImageMagick in the default /../usr/local folder? You will find the answer to these questions, and more, in Advanced Unix Source Installation.

    - -

    Install from Windows Source

    - -

    Building ImageMagick source for Windows requires a modern version of Microsoft Visual Studio IDE. Users have reported success with the Borland C++ compiler as well. If you don't have a compiler you can still install a self-installing binary release.

    - -

    Download ImageMagick-windows.zip from www.imagemagick.org or a mirrors and verify its message digest.

    - -

    You can unpack the distribution with WinZip or type the following from any MS-DOS Command Prompt window:

    - -
    -unzip ImageMagick-windows.zip
    -
    - -

    Next, launch your Visual Studio IDE and choose Open->Project. Select the configure workspace from the ImageMagick-7.0.0/VisualMagick/configure folder and press Open. Choose Build->Build Solution -to compile the program and on completion run the program.

    - -

    [configure]

    - -

    Press Next and click on the multi-threaded static build. If you are using the Visual Studio 6.0 IDE, make sure no check is next to the Generate Visual Studio 7 format option. Now press, on Next twice and finally Finish. The configuration utility just created a workspace required to build ImageMagick from source. Choose Open->Project and select the VisualStaticMT workspace from the ImageMagick-7.0.0/VisualMagick/ folder. Finally, choose Build->Build Solution to compile and build the ImageMagick distribution.

    - -

    To verify ImageMagick is working properly, launch a MS-DOS Command Prompt window and type

    - -
     cd ImageMagick-7.0.0
    convert logo: image.jpg
    -

    For a more comprehensive test, run the ImageMagick validation suite:

    - -
    -validate
    -
    - -

    Congratulations, you have a working ImageMagick distribution under Windows and you are ready to use ImageMagick to convert, compose, or edit your images or perhaps you'll want to use one of the Application Program Interfaces for C, C++, Perl, and others.

    - -

    The above instructions will satisfy a great number of ImageMagick users, but we suspect a few will have additional questions or problems to consider. For example, what does one do if ImageMagick fails to configure or compile? Or what if you want to install ImageMagick in a place other than the ImageMagick-7.0.0/VisualMagick/bin folder? Or perhaps you want to build and install the ImageMagickObject COM+ component. You will find the answer to these questions, and more, in Advanced Windows Source Installation.

    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/jp2.html b/ImageMagick-7.0.0-0/www/jp2.html deleted file mode 100644 index 10db158f4..000000000 --- a/ImageMagick-7.0.0-0/www/jp2.html +++ /dev/null @@ -1,160 +0,0 @@ - - - - - - - - - ImageMagick: JP2 Encoding Options - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    ImageMagick's JPEG-2000 image formats, JP2 and JPC, accept a plethora of encoding options as detailed below. As an example, suppose you are interested in these options:

    - -
      -
    • code blocks are 64 samples in width and 32 samples in height
    • -
    • no multicomponent transform
    • -
    • 4 resolution levels for each component
    • -
    • compression is lossy at 64:1
    • -
    - -

    Use this command to convert a JPEG-2000 image to the PNG image format:

    - -
    -convert wizard.jp2 wizard.png
    -
    - -

    Let's convert a JPEG image to a lossless JPEG-2000 image:

    - -
    -convert wizard.jpg -quality 0 wizard.jp2
    -
    - -

    Here we extract an area from the image:

    - -
    -convert 'wizard.jp2[640x480+0+0]' wizard.png
    -
    - -

    Extract a particular tile from the image:

    - -
    -convert 'wizard.jp2[2]' wizard.png
    -
    - -

    Specify a subsampling factor:

    - -
    -convert wizard.png -colorspace YUV -sampling-factor 2,2 wizard.jp2
    -
    - -

    Save a tiled JPEG-2000 image:

    - -
    -convert wizard.png 'wizard.png[512x512]'
    -
    - -

    Write a digital Cinema 4K profile compliant codestream:

    - -
    -convert wizard.png -resize 4096x2160! -depth 12 wizard.jp2
    -
    - -

    Here is a complete list of JPEG-2000 decoding options:

    - -
    - - - - - - - - - -
    jp2:layer-number=xset the maximum number of quality layers to decode.
    jp2:reduce-factor=xset the number of highest resolution levels to be discarded.
    - -

    Here is a complete list of JPEG-2000 encoding options:

    - -
    - - -
    jp2:number-resolutions=x
    -
    number of resolutions to encode.
    - - - - - - - - - - - - - -
    jp2:quality=x,x,...set the quality layer PSNR, given in dB. The order is from left to right in ascending order. The default is a single lossless quality layer.
    jp2:rate=x,x,...the compression ratio values. Each value is a factor of compression, thus 20 means 20 times compressed. The order is from left to right in descending order. A final lossless quality layer is signified by the value 1. The default is a single lossless quality layer.
    jp2:progression-order=xchoose from LRCP, RLCP, RPCL, PCRL or CPRL.
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/license.html b/ImageMagick-7.0.0-0/www/license.html deleted file mode 100644 index 7ef79dd6c..000000000 --- a/ImageMagick-7.0.0-0/www/license.html +++ /dev/null @@ -1,199 +0,0 @@ - - - - - - - - - ImageMagick: License - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Terms and Conditions for Use, Reproduction, and Distribution • How to Apply the License to your Work

    - -

    Before we get to the text of the license, lets just review what the license says in simple terms:

    - -

    It allows you to:

    - -
      -
    • freely download and use ImageMagick software, in whole or in part, for personal, company internal, or commercial purposes;
    • -
    • use ImageMagick software in packages or distributions that you create;
    • -
    • link against a library under a different license;
    • -
    • link code under a different license against a library under this license;
    • -
    • merge code into a work under a different license;
    • -
    • extend patent grants to any code using code under this license;
    • -
    • and extend patent protection.
    • -
    - -

    It forbids you to:

    - -
      -
    • redistribute any piece of ImageMagick-originated software without proper attribution;
    • -
    • use any marks owned by ImageMagick Studio LLC in any way that might state or imply that ImageMagick Studio LLC endorses your distribution;
    • -
    • use any marks owned by ImageMagick Studio LLC in any way that might state or imply that you created the ImageMagick software in question.
    • -
    - -

    It requires you to:

    - -
      -
    • include a copy of the license in any redistribution you may make that includes ImageMagick software;
    • -
    • provide clear attribution to ImageMagick Studio LLC for any distributions that include ImageMagick software.
    • -
    - -

    It does not require you to:

    - -
      -
    • include the source of the ImageMagick software itself, or of any modifications you may have made to it, in any redistribution you may assemble that includes it;
    • -
    • submit changes that you make to the software back to the ImageMagick Studio LLC (though such feedback is encouraged).
    • -
    - -

    A few other clarifications include:

    - -
      -
    • ImageMagick is freely available without charge;
    • -
    • you may include ImageMagick on a DVD as long as you comply with the terms of the license;
    • -
    • you can give modified code away for free or sell it under the terms of the ImageMagick license or distribute the result under a different license, but you need to acknowledge the use of the ImageMagick software;
    • -
    • the license is compatible with the GPL V3.
    • -
    • when exporting the ImageMagick software, review its export classification.
    • -
    - - -

    Terms and Conditions for Use, Reproduction, and Distribution

    - -

    The legally binding and authoritative terms and conditions for use, reproduction, and distribution of ImageMagick follow:

    - -

    Copyright 1999-2016 ImageMagick Studio LLC, a non-profit organization dedicated to making software imaging solutions freely available.

    - -

    1. Definitions.

    - -

    License shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.

    - -

    Licensor shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.

    - -

    Legal Entity shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, control means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.

    - -

    You (or Your) shall mean an individual or Legal Entity exercising permissions granted by this License.

    - -

    Source form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.

    - -

    Object form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.

    - -

    Work shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).

    - -

    Derivative Works shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.

    - -

    Contribution shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as Not a Contribution.

    - -

    Contributor shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.

    - -

    2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.

    - -

    3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.

    - -

    4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:

    - -
      -
    1. You must give any other recipients of the Work or Derivative Works a copy of this License; and
    2. - -
    3. You must cause any modified files to carry prominent notices stating that You changed the files; and
    4. - -
    5. You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
    6. - -
    7. If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License.
    8. -
    - -

    You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.

    - -

    5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.

    - -

    6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.

    - -

    7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.

    - -

    8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.

    - -

    9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.

    - - -

    How to Apply the License to your Work

    - -

    To apply the ImageMagick License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information (don't include the brackets). The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives.

    - -
    -   Copyright [yyyy] [name of copyright owner]
    -
    -   Licensed under the ImageMagick License (the "License"); you may not use
    -   this file except in compliance with the License.  You may obtain a copy
    -   of the License at
    -
    -     http://www.imagemagick.org/www/license.html
    -
    -   Unless required by applicable law or agreed to in writing, software
    -   distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
    -   WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
    -   License for the specific language governing permissions and limitations
    -   under the License.
    -
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/links.html b/ImageMagick-7.0.0-0/www/links.html deleted file mode 100644 index f3eae26d3..000000000 --- a/ImageMagick-7.0.0-0/www/links.html +++ /dev/null @@ -1,159 +0,0 @@ - - - - - - - - - ImageMagick: Related Web Sites - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Use ImageMagick on the Web • Command-line Tutorials • Program Interface Tutorials • ImageMagick Techniques • Installation Tutorials • ImageMagick Topics • ImageMagick Book Review • Web Site Mirrors • Image Bank • Other Projects

    - -

    Listed here are a number of external web sites that are related to ImageMagick. ImageMagick Studio does not maintain or endorse these sites, excepting the Wizard's Toolkit site, but we feel they are a helpfull adjunct to this web site.

    - -

    Use ImageMagick on the Web

    - - -

    Command-line Tutorials

    - - -

    Program Interface Tutorials

    - - - -

    Installation Tutorials

    - - - -

    ImageMagick Techniques

    - - - -

    ImageMagick Topics

    - - -

    ImageMagick Book Review

    - - -

    ImageMagick Web Site Mirrors

    - - -

    Image Bank

    - - - -

    Other Projects

    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/magick++.html b/ImageMagick-7.0.0-0/www/magick++.html deleted file mode 100644 index e28877480..000000000 --- a/ImageMagick-7.0.0-0/www/magick++.html +++ /dev/null @@ -1,183 +0,0 @@ - - - - - - - - - ImageMagick: Magick++, C++ API for ImageMagick - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Documentation • Obtaining Magick++ • Installation • Reporting Bugs

    - - -

    Magick++ API is the object-oriented C++ API to the ImageMagick image-processing library.

    -

    Magick++ supports an object model which is inspired by PerlMagick. -Images support implicit reference counting so that copy constructors -and assignment incur almost no cost. The cost of actually copying an -image (if necessary) is done just before modification and this copy -is managed automagically by Magick++. De-referenced copies are -automagically deleted. The image objects support value (rather than -pointer) semantics so it is trivial to support multiple generations -of an image in memory at one time. -

    -

    Magick++ provides integrated support for the Standard -Template Library (STL) so that the powerful containers available -(e.g. deque, -vector, list, -and map) can -be used to write programs similar to those possible with PERL & -PerlMagick. STL-compatible template versions of ImageMagick's -list-style operations are provided so that operations may be -performed on multiple images stored in STL containers. -

    -

    Documentation

    - -

    Detailed documentation is -provided for all Magick++ classes, class methods, and template -functions which comprise the API. See a Gentle Introduction to Magick++ for an introductory tutorial to Magick++. We include the source if you want to correct, enhance, or expand the tutorial.

    -

    Obtaining Magick++

    - -

    Magick++ is included as part of ImageMagick -source releases and may be retrieved via ftp -or GIT. -

    -

    Installation

    - -

    Once you have the Magick++ sources available, follow these detailed -installation instructions for UNIX and -Windows. -

    -

    Usage

    -

    A helper script named Magick++-config is installed -under Unix which assists with recalling compilation options required -to compile and link programs which use Magick++. For example, the -following command compiles and links the source file demo.cpp -to produce the executable demo (notice that quotes are -backward quotes): -

    -
    -c++ `Magick++-config --cxxflags --cppflags` -O2 -o demo demo.cpp \
    -  `Magick++-config --ldflags --libs`
    -
    -

    Set the PKG_CONFIG_PATH environment variable if ImageMagick is not in your default system path:

    - -
    -export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
    -
    - -

    Windows users may get started by manually editing a project file -for one of the Magick++ demo programs. -

    -

    Note, under Windows (and possibly the Mac) it may be necessary to initialize the ImageMagick library prior to using the Magick++ library. This initialization is performed by passing the path to the ImageMagick DLLs (assumed to be in the same directory as your program) to the InitializeMagick() function call. This is commonly performed by providing the path to your program (argv[0]) as shown in the following example:

    -
    -int main( int argc, char ** argv) {
    -  InitializeMagick(*argv);
    -  ...
    -
    -

    This initialization step is not required under Unix, Linux, -Cygwin, or any other operating environment that supports the notion -of installing ImageMagick in a known location.

    -

    Here is a example program that utilizes the Magick++ API to get you started, magick++.cpp. It reads an image, crops it, and writes it to disk in the PNG image format.

    - -
    -#include <Magick++.h> 
    -#include <iostream> 
    -
    -using namespace std; 
    -using namespace Magick; 
    -
    -int main(int argc,char **argv) 
    -{ 
    -  InitializeMagick(*argv);
    -
    -  // Construct the image object. Seperating image construction from the 
    -  // the read operation ensures that a failure to read the image file 
    -  // doesn't render the image object useless. 
    -  Image image;
    -  try { 
    -    // Read a file into image object 
    -    image.read( "logo:" );
    -
    -    // Crop the image to specified size (width, height, xOffset, yOffset)
    -    image.crop( Geometry(100,100, 100, 100) );
    -
    -    // Write the image to a file 
    -    image.write( "logo.png" ); 
    -  } 
    -  catch( Exception &error_ ) 
    -    { 
    -      cout << "Caught exception: " << error_.what() << endl; 
    -      return 1; 
    -    } 
    -  return 0; 
    -}
    -
    -

    Reporting Bugs

    - -

    Questions regarding usage should be directed to or to report any bugs go to -Magick++ bug tracking forum. -

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/magick-core.html b/ImageMagick-7.0.0-0/www/magick-core.html deleted file mode 100644 index 14313f278..000000000 --- a/ImageMagick-7.0.0-0/www/magick-core.html +++ /dev/null @@ -1,333 +0,0 @@ - - - - - - - - - ImageMagick: MagickCore, Low-level C API for ImageMagick - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    The MagickCore API is a low-level interface between the C programming language and the ImageMagick image processing libraries and is recommended for wizard-level programmers only. Unlike the MagickWand C API which uses only a few opaque types and accessors, with MagickCore you almost exlusively access the structure members directly. A description of the MagickCore public methods are found here:

    - - - -

    After you write your MagickCore program, compile it like this:

    - -
    -cc -o core core.c `pkg-config --cflags --libs MagickCore`
    -
    - -

    Note, if your instance of ImageMagick does not support modules but does include support for the WMF image format, you'll need to link with the MagickWand library instead (since it is a dependency of the WMF image format):

    - -
    -cc -o core core.c `pkg-config --cflags --libs MagickWand`
    -
    - -

    Set the PKG_CONFIG_PATH environment variable if ImageMagick is not in your default system path:

    - -
    -export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
    -
    - -

    Here is a example program that utilizes the MagickCore API to get you started, core.c. It reads a GIF image, creates a thumbnail, and writes it to disk in the PNG image format.

    - -
    #include <stdio.h>
    -#include <stdlib.h>
    -#include <string.h>
    -#include <time.h>
    -#include <magick/MagickCore.h>
    -
    -int main(int argc,char **argv)
    -{
    -  ExceptionInfo
    -    *exception;
    -
    -  Image
    -    *image,
    -    *images,
    -    *resize_image,
    -    *thumbnails;
    -
    -  ImageInfo
    -    *image_info;
    -
    -  if (argc != 3)
    -    {
    -      (void) fprintf(stdout,"Usage: %s image thumbnail\n",argv[0]);
    -      exit(0);
    -    }
    -  /*
    -    Initialize the image info structure and read an image.
    -  */
    -  MagickCoreGenesis(*argv,MagickTrue);
    -  exception=AcquireExceptionInfo();
    -  image_info=CloneImageInfo((ImageInfo *) NULL);
    -  (void) strcpy(image_info->filename,argv[1]);
    -  images=ReadImage(image_info,exception);
    -  if (exception->severity != UndefinedException)
    -    CatchException(exception);
    -  if (images == (Image *) NULL)
    -    exit(1);
    -  /*
    -    Convert the image to a thumbnail.
    -  */
    -  thumbnails=NewImageList();
    -  while ((image=RemoveFirstImageFromList(&images)) != (Image *) NULL)
    -  {
    -    resize_image=ResizeImage(image,106,80,LanczosFilter,1.0,exception);
    -    if (resize_image == (Image *) NULL)
    -      MagickError(exception->severity,exception->reason,exception->description);
    -    (void) AppendImageToList(&thumbnails,resize_image);
    -    DestroyImage(image);
    -  }
    -  /*
    -    Write the image thumbnail.
    -  */
    -  (void) strcpy(thumbnails->filename,argv[2]);
    -  WriteImage(image_info,thumbnails);
    -  /*
    -    Destroy the image thumbnail and exit.
    -  */
    -  thumbnails=DestroyImageList(thumbnails);
    -  image_info=DestroyImageInfo(image_info);
    -  exception=DestroyExceptionInfo(exception);
    -  MagickCoreTerminus();
    -  return(0);
    -}
    -

    Now lets perform the same contrast enhancement while taking advantage of our dual or quad-core processing system by running the algorithm in parallel utilizing wand views. The sigmoidal-contrast.c module reads an image, applies sigmoidal non-linearity contrast control, and writes the result to disk just like the previous contrast enhancement program, but now it does its work in parallel (assumes ImageMagick is built with OpenMP support).

    - -
    #include <stdio.h>
    -#include <stdlib.h>
    -#include <math.h>
    -#include <magick/MagickCore.h>
    -
    -static MagickBooleanType SigmoidalContrast(ImageView *contrast_view,
    -  const ssize_t y,const int id,void *context)
    -{
    -#define QuantumScale  ((MagickRealType) 1.0/(MagickRealType) QuantumRange)
    -#define SigmoidalContrast(x) \
    -  (QuantumRange*(1.0/(1+exp(10.0*(0.5-QuantumScale*x)))-0.0066928509)*1.0092503)
    -
    -  RectangleInfo
    -    extent;
    -
    -  register IndexPacket
    -    *indexes;
    -
    -  register PixelPacket
    -    *pixels;
    -
    -  register ssize_t
    -    x;
    -
    -  extent=GetImageViewExtent(contrast_view);
    -  pixels=GetImageViewAuthenticPixels(contrast_view);
    -  for (x=0; x < (ssize_t) (extent.width-extent.x); x++)
    -  {
    -    SetPixelRed(pixels,RoundToQuantum(SigmoidalContrast(GetPixelRed(pixels)));
    -    SetPixelGreen(pixels,RoundToQuantum(SigmoidalContrast(GetPixelGreen(pixels)));
    -    SetPixelBlue(pixels,RoundToQuantum(SigmoidalContrast(GetPixelBlue(pixels)));
    -    SetPixelOpacity(pixels,RoundToQuantum(SigmoidalContrast(GetPixelOpacity(pixels)));
    -    pixels++;
    -  }
    -  indexes=GetImageViewAuthenticIndexes(contrast_view);
    -  if (indexes != (IndexPacket *) NULL)
    -    for (x=0; x < (ssize_t) (extent.width-extent.x); x++)
    -      SetPixelIndex(indexes+x,RoundToQuantum(SigmoidalContrast(GetPixelIndex(indexes+x))));
    -  return(MagickTrue);
    -}
    -
    -int main(int argc,char **argv)
    -{
    -#define ThrowImageException(image) \
    -{ \
    - \
    -  CatchException(exception); \
    -  if (contrast_image != (Image *) NULL) \
    -    contrast_image=DestroyImage(contrast_image); \
    -  exit(-1); \
    -}
    -#define ThrowViewException(view) \
    -{ \
    -  char \
    -    *description; \
    - \
    -  ExceptionType \
    -    severity; \
    - \
    -  description=GetImageViewException(view,&severity); \
    -  (void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
    -  description=DestroyString(description); \
    -  exit(-1); \
    -}
    -
    -  ExceptionInfo
    -    *exception;
    -
    -  Image
    -    *contrast_image;
    -
    -  ImageInfo
    -    *image_info;
    -
    -  ImageView
    -    *contrast_view;
    -
    -  MagickBooleanType
    -    status;
    -
    -  if (argc != 3)
    -    {
    -      (void) fprintf(stdout,"Usage: %s image sigmoidal-image\n",argv[0]);
    -      exit(0);
    -    }
    -  /*
    -    Read an image.
    -  */
    -  MagickCoreGenesis(*argv,MagickTrue);
    -  image_info=AcquireImageInfo();
    -  (void) CopyMagickString(image_info->filename,argv[1],MaxTextExtent);
    -  exception=AcquireExceptionInfo();
    -  contrast_image=ReadImage(image_info,exception);
    -  if (contrast_image == (Image *) NULL)
    -    ThrowImageException(contrast_image);
    -  /*
    -    Sigmoidal non-linearity contrast control.
    -  */
    -  contrast_view=NewImageView(contrast_image);
    -  if (contrast_view == (ImageView *) NULL)
    -    ThrowImageException(contrast_image);
    -  status=UpdateImageViewIterator(contrast_view,SigmoidalContrast,(void *) NULL);
    -  if (status == MagickFalse)
    -    ThrowImageException(contrast_image);
    -  contrast_view=DestroyImageView(contrast_view);
    -  /*
    -    Write the image then destroy it.
    -  */
    -  status=WriteImages(image_info,contrast_image,argv[2],exception);
    -  if (status == MagickFalse)
    -    ThrowImageException(contrast_image);
    -  contrast_image=DestroyImage(contrast_image);
    -  exception=DestroyExceptionInfo(exception);
    -  image_info=DestroyImageInfo(image_info);
    -  MagickCoreTerminus();
    -  return(0);
    -}
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/magick-vector-graphics.html b/ImageMagick-7.0.0-0/www/magick-vector-graphics.html deleted file mode 100644 index 71bbaa5c2..000000000 --- a/ImageMagick-7.0.0-0/www/magick-vector-graphics.html +++ /dev/null @@ -1,876 +0,0 @@ - - - - - - - - - ImageMagick: Magick Vector Graphics - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    MVG Overview • Drawing Primitives

    - -

    This specification defines the features and syntax for Magick Vector Graphics (MVG), a modularized language for describing two-dimensional vector and mixed vector/raster graphics in ImageMagick. You can use the language to draw from the -command line, from an MVG file, from an SVG -- Scalable Vector Graphics file or from one of the ImageMagick program interfaces. Use this command, for example, to render an arc:

    - -
    -convert -size 100x60 canvas:skyblue -fill white -stroke black \
    -  -draw "path \'M 30,40  A 30,20  20  0,0 70,20 A 30,20  20  1,0 30,40 Z \'" \
    -  arc.png');
    -
    - -

    and here is the result:

    - -
      - arc -
    - -

    When the drawing gets sufficiently complex, we recommend you assemble the graphic primitives into a MVG file. For our example, we use piechart.mvg:

    - -
    push graphic-context
    -  viewbox 0 0 624 369
    -  affine 0.283636 0 0 0.283846 -0 -0
    -  push graphic-context
    -    push graphic-context
    -      fill 'darkslateblue'
    -      stroke 'blue'
    -      stroke-width 1
    -      rectangle 1,1 2199,1299
    -    pop graphic-context
    -    push graphic-context
    -      font-size 40
    -      fill 'white'
    -      stroke-width 1
    -      text 600,1100 'Average: 20.0'
    -    pop graphic-context
    -    push graphic-context
    -      fill 'red'
    -      stroke 'black'
    -      stroke-width 5
    -      path 'M700.0,600.0 L340.0,600.0 A360.0,360.0 0 0,1 408.1452123287954,389.2376150414973 z'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 40
    -      fill 'white'
    -      stroke-width 1
    -      text 1400,140 'MagickWand for PHP'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 30
    -      fill 'white'
    -      stroke-width 1
    -      text 1800,140 '(10.0%)'
    -    pop graphic-context
    -    push graphic-context
    -      fill 'red'
    -      stroke 'black'
    -      stroke-width 4
    -      rectangle 1330,100 1370,140
    -    pop graphic-context
    -    push graphic-context
    -      fill 'yellow'
    -      stroke 'black'
    -      stroke-width 5
    -      path 'M700.0,600.0 L408.1452123287954,389.2376150414973 A360.0,360.0 0 0,1 976.5894480359858,369.56936567559273 z'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 40
    -      fill 'white'
    -      stroke-width 1
    -      text 1400,220 'MagickCore'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 30
    -      fill 'white'
    -      stroke-width 1
    -      text 1800,220 '(29.0%)'
    -    pop graphic-context
    -    push graphic-context
    -      fill 'yellow'
    -      stroke 'black'
    -      stroke-width 4
    -      rectangle 1330,180 1370,220
    -    pop graphic-context
    -    push graphic-context
    -      fill 'fuchsia'
    -      stroke 'black'
    -      stroke-width 5
    -      path 'M700.0,600.0 L976.5894480359858,369.56936567559273 A360.0,360.0 0 0,1 964.2680466142854,844.4634932636567 z'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 40
    -      fill 'white'
    -      stroke-width 1
    -      text 1400,300 'MagickWand'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 30
    -      fill 'white'
    -      stroke-width 1
    -      text 1800,300 '(22.9%)'
    -    pop graphic-context
    -    push graphic-context
    -      fill 'fuchsia'
    -      stroke 'black'
    -      stroke-width 4
    -      rectangle 1330,260 1370,300
    -    pop graphic-context
    -    push graphic-context
    -      fill 'blue'
    -      stroke 'black'
    -      stroke-width 5
    -      path 'M700.0,600.0 L964.2680466142854,844.4634932636567 A360.0,360.0 0 0,1 757.853099990584,955.3210081341651 z'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 40
    -      fill 'white'
    -      stroke-width 1
    -      text 1400,380 'JMagick'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 30
    -      fill 'white'
    -      stroke-width 1
    -      text 1800,380 '(10.6%)'
    -    pop graphic-context
    -    push graphic-context
    -      fill 'blue'
    -      stroke 'black'
    -      stroke-width 4
    -      rectangle 1330,340 1370,380
    -    pop graphic-context
    -    push graphic-context
    -      fill 'lime'
    -      stroke 'black'
    -      stroke-width 5
    -      path 'M700.0,600.0 L757.853099990584,955.3210081341651 A360.0,360.0 0 0,1 340.0,600.0 z'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 40
    -      fill 'white'
    -      stroke-width 1
    -      text 1400,460 'Magick++'
    -    pop graphic-context
    -    push graphic-context
    -      font-size 30
    -      fill 'white'
    -      stroke-width 1
    -      text 1800,460 '(27.5%)'
    -    pop graphic-context
    -    push graphic-context
    -      fill 'lime'
    -      stroke 'black'
    -      stroke-width 4
    -      rectangle 1330,420 1370,460
    -    pop graphic-context
    -    push graphic-context
    -      font-size 100
    -      fill 'white'
    -      stroke-width 1
    -      text 100,150 'ImageMagick'
    -    pop graphic-context
    -    push graphic-context
    -      fill 'none'
    -      stroke 'black'
    -      stroke-width 5
    -      circle 700,600 700,960
    -    pop graphic-context
    -  pop graphic-context
    -pop graphic-context
    -
    - -

    to render a pie chart with this command:

    - -
    -convert piechart.mvg piechart.png
    -
    - -

    which produces this rendering:

    - -
      - piechart -
    - -

    However, in general, MVG is sufficiently difficult to work with that you probably want to use a program to generate your graphics in the SVG format. ImageMagick automagically converts SVG to MVG and renders your image, for example, we render piechart.svg with this command:

    - -
    -convert piechart.svg piechart.jpg
    -
    - - -

    to produce the same pie chart we created with the MVG language.

    - -

    Drawing is available from many of the ImageMagick program interfaces as well. ImageMagick converts the drawing API calls to MVG and renders it. Here is example code written in the MagickWand language:

    - -
    (void) PushDrawingWand(draw_wand);
    -{
    -  const PointInfo points[6] =
    -  {
    -    { 180,504 },
    -    { 282.7,578.6 },
    -    { 243.5,699.4 },
    -    { 116.5,699.4 },
    -    { 77.26,578.6 },
    -    { 180,504 }
    -  };
    -
    -  DrawSetStrokeAntialias(draw_wand,True);
    -  DrawSetStrokeWidth(draw_wand,9);
    -  DrawSetStrokeLineCap(draw_wand,RoundCap);
    -  DrawSetStrokeLineJoin(draw_wand,RoundJoin);
    -  (void) DrawSetStrokeDashArray(draw_wand,0,(const double *)NULL);
    -  (void) PixelSetColor(color,"#4000c2");
    -  DrawSetStrokeColor(draw_wand,color);
    -  DrawSetFillRule(draw_wand,EvenOddRule);
    -  (void) PixelSetColor(color,"#800000");
    -  DrawSetFillColor(draw_wand,color);
    -  DrawPolygon(draw_wand,6,points);
    -}
    -(void) PopDrawingWand(draw_wand);
    -
    - -

    MVG Overview

    - -

    MVG ignores all white-space between commands. This allows multiple MVG commands per line. It is common convention to terminate each MVG command with a new line to make MVG easier to edit and read. This syntax description uses indentation in MVG sequences to aid with understanding. Indentation is supported but is not required.

    - -

    Metafile wrapper syntax (to support stand-alone MVG files):

    - -
    -push graphic-context
    -  viewbox 0 0 width height
    -  [ any other MVG commands ]
    -pop graphic-context
    -
    - -

    Pattern syntax (saving and restoring context):

    - -
    -push pattern id x,y width,height
    - push graphic-context
    -  [ drawing commands ]
    - pop graphic-context
    -pop pattern
    -
    - -

    an example is (%s is a identifier string):

    - -
    -push defs
    - push pattern %s 10,10 20,20
    -  push graphic-context
    -   fill red
    -   rectangle 5,5 15,15
    -  pop graphic-context
    -  push graphic-context
    -   fill green
    -   rectangle 10,10 20,20
    -  pop graphic-context
    - pop pattern
    -pop defs
    -
    - -

    For image tiling use:

    - -
    -push pattern id x,y width,height
    - image Copy ...
    -pop pattern
    -
    - -

    Note you can use the pattern for either the fill or stroke like:

    - -
    -stroke url(#%s)
    -
    - -

    or

    - -
    -fill url(#%s)
    -
    - -

    The clip path defines a clipping area, where only the contained area to be drawn upon. Areas outside of the clipping areare masked.

    - -
    -push defs
    - push clip-path %s
    -  push graphic-context
    -   rectangle 10,10 20,20
    -  pop graphic-context
    - pop clip-path
    -pop defs
    -clip-path url(#%s)
    -
    - -

    Drawing Primitives

    - -

    Here is a complete description of the MVG drawing primitives:

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    PrimitiveDescription
    affine sx,rx,ry,sy,tx,ty
    arc x0,y0 x1,y1 a0,a1
    bezier x0,y0 ... xn,ynBezier (spline) requires three or more x,y coordinates to define its shape. The first and last points are the knots (preserved coordinates) and any intermediate coordinates are the control points. If two control points are specified, the line between each end knot and its sequentially respective control point determines the tangent direction of the curve at that end. If one control point is specified, the lines from the end knots to the one control point determines the tangent directions of the curve at each end. If more than two control points are specified, then the additional control points act in combination to determine the intermediate shape of the curve. In order to draw complex curves, it is highly recommended either to use the Path primitive or to draw multiple four-point bezier segments with the start and end knots of each successive segment repeated.
    border-color color
    circle originx,originy perimeterx,perimetery
    clip-path url(name)
    clip-rule ruleChoose from these rule types: -
    evenodd
    -nonzero
    clip-units unitsChoose from these unit types: -
    userSpace
    -userSpaceOnUse
    -objectBoundingBox
    color x,y methodChoose from these method types: -
    point
    -replace
    -floodfill
    -filltoborder
    -reset
    decorate typeChoose from these types of decorations: -
    none
    -line-through
    -overline
    -underline
    ellipse centerx,centery radiusx,radiusy arcstart,arcstop
    fill colorChoose from any of these colors.
    fill-opacity opacityThe opacity ranges from 0.0 (fully transparent) to 1.0 (fully opaque) or as a percentage (e.g. 50%).
    fill-rule ruleChoose from these rule types: -
    evenodd
    -nonzero
    font name
    font-family family
    font-size point-size
    font-stretch typeChoose from these stretch types: -
    all
    -normal
    -ultra-condensed
    -extra-condensed
    -condensed
    -semi-condensed
    -semi-expanded
    -expanded
    -extra-expanded
    -ultra-expanded
    font-style styleChoose from these styles: -
    all
    -normal
    -italic
    -oblique
    font-weight weightChoose from these weights: -
    all
    -normal
    -bold
    -100
    -200
    -300
    -400
    -500
    -600
    -700
    -800
    -900
    gradient-units unitsChoose from these units: -
    userSpace
    -userSpaceOnUse
    -objectBoundingBox
    gravity typeChoose from these gravity types: -
    NorthWest
    -North
    -NorthEast
    -West
    -Center
    -East
    -SouthWest
    -South
    -SouthEast
    image compose x,y width,height 'filename'Choose from these compose operations: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    MethodDescription
    clearBoth the color and the alpha of the destination are cleared. Neither the source nor the destination are used as input.
    srcThe source is copied to the destination. The destination is not used as input.
    dstThe destination is left untouched.
    src-overThe source is composited over the destination.
    dst-overThe destination is composited over the source and the result replaces the destination.
    src-inThe part of the source lying inside of the destination replaces the destination.
    dst-inThe part of the destination lying inside of the source replaces the destination.
    src-outThe part of the source lying outside of the destination replaces the destination.
    dst-outThe part of the destination lying outside of the source replaces the destination.
    src-atopThe part of the source lying inside of the destination is composited onto the destination.
    dst-atopThe part of the destination lying inside of the source is composited over the source and replaces the destination.
    multiplyThe source is multiplied by the destination and replaces the destination. The resultant color is always at least as dark as either of the two constituent colors. Multiplying any color with black produces black. Multiplying any color with white leaves the original color unchanged.
    screenThe source and destination are complemented and then multiplied and then replace the destination. The resultant color is always at least as light as either of the two constituent colors. Screening any color with white produces white. Screening any color with black leaves the original color unchanged.
    overlayMultiplies or screens the colors, dependent on the destination color. Source colors overlay the destination whilst preserving its highlights and shadows. The destination color is not replaced, but is mixed with the source color to reflect the lightness or darkness of the destination.
    darkenSelects the darker of the destination and source colors. The destination is replaced with the source when the source is darker, otherwise it is left unchanged.
    lightenSelects the lighter of the destination and source colors. The destination is replaced with the source when the source is lighter, otherwise it is left unchanged.
    linear-lightIncrease contrast slightly with an impact on the foreground's tonal values.
    color-dodgeBrightens the destination color to reflect the source color. Painting with black produces no change.
    color-burnDarkens the destination color to reflect the source color. Painting with white produces no change.
    hard-lightMultiplies or screens the colors, dependent on the source color value. If the source color is lighter than 0.5, the destination is lightened as if it were screened. If the source color is darker than 0.5, the destination is darkened, as if it were multiplied. The degree of lightening or darkening is proportional to the difference between the source color and 0.5. If it is equal to 0.5 the destination is unchanged. Painting with pure black or white produces black or white.
    soft-lightDarkens or lightens the colors, dependent on the source color value. If the source color is lighter than 0.5, the destination is lightened. If the source color is darker than 0.5, the destination is darkened, as if it were burned in. The degree of darkening or lightening is proportional to the difference between the source color and 0.5. If it is equal to 0.5, the destination is unchanged. Painting with pure black or white produces a distinctly darker or lighter area, but does not result in pure black or white.
    plusThe source is added to the destination and replaces the destination. This operator is useful for animating a dissolve between two images.
    addAs per 'plus' but transparency data is treated as matte - values. As such any transparent areas in either image remain - transparent.
    minusSubtract the colors in the source image from the - destination image. When transparency is involved, Opaque areas will be - subtracted from any destination opaque areas.
    subtractSubtract the colors in the source image from the - destination image. When transparency is involved transparent areas are - subtracted, so only the opaque areas in the source remain opaque in - the destination image.
    differenceSubtracts the darker of the two constituent colors from the lighter. Painting with white inverts the destination color. Painting with black produces no change.
    exclusionProduces an effect similar to that of 'difference', but appears as lower contrast. Painting with white inverts the destination color. Painting with black produces no change.
    xorThe part of the source that lies outside of the destination is combined with the part of the destination that lies outside of the source.
    copy-*Copy the specified channel in the source image to the - same channel in the destination image. If the channel specified in - the source image does not exist, (which can only happen for methods, - 'copy-opacity' or 'copy-black') then it is - assumed that the source image is a special grayscale channel image - of the values to be copied.
    change-maskReplace any destination pixel that is the similar to the source images pixel (as defined by the current -fuzz factor), with transparency.
    interline-spacing pixels
    interword-spacing pixels
    kerning pixels
    line x,y x1,y1
    matte x,y methodChoose from these methods: -
    point
    -replace
    -floodfill
    -filltoborder
    -reset
    offset offset
    opacity opacityUse percent (e.g. 50%).
    path path
    point x,y
    polygon x,y x1,y1, ..., xn,yn
    polyline x,y x1,y1, ..., xn,yn
    pop clip-path
    pop defs
    pop gradient
    pop graphic-context
    pop pattern
    push clip-path name
    push defs
    push gradient id linear x,y x1,y1
    push gradient id radial xc,cy xf,yf radius
    push graphic-context
    push pattern id radial x,y width,height
    rectangle x,y x1,y1
    rotate angle
    roundrectangle x,y x1,y1 width,height
    scale x,y
    skewX angle
    skewX angle
    stop-color color offset
    stroke color
    stroke-antialias 0 • 1
    stroke-dasharray none • numeric-list
    stroke-dashoffset offset
    stroke-linecap typeChoose from these cap types: -
    butt
    -round
    -square
    stroke-linejoin typeChoose from these join types: -
    bevel
    -miter
    -round
    stroke-miterlimit limit
    stroke-opacity opacityThe opacity ranges from 0.0 (fully transparent) to 1.0 (fully opaque) or as a percentage (e.g. 50%).
    stroke-width width
    text "text"
    text-antialias 0 • 1
    text-undercolor color
    translate x,y
    viewbox x,y x1,y1
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/magick-wand.html b/ImageMagick-7.0.0-0/www/magick-wand.html deleted file mode 100644 index b731825b2..000000000 --- a/ImageMagick-7.0.0-0/www/magick-wand.html +++ /dev/null @@ -1,379 +0,0 @@ - - - - - - - - - ImageMagick: MagickWand, C API for ImageMagick - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    The MagickWand API is the recommended interface between the C programming language and the ImageMagick image processing libraries. Unlike the MagickCore C API, MagickWand uses only a few opaque types. Accessors are available to set or get important wand properties. A description of the MagickWand public methods are found here:

    - - - -

    After you write your MagickWand program, compile it like this:

    - -
    -cc -o wand wand.c `pkg-config --cflags --libs MagickWand`
    -
    - -

    Set the PKG_CONFIG_PATH environment variable if ImageMagick is not in your default system path:

    - -
    -export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
    -
    - -

    Here is a example program that utilizes the MagickWand API to get you started, wand.c. It reads an image, creates a thumbnail, and writes the result to disk.

    - -
    #include <stdio.h>
    -#include <stdlib.h>
    -#include <wand/MagickWand.h>
    -
    -int main(int argc,char **argv)
    -{
    -#define ThrowWandException(wand) \
    -{ \
    -  char \
    -    *description; \
    - \
    -  ExceptionType \
    -    severity; \
    - \
    -  description=MagickGetException(wand,&severity); \
    -  (void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
    -  description=(char *) MagickRelinquishMemory(description); \
    -  exit(-1); \
    -}
    -
    -  MagickBooleanType
    -    status;
    -
    -  MagickWand
    -    *magick_wand;
    -
    -  if (argc != 3)
    -    {
    -      (void) fprintf(stdout,"Usage: %s image thumbnail\n",argv[0]);
    -      exit(0);
    -    }
    -  /*
    -    Read an image.
    -  */
    -  MagickWandGenesis();
    -  magick_wand=NewMagickWand();
    -  status=MagickReadImage(magick_wand,argv[1]);
    -  if (status == MagickFalse)
    -    ThrowWandException(magick_wand);
    -  /*
    -    Turn the images into a thumbnail sequence.
    -  */
    -  MagickResetIterator(magick_wand);
    -  while (MagickNextImage(magick_wand) != MagickFalse)
    -    MagickResizeImage(magick_wand,106,80,LanczosFilter,1.0);
    -  /*
    -    Write the image then destroy it.
    -  */
    -  status=MagickWriteImages(magick_wand,argv[2],MagickTrue);
    -  if (status == MagickFalse)
    -    ThrowWandException(magick_wand);
    -  magick_wand=DestroyMagickWand(magick_wand);
    -  MagickWandTerminus();
    -  return(0);
    -}
    -
    - -

    Here is another program that shows one way to get and set image pixels with the MagickWand API, contrast.c. It reads an image, applies sigmoidal non-linearity contrast control, and writes the result to disk.

    - -
    #include <stdio.h>
    -#include <stdlib.h>
    -#include <math.h>
    -#include <wand/MagickWand.h>
    -
    -int main(int argc,char **argv)
    -{
    -#define QuantumScale  ((MagickRealType) 1.0/(MagickRealType) QuantumRange)
    -#define SigmoidalContrast(x) \
    -  (QuantumRange*(1.0/(1+exp(10.0*(0.5-QuantumScale*x)))-0.0066928509)*1.0092503)
    -#define ThrowWandException(wand) \
    -{ \
    -  char \
    -    *description; \
    - \
    -  ExceptionType \
    -    severity; \
    - \
    -  description=MagickGetException(wand,&severity); \
    -  (void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
    -  description=(char *) MagickRelinquishMemory(description); \
    -  exit(-1); \
    -}
    -
    -  long
    -    y;
    -
    -  MagickBooleanType
    -    status;
    -
    -  MagickPixelPacket
    -    pixel;
    -
    -  MagickWand
    -    *contrast_wand,
    -    *image_wand;
    -
    -  PixelIterator
    -    *contrast_iterator,
    -    *iterator;
    -
    -  PixelWand
    -    **contrast_pixels,
    -    **pixels;
    -
    -  register long
    -    x;
    -
    -  unsigned long
    -    width;
    -
    -  if (argc != 3)
    -    {
    -      (void) fprintf(stdout,"Usage: %s image sigmoidal-image\n",argv[0]);
    -      exit(0);
    -    }
    -  /*
    -    Read an image.
    -  */
    -  MagickWandGenesis();
    -  image_wand=NewMagickWand();
    -  status=MagickReadImage(image_wand,argv[1]);
    -  if (status == MagickFalse)
    -    ThrowWandException(image_wand);
    -  contrast_wand=CloneMagickWand(image_wand);
    -  /*
    -    Sigmoidal non-linearity contrast control.
    -  */
    -  iterator=NewPixelIterator(image_wand);
    -  contrast_iterator=NewPixelIterator(contrast_wand);
    -  if ((iterator == (PixelIterator *) NULL) ||
    -      (contrast_iterator == (PixelIterator *) NULL))
    -    ThrowWandException(image_wand);
    -  for (y=0; y < (long) MagickGetImageHeight(image_wand); y++)
    -  {
    -    pixels=PixelGetNextIteratorRow(iterator,&width);
    -    contrast_pixels=PixelGetNextIteratorRow(contrast_iterator,&width);
    -    if ((pixels == (PixelWand **) NULL) ||
    -        (contrast_pixels == (PixelWand **) NULL))
    -      break;
    -    for (x=0; x < (long) width; x++)
    -    {
    -      PixelGetMagickColor(pixels[x],&pixel);
    -      pixel.red=SigmoidalContrast(pixel.red);
    -      pixel.green=SigmoidalContrast(pixel.green);
    -      pixel.blue=SigmoidalContrast(pixel.blue);
    -      pixel.index=SigmoidalContrast(pixel.index);
    -      PixelSetMagickColor(contrast_pixels[x],&pixel);
    -    }
    -    (void) PixelSyncIterator(contrast_iterator);
    -  }
    -  if (y < (long) MagickGetImageHeight(image_wand))
    -    ThrowWandException(image_wand);
    -  contrast_iterator=DestroyPixelIterator(contrast_iterator);
    -  iterator=DestroyPixelIterator(iterator);
    -  image_wand=DestroyMagickWand(image_wand);
    -  /*
    -    Write the image then destroy it.
    -  */
    -  status=MagickWriteImages(contrast_wand,argv[2],MagickTrue);
    -  if (status == MagickFalse)
    -    ThrowWandException(image_wand);
    -  contrast_wand=DestroyMagickWand(contrast_wand);
    -  MagickWandTerminus();
    -  return(0);
    -}
    -
    -

    Now lets perform the same contrast enhancement while taking advantage of our dual or quad-core processing system by running the algorithm in parallel utilizing wand views. The sigmoidal-contrast.c module reads an image, applies sigmoidal non-linearity contrast control, and writes the result to disk just like the previous contrast enhancement program, but now it does its work in parallel (assumes ImageMagick is built with OpenMP support).

    - -
    #include <stdio.h>
    -#include <stdlib.h>
    -#include <math.h>
    -#include <wand/MagickWand.h>
    -
    -static MagickBooleanType SigmoidalContrast(WandView *pixel_view,
    -  const ssize_t y,const int id,void *context)
    -{
    -#define QuantumScale  ((MagickRealType) 1.0/(MagickRealType) QuantumRange)
    -#define SigmoidalContrast(x) \
    -  (QuantumRange*(1.0/(1+exp(10.0*(0.5-QuantumScale*x)))-0.0066928509)*1.0092503)
    -
    -  RectangleInfo
    -    extent;
    -
    -  MagickPixelPacket
    -    pixel;
    -
    -  PixelWand
    -    **pixels;
    -
    -  register long
    -    x;
    -
    -  extent=GetWandViewExtent(contrast_view);
    -  pixels=GetWandViewPixels(contrast_view);
    -  for (x=0; x < (long) (extent.width-extent.height); x++)
    -  {
    -    PixelGetMagickColor(pixels[x],&pixel);
    -    pixel.red=SigmoidalContrast(pixel.red);
    -    pixel.green=SigmoidalContrast(pixel.green);
    -    pixel.blue=SigmoidalContrast(pixel.blue);
    -    pixel.index=SigmoidalContrast(pixel.index);
    -    PixelSetMagickColor(contrast_pixels[x],&pixel);
    -  }
    -  return(MagickTrue);
    -}
    -
    -int main(int argc,char **argv)
    -{
    -#define ThrowViewException(view) \
    -{ \
    -  description=GetWandViewException(view,&severity); \
    -  (void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
    -  description=(char *) MagickRelinquishMemory(description); \
    -  exit(-1); \
    -}
    -#define ThrowWandException(wand) \
    -{ \
    -  description=MagickGetException(wand,&severity); \
    -  (void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
    -  description=(char *) MagickRelinquishMemory(description); \
    -  exit(-1); \
    -}
    -
    -  char
    -    *description;
    -
    -  ExceptionType
    -    severity;
    -
    -  MagickBooleanType
    -    status;
    -
    -  MagickPixelPacket
    -    pixel;
    -
    -  MagickWand
    -    *contrast_wand;
    -
    -  WandView
    -    *contrast_view;
    -
    -  if (argc != 3)
    -    {
    -      (void) fprintf(stdout,"Usage: %s image sigmoidal-image\n",argv[0]);
    -      exit(0);
    -    }
    -  /*
    -    Read an image.
    -  */
    -  MagickWandGenesis();
    -  contrast_wand=NewMagickWand();
    -  status=MagickReadImage(contrast_wand,argv[1]);
    -  if (status == MagickFalse)
    -    ThrowWandException(contrast_wand);
    -  /*
    -    Sigmoidal non-linearity contrast control.
    -  */
    -  contrast_view=NewWandView(contrast_wand);
    -  if (contrast_view == (WandView *) NULL)
    -    ThrowWandException(contrast_wand);
    -  status=UpdateWandViewIterator(contrast_view,SigmoidalContrast,(void *) NULL);
    -  if (status == MagickFalse)
    -    ThrowWandException(contrast_wand);
    -  contrast_view=DestroyWandView(contrast_view);
    -  /*
    -    Write the image then destroy it.
    -  */
    -  status=MagickWriteImages(contrast_wand,argv[2],MagickTrue);
    -  if (status == MagickFalse)
    -    ThrowWandException(contrast_wand);
    -  contrast_wand=DestroyMagickWand(contrast_wand);
    -  MagickWandTerminus();
    -  return(0);
    -}
    -
    -

    MagickWand Examples in C illustrates how to use the ImageMagick MagickWand API. Each example is presented as a C function, complete with headers, so that it can be copied to a file and then included in your own C project.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/miff.html b/ImageMagick-7.0.0-0/www/miff.html deleted file mode 100644 index efa4c5909..000000000 --- a/ImageMagick-7.0.0-0/www/miff.html +++ /dev/null @@ -1,241 +0,0 @@ - - - - - - - - - ImageMagick: Magick Image File Format - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    MIFF Header • MIFF Binary Data

    - -

    The Magick Image File Format (MIFF) is ImageMagick's own platform-independent format for storing bitmap images. It has an advantage over other image formats in that it stores all metadata known to ImageMagick (e.g. image color profiles, comments, author, copyright, etc.), whereas, other formats may only support a small portion of available metadata or none at all. A MIFF image file consist of two sections. The first section is a header composed of keys describing the image in text form. The next section is the binary image data. We discuss these sections in detail below.

    - -

    MIFF Header

    - - -

    The MIFF header is composed entirely of ISO-8859-1 characters. The fields in the header are key and value combination in the key = value format, with each key and value separated by an equal sign (=). Each key = value combination is delimited by at least one control or whitespace character. Comments may appear in the header section and are always delimited by braces. The MIFF header always ends with a colon (:) character, followed by a ctrl-Z character. It is also common to proceed the colon with a formfeed and a newline character. The formfeed prevents the listing of binary data when using the more Unix program, whereas, the ctrl-Z has the same effect with the type command on the Windows command line.

    - -

    The following is a partial list of key = value combinations that are typically be found in a MIFF file:

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    background-color = color
    border-color = color
    matte-color = colorthese optional keys reflect the image background, border, and matte colors respectively. A color can be a name (e.g. white) or a hex value (e.g. #ccc).
    class = { DirectClass, PseudoClass }the type of binary pixel data stored in the MIFF file. If this key is not present, DirectClass pixel data is assumed.
    colors = valuethe number of colors in a DirectClass image. For a PseudoClass image, this key specifies the number of entries in the colormap. If this key is not present in the header, and the image is PseudoClass, a linear 256 color grayscale colormap is assumed. The maximum number of colormap entries is 65536.
    colorspace = { RGB, CMYK, ... }the colorspace of the pixel data. The default is RGB.
    columns = valuethe width of the image in pixels. This a required key and has no default value.
    compression = {BZip, None, Zip, ... }the type of algorithm used to compress the image data. If this key is not present, the pixel data is assumed to be uncompressed.
    delay = microsecondsthe interframe delay in an image sequence in microseconds.
    depth = { 8, 16, 32 }the depth of a single color value representing values from 0 to 255 (depth 8), 0 - 65535 (depth 16), or 0 - 4294967295 (depth 32). If this key is absent, a depth of 8 is assumed.
    dispose = valuelayer disposal method. Here are the valid values: -
      -
      0. No disposal specified.
      -
      1. Do not dispose between frames.
      -
      2. Overwrite frame with background color from header.
      -
      3. Overwrite with previous frame.
      -
    -
    gamma = valuethe gamma of the image. If it is not specified, a gamma of 1.0 (linear brightness response) is assumed.
    id = ImageMagickidentifies the file as a MIFF-format image file. This key is required and has no default. Although this key can appear anywhere in the header, it should start as the first key of the header in column 1. This will allow programs like file(1) to easily identify the file as MIFF.
    iterations = valuethe number of times an image sequence loops before stopping.
    label = { string ]defines a short title or caption for the image. If any whitespace appears in the label, it must be enclosed within braces.
    matte = { True, False }specifies whether a the image has matte data. Matte data is generally useful for image compositing.
    montage = <width>x<height>[+-]<x offset>[+-]<y offset>size and location of the individual tiles of a composite image. - Use this key when the image is a composite of a number of different tiles. A tile consists of an image and optionally a border and a label. Width is the size in pixels of each individual tile in the horizontal direction and height is the size in the vertical direction. Each tile must have an equal number of pixels in width and equal in height. However, the width can differ from the height. X offset is the offset in number of pixels from the vertical edge of the composite image where the first tile of a row begins and y offset is the offset from the horizontal edge where the first tile of a column begins. If this key is specified, a directory of tile names must follow the image header. The format of the directory is explained below.
    page = valuepreferred size and location of an image canvas.
    profile-icc = valuethe number of bytes in the International Color Consortium color profile. The profile is defined by the ICC profile specification located at http://www.color.org/icc_specs2.html.
    red-primary = x,y
    green-primary = x,y
    blue-primary = x,y
    white-point = x,ythis optional key reflects the chromaticity primaries and white point.
    rendering-intent = { saturation, perceptual, absolute, relative }Rendering intent is the CSS-1 property that has been defined by the International Color Consortium (http://www.color.org).
    resolution = <x-resolution>x<y-resolution>vertical and horizontal resolution of the image. See units for the specific resolution units (e.g. pixels per inch).
    rows = valuethe height of the image in pixels. This a required key and has no default value.
    scene = valuethe sequence number for this MIFF image file. This optional key is useful when a MIFF image file is one in a sequence of files used in an animation.
    signature = valuethis optional key contains a string that uniquely identifies the image pixel contents. NIST's SHA-256 message digest algorithm is recommended.
    units = { pixels-per-inch, pixels-per-centimeter }image resolution units.
    - -

    Other key value pairs are permitted. If a value contains whitespace it must be enclosed with braces as illustrated here:

    - -
    -id=ImageMagick
    -class=PseudoClass  colors=256  matte=False
    -columns=1280  rows=1024  depth=8
    -compression=RLE
    -colorspace=RGB
    -copyright={Copyright (c) 1999-2016 ImageMagick Studio LLC}
    -⋮
    -
    - -

    Note that key = value combinations may be separated by newlines or spaces and may occur in any order within the header. Comments (within braces) may appear anywhere before the colon.

    - -

    If you specify the montage key in the header, follow the header with a directory of image tiles. This directory consists of a name for each tile of the composite image separated by a newline character. The list is terminated with a NULL character.

    - -

    If you specify the color-profile key in the header, follow the header (or montage directory if the montage key is in the header) with the binary color profile.

    - -

    The header is separated from the image data by a : character immediately followed by a newline.

    - -

    MIFF Binary Data

    - -

    Next comes the binary image data itself. How the image data is formatted depends upon the class of the image as specified (or not specified) by the value of the class key in the header.

    - -

    DirectClass images are continuous-tone, images stored as RGB (red, green, blue), RGBA (red, green, blue, alpha), CMYK (cyan, yellow, magenta, black), or CMYKA (cyan, yellow, magenta, black, alpha) intensity values as defined by the colorspace key. Each intensity value is one byte in length for images of depth 8 (0..255), two bytes for a depth of 16 (0..65535), and images of depth 32 (0..4294967295) require four bytes in most significant byte first order.

    - -

    PseudoClass images are colormapped RGB images. The colormap is stored as a series of red, green, and blue pixel values, each value being a byte in size. If the image depth is 16, each colormap entry consumes two bytes with the most significant byte being first. The number of colormap entries is defined by the colors key. The colormap data occurs immediately following the header (or image directory if the montage key is in the header). PseudoClass image data is an array of index values into the color map. If there are 256 -or fewer colors in the image, each byte of image data contains an index value. If the image contains more than 256 colors or the image depth is 16, the index value is stored as two contiguous bytes with the most significant byte being first. If matte is true, each colormap index is followed by a 1 or 2-byte alpha value.

    - -

    The image pixel data in a MIFF file may be uncompressed, runlength encoded, Zip compressed, or BZip compressed. The compression key in the header defines how the image data is compressed. Uncompressed pixels are stored one scanline at a time in row order. Runlength-encoded compression counts runs of identical adjacent pixels and stores the pixels followed by a length byte (the number of identical pixels minus 1). Zip and BZip compression compresses each row of an image and precedes the compressed row with the length of compressed pixel bytes as a word in most significant byte first order.

    - -

    MIFF files may contain more than one image. Simply concatenate each individual image (composed of a header and image data) into one file.

    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/mogrify.html b/ImageMagick-7.0.0-0/www/mogrify.html deleted file mode 100644 index ae2773d64..000000000 --- a/ImageMagick-7.0.0-0/www/mogrify.html +++ /dev/null @@ -1,1283 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Mogrify - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    Use the mogrify program to resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more. This tool is similar to convert except that the original image file is overwritten (unless you change the file suffix with the -format option) with any changes you request. See Command Line Processing for advice on how to structure your mogrify command or see below for sample usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the mogrify command here to illustrate its usefulness and ease of use. To get started, let's reduce the size of our -rose:

    - -
    -mogrify -resize 50% rose.jpg
    -
    - - - -

    You can resize all your JPEG images in a folder to a maximum dimension of 256x256 with this command:

    - -
    -mogrify -resize 256x256 *.jpg
    -
    - -

    Finally, we convert all our PNG images in a folder to the JPEG format:

    - -
    -mogrify -format jpg *.png
    -
    - -

    Here image files 1.png, 2.png, etc., are left untouched and files 1.jpg, 2.jpg, etc., are created. They are copies of their respective PNG images except are stored in the JPEG image format.

    - - -

    You can find additional examples of using mogrify in Graphics from the Command Line. Further discussion is available in More Graphics from the Command Line and Examples of ImageMagick Usage.

    - -

    Option Summary

    - -

    The mogrify command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -adaptive-blur geometryadaptively blur pixels; decrease effect near edges
    -adaptive-resize geometryadaptively resize image with data dependent triangulation.
    -adaptive-sharpen geometryadaptively sharpen pixels; increase effect near edges
    -adjoinjoin images into a single multi-image file
    -affine matrixaffine transform matrix
    -alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
    -annotate geometry textannotate the image with text
    -antialiasremove pixel-aliasing
    -appendappend an image sequence
    -authenticate valuedecipher image with this password
    -auto-gammaautomagically adjust gamma level of image
    -auto-levelautomagically adjust color levels of image
    -auto-orientautomagically orient image
    -background colorbackground color
    -bench iterationsmeasure performance
    -bias valueadd bias when convolving an image
    -black-threshold valueforce all pixels below the threshold into black
    -blue-primary pointchromaticity blue primary point
    -blue-shift factorsimulate a scene at nighttime in the moonlight
    -blur geometryreduce image noise and reduce detail levels
    -border geometrysurround image with a border of color
    -bordercolor colorborder color
    -brightness-contrast geometryimprove brightness / contrast of the image
    -canny geometryuse a multi-stage algorithm to detect a wide range of edges in the image
    -caption stringassign a caption to an image
    -cdl filenamecolor correct with a color decision list
    -channel typeapply option to select image channels
    -charcoal radiussimulate a charcoal drawing
    -chop geometryremove pixels from the image interior
    -clipclip along the first path from the 8BIM profile
    -clampset each pixel whose value is below zero to zero and any the pixel whose value is above the quantum range to the quantum range (e.g. 65535) otherwise the pixel value remains unchanged.
    -clip-mask filenameassociate clip mask with the image
    -clip-path idclip along a named path from the 8BIM profile
    -clutapply a color lookup table to the image
    -complexoperatorperform complex mathematics on an image sequence
    -connected-components connectivityconnected-components uniquely labeled, choose from 4 or 8 way connectivity
    -contrast-stretch geometryimprove the contrast in an image by `stretching' the range of intensity value
    -coalescemerge a sequence of images
    -colorize valuecolorize the image with the fill color
    -color-matrix matrixapply color correction to the image.
    -colors valuepreferred number of colors in the image
    -colorspace typeset image colorspace
    -combinecombine a sequence of images
    -comment stringannotate image with comment
    -compose operatorset image composite operator
    -compositecomposite image
    -compress typeimage compression type
    -contrastenhance or reduce the image contrast
    -convolve coefficientsapply a convolution kernel to the image
    -copy geometry offsetcopy pixels from one area of an image to another
    -crop geometrycrop the image
    -cycle amountcycle the image colormap
    -decipher filenameconvert cipher pixels to plain
    -debug eventsdisplay copious debugging information
    -define format:optiondefine one or more image format options
    -deconstructbreak down an image sequence into constituent parts
    -delay valuedisplay the next image after pausing
    -delete indexdelete the image from the image sequence
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -despecklereduce the speckles within an image
    -direction typerender text right-to-left or left-to-right
    -display serverget image or font from this X server
    -dispose methodlayer disposal method
    -distort type coefficientsdistort image
    -distribute-cache portlaunch a pixel cache server
    -dither methodapply error diffusion to image
    -draw stringannotate the image with a graphic primitive
    -duplicate count,indexesduplicate an image one or more times
    -edge radiusapply a filter to detect edges in the image
    -emboss radiusemboss an image
    -encipher filenameconvert plain pixels to cipher pixels
    -encoding typetext encoding type
    -endian typeendianness (MSB or LSB) of the image
    -enhanceapply a digital filter to enhance a noisy image
    -equalizeperform histogram equalization to an image
    -evaluate operator valueevaluate an arithmetic, relational, or logical expression
    -evaluate-sequence operatorevaluate an arithmetic, relational, or logical expression for an image sequence
    -extent geometryset the image size
    -extract geometryextract area from image
    -family namerender text with this font family
    -features distanceanalyze image features (e.g. contract, correlations, etc.).
    -fftimplements the discrete Fourier transform (DFT)
    -fill colorcolor to use when filling a graphic primitive
    -filter typeuse this filter when resizing an image
    -flattenflatten a sequence of images
    -flipflip image in the vertical direction
    -floodfill geometry colorfloodfill the image with color
    -flopflop image in the horizontal direction
    -font namerender text with this font
    -format typeoutput formatted image characteristics
    -frame geometrysurround image with an ornamental border
    -function nameapply a function to the image
    -fuzz distancecolors within this distance are considered equal
    -fx expressionapply mathematical expression to an image channel(s)
    -gamma valuelevel of gamma correction
    -gaussian-blur geometryreduce image noise and reduce detail levels
    -geometry geometrypreferred size or location of the image
    -gravity typehorizontal and vertical text placement
    -grayscale methodconvert image to grayscale
    -green-primary pointchromaticity green primary point
    -helpprint program options
    -hough-lines geometryidentify lines in the image
    -identifyidentify the format and characteristics of the image
    -ifftimplements the inverse discrete Fourier transform (DFT)
    -implode amountimplode image pixels about the center
    -insert indexinsert last image into the image sequence
    -intensity methodmethod to generate an intensity value from a pixel
    -intent typetype of rendering intent when managing the image color
    -interlace typetype of image interlacing scheme
    -interline-spacing valuethe space between two text lines
    -interpolate methodpixel color interpolation method
    -interword-spacing valuethe space between two words
    -kerning valuethe space between two characters
    -kuwahara geometryedge preserving noise reduction filter
    -label stringassign a label to an image
    -lat geometrylocal adaptive thresholding
    -layers methodoptimize or compare image layers
    -level valueadjust the level of image contrast
    -limit type valuepixel cache resource limit
    -linear-stretch geometrylinear with saturation histogram stretch
    -liquid-rescale geometryrescale image with seam-carving
    -log formatformat of debugging information
    -loop iterationsadd Netscape loop extension to your GIF animation
    -mask filenameassociate a mask with the image
    -mattecolor colorframe color
    -median radiusapply a median filter to the image
    -mean-shift geometrydelineate arbitrarily shaped clusters in the image
    -metric typemeasure differences between images with this metric
    -mode radiusmake each pixel the 'predominant color' of the neighborhood
    -modulate valuevary the brightness, saturation, and hue
    -monitormonitor progress
    -monochrometransform image to black and white
    -morph valuemorph an image sequence
    -morphology method kernelapply a morphology method to the image
    -motion-blur geometrysimulate motion blur
    -negatereplace each pixel with its complementary color
    -noise radiusadd or reduce noise in an image
    -normalizetransform image to span the full range of colors
    -opaque colorchange this color to the fill color
    -ordered-dither NxNordered dither the image
    -orient typeimage orientation
    -page geometrysize and location of an image canvas (setting)
    -paint radiussimulate an oil painting
    -perceptibleset each pixel whose value is less than |epsilon| to -epsilon or epsilon (whichever is closer) otherwise the pixel value remains unchanged.
    -pingefficiently determine image attributes
    -pointsize valuefont point size
    -polaroid anglesimulate a Polaroid picture
    -poly termsbuild a polynomial from the image sequence and the corresponding terms (coefficients and degree pairs).
    -posterize levelsreduce the image to a limited number of color levels
    -precision valueset the maximum number of significant digits to be printed
    -preview typeimage preview type
    -print stringinterpret string and print to console
    -process image-filterprocess the image with a custom image filter
    -profile filenameadd, delete, or apply an image profile
    -quality valueJPEG/MIFF/PNG compression level
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -radial-blur angleradial blur the image
    -raise valuelighten/darken image edges to create a 3-D effect
    -random-threshold low,highrandom threshold the image
    -red-primary pointchromaticity red primary point
    -regard-warningspay attention to warning messages.
    -region geometryapply options to a portion of the image
    -remap filenametransform image colors to match this set of colors
    -renderrender vector graphics
    -repage geometrysize and location of an image canvas
    -resample geometrychange the resolution of an image
    -resize geometryresize the image
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -roll geometryroll an image vertically or horizontally
    -rotate degreesapply Paeth rotation to the image
    -sample geometryscale image with pixel sampling
    -sampling-factor geometryhorizontal and vertical sampling factor
    -scale geometryscale the image
    -scene valueimage scene number
    -seed valueseed a new sequence of pseudo-random numbers
    -segment valuessegment an image
    -selective-blur geometryselectively blur pixels within a contrast threshold
    -separateseparate an image channel into a grayscale image
    -sepia-tone thresholdsimulate a sepia-toned photo
    -set attribute valueset an image attribute
    -shade degreesshade the image using a distant light source
    -shadow geometrysimulate an image shadow
    -sharpen geometrysharpen the image
    -shave geometryshave pixels from the image edges
    -shear geometryslide one edge of the image along the X or Y axis
    -sigmoidal-contrast geometryincrease the contrast without saturating highlights or shadows
    -size geometrywidth and height of image
    -sketch geometrysimulate a pencil sketch
    -smush offsetsmush an image sequence together
    -solarize thresholdnegate all pixels above the threshold level
    -splice geometrysplice the background color into the image
    -spread radiusdisplace image pixels by a random amount
    -statistic type geometryreplace each pixel with corresponding statistic from the neighborhood
    -stripstrip image of all profiles and comments
    -stroke colorgraphic primitive stroke color
    -strokewidth valuegraphic primitive stroke width
    -stretch typerender text with this font stretch
    -style typerender text with this font style
    -swap indexesswap two images in the image sequence
    -swirl degreesswirl image pixels about the center
    -synchronizesynchronize image to storage device
    -texture filenamename of texture to tile onto the image background
    -threshold valuethreshold the image
    -thumbnail geometrycreate a thumbnail of the image
    -tile filenametile image when filling a graphic primitive
    -tile-offset geometryset the image tile offset
    -tint valuetint the image with the fill color
    -transformaffine transform image
    -transparent colormake this color transparent within the image
    -transparent-color colortransparent color
    -transposeflip image in the vertical direction and rotate 90 degrees
    -transverseflop image in the horizontal direction and rotate 270 degrees
    -treedepth valuecolor tree depth
    -trimtrim image edges
    -type typeimage type
    -undercolor colorannotation bounding box color
    -unique-colorsdiscard all but one of any pixel color.
    -units typethe units of image resolution
    -unsharp geometrysharpen the image
    -verboseprint detailed information about the image
    -versionprint version information
    -viewFlashPix viewing transforms
    -vignette geometrysoften the edges of the image in vignette style
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    -wave geometryalter an image along a sine wave
    -weight typerender text with this font weight
    -white-point pointchromaticity white point
    -white-threshold valueforce all pixels above the threshold into white
    -write filenamewrite images to this file
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/montage.html b/ImageMagick-7.0.0-0/www/montage.html deleted file mode 100644 index 52ba6f5b9..000000000 --- a/ImageMagick-7.0.0-0/www/montage.html +++ /dev/null @@ -1,634 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Montage - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    Use the montage program to create a composite image by combining several separate images. The images are tiled on the composite image optionally adorned with a border, frame, image name, and more. See Command Line Processing for advice on how to structure your montage command or see below for example usages of the command.

    - -

    Example Usage

    - -

    We list a few examples of the montage command here to illustrate its usefulness and ease of use. To get started, let's montage two images into a single composite:

    - -
    -montage -background '#336699' -geometry +4+4 rose.jpg red-ball.png montage.jpg
    -
    - - - -

    Ok, let's add some decorations:

    - -
    -montage -label %f -frame 5 -background '#336699' -geometry +4+4 rose.jpg red-ball.png frame.jpg
    -
    - - - -

    You can find additional examples of using montage at Examples of ImageMagick Usage and Graphics from the Command Line. Further discussion is available in More Graphics from the Command Line and Examples of ImageMagick Usage.

    - -

    Option Summary

    - -

    The montage command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -adaptive-sharpen geometryadaptively sharpen pixels; increase effect near edges
    -adjoinjoin images into a single multi-image file
    -affine matrixaffine transform matrix
    -alphaon, activate, off, deactivate, set, opaque, copy", -transparent, extract, background, or shape the alpha channel
    -annotate geometry textannotate the image with text
    -authenticate valuedecrypt image with this password
    -auto-orientautomagically orient image
    -background colorbackground color
    -blue-primary pointchromaticity blue primary point
    -blur geometryreduce image noise and reduce detail levels
    -border geometrysurround image with a border of color
    -bordercolor colorborder color
    -caption stringassign a caption to an image
    -channel typeapply option to select image channels
    -clone indexclone an image
    -coalescemerge a sequence of images
    -colors valuepreferred number of colors in the image
    -colorspace typeset image colorspace
    -comment stringannotate image with comment
    -compose operatorset image composite operator
    -compositecomposite image
    -compress typeimage compression type
    -crop geometrypreferred size and location of the cropped image
    -debug eventsdisplay copious debugging information
    -define format:optiondefine one or more image format options
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -display serverget image or font from this X server
    -dispose methodlayer disposal method
    -dither methodapply error diffusion to image
    -draw stringannotate the image with a graphic primitive
    -duplicate count,indexesduplicate an image one or more times
    -endian typeendianness (MSB or LSB) of the image
    -extent geometryset the image size
    -extract geometryextract area from image
    -fill colorcolor to use when filling a graphic primitive
    -filter typeuse this filter when resizing an image
    -flattenflatten a sequence of images
    -flipflip image in the vertical direction
    -flopflop image in the horizontal direction
    -font namerender text with this font
    -frame geometrysurround image with an ornamental border
    -gamma valuelevel of gamma correction
    -geometry geometrypreferred size or location of the image
    -gravity typehorizontal and vertical text placement
    -green-primary pointchromaticity green primary point
    -helpprint program options
    -identifyidentify the format and characteristics of the image
    -interlace typetype of image interlacing scheme
    -interpolate methodpixel color interpolation method
    -kerning valuethe space between two characters
    -label stringassign a label to an image
    -limit type valuepixel cache resource limit
    -log formatformat of debugging information
    -mattecolor colorframe color
    -mode typeframing style
    -monitormonitor progress
    -monochrometransform image to black and white
    -origin geometryimage origin
    -page geometrysize and location of an image canvas (setting)
    -pointsize valuefont point size
    -polaroid anglesimulate a Polaroid picture
    -profile filenameadd, delete, or apply an image profile
    -quality valueJPEG/MIFF/PNG compression level
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -red-primary pointchromaticity red primary point
    -regard-warningspay attention to warning messages.
    -repage geometrysize and location of an image canvas
    -resize geometryresize the image
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -rotate degreesapply Paeth rotation to the image
    -sampling-factor geometryhorizontal and vertical sampling factor
    -scale geometryscale the image
    -scenesrangeimage scene range
    -seed valueseed a new sequence of pseudo-random numbers
    -shadow geometrysimulate an image shadow
    -size geometrywidth and height of image
    -stripstrip image of all profiles and comments
    -stroke colorgraphic primitive stroke color
    -synchronizesynchronize image to storage device
    -taintmark the image as modified
    -texture filenamename of texture to tile onto the image background
    -tile filenametile image when filling a graphic primitive
    -tile-offset geometryset the image tile offset
    -titledecorate the montage image with a title
    -transformaffine transform image
    -transparent colormake this color transparent within the image
    -transposeflip image in the vertical direction and rotate 90 degrees
    -transparent-color colortransparent color
    -treedepth valuecolor tree depth
    -trimtrim image edges
    -type typeimage type
    -units typethe units of image resolution
    -unsharp geometrysharpen the image
    -verboseprint detailed information about the image
    -versionprint version information
    -viewFlashPix viewing transforms
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    -white-point pointchromaticity white point
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/motion-picture.html b/ImageMagick-7.0.0-0/www/motion-picture.html deleted file mode 100644 index 51a35633d..000000000 --- a/ImageMagick-7.0.0-0/www/motion-picture.html +++ /dev/null @@ -1,190 +0,0 @@ - - - - - - - - - ImageMagick: Motion Picture Digital Images - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Log Format • DPX properties • DPX Settings

    - -

    DPX (SMPTE 268M-2003) - This format is used in Motion Picture and Effects industry that makes particular use of the extensive header information and the format's flexibility in being able to handle high dynamic range and logarithmic color values at a variety of bit depths using RGB or YCbCr pixel descriptions. It is based on, but largely supersedes, Kodak's Cineon format that has more a more film specific header.

    - -

    One example of it's use includes scanning film for use in post production. Each frame is stored as an individual DPX file ranging from 2k (2048 pixels wide) to 8k (8192 pixels wide - for IMAX frames) at anything between 8 to 64 bits per color component. A sequence of these might then be processed using compositing software, altering the color or adding visual effects. Once complete they might then be recorded digitally to tape or projected back on to film.

    - -

    The color values for each pixel are often stored logarithmically (particularly if the sequence is destined to be transferred back on to film) which more naturally reflects the density of how color information is stored in the emulsion on the original film. When viewed without alteration, logarithmic files appear to have very low contrast and requires a 'look up table' to translate the logarithmic image to something that resembles what you might see if the image was transferred back to film and projected in a cinema. Apart from making the image linear (like most typical computer images) and adjusting the gamma level this table sets where the black and white point lies.

    - -

    For a 10 bit logarithmic image where each color component value ranges from 0 to 1023 the black and white points are normally set at 95 for black and 685 for white. What this means is that the logarithmic file stores color values that are lighter than what the linear version will display as pure white and darker than what it will display as pure black. This extra information therefore remains available for an effects artists who might wish to alter the brightness of the image after it has been stored as a DPX file.

    - -

    As an example, had this information been lost, reducing the brightness of an image uniformly would result in highlights becoming darker, whereas with this extra information the highlights instead reduce in size and start showing details that were previously too bright to be seen. The latter is far closer to what happens in the real world.

    - -

    The header can contain Film and/or Television specific data related to a production. For example the television header can contain a SMPTE time code so that shots exported as a DPX sequence from a production's edit can be easily replaced once any effects have been added. The film header holds information about the reel of film the frames originated from and various camera settings that were used while filming. All these details usually stay with the images as they are passed between post-production companies.

    - -

    Log Format

    - -

    The color values for each pixel are often stored logarithmically (particularly if the sequence is destined to be transferred back on to film) which more naturally reflects the density of how color information is stored in the emulsion on the original film. When viewed without alteration logarithmic files appear to have very low contrast (leftmost image), and so require a 'look up table' to translate the logarithmic image to something that resembles what you might see if the image was transferred back to film and projected in a cinema (rightmost image). Apart from making the image linear (like most typical computer images) and adjusting the gamma level this table sets where the black and white point lies.

    - -
      - bluebells-log - bluebells-linear -
    - -

    For a 10 bit logarithmic image where each color component value ranges from 0 to 1023 the black and white points are normally set at 95 for black and 685 for white. What this means is that the logarithmic file stores color values that are lighter than what the linear version will display as pure white and darker than what it will display as pure black. This extra information therefore remains available for an effects artists who might wish to alter the brightness of the image after it has been stored as a DPX file.

    - -

    As an example, had this information been lost, reducing the brightness of a linear image uniformly would result in highlights becoming darker (leftmost image), whereas with this extra information the highlights instead reduce in size and start showing details that were previously too bright to be seen (rightmost image). The latter is far closer to what happens in the real world.

    - -
      - bluebells-clipped - bluebells-darker -
    - -

    DPX Properties

    - -

    ImageMagick supports these DPX properties:

    - -
    dpx:file.copyright
    -dpx:file.creator
    -dpx:file.filename
    -dpx:file.project
    -dpx:file.version
    -dpx:film.count
    -dpx:film.format
    -dpx:film.frame_id
    -dpx:film.frame_position
    -dpx:film.frame_rate
    -dpx:film.held_count
    -dpx:film.id
    -dpx:film.offset
    -dpx:film.prefix
    -dpx:film.sequence_length
    -dpx:film.shutter_angle
    -dpx:film.slate
    -dpx:film.type
    -dpx:orientation.aspect_ratio
    -dpx:orientation.border
    -dpx:orientation.device
    -dpx:orientation.filename
    -dpx:orientation.serial
    -dpx:orientation.x_center
    -dpx:orientation.x_offset
    -dpx:orientation.x_size
    -dpx:orientation.y_center
    -dpx:orientation.y_offset
    -dpx:orientation.y_size
    -dpx:television.black_gain
    -dpx:television.black_level
    -dpx:television.break_point
    -dpx:television.field_number
    -dpx:television.frame_rate
    -dpx:television.gamma
    -dpx:television.integration_times
    -dpx:television.interlace
    -dpx:television.padding
    -dpx:television.time.code
    -dpx:television.time_offset
    -dpx:television.user.bits
    -dpx:television.vertical_sample_rate
    -dpx:television.video_signal
    -dpx:television.white_level
    -dpx:user.id
    -dpx:user.data
    -
    - -

    Look for any user data as the dpx:user-data image profile.

    - -

    To determine which properties are associated with your DPX image, use this command for example:

    - -
    -identify -verbose bluebells.dpx
    -
    - -

    To identify a particular property, try this:

    - -
    -identify -format "%[dpx:television.time.code]" bluebells.dpx
    -
    - -

    Finally, to set a property:

    - -
    -convert bluebells.dpx -define dpx:television.time.code=10:00:02:15 bluebells-001.dpx
    -
    - -

    DPX Settings

    - -

    Use -set to specify the image or film gamma or black and white points. For example use: -

    - -
    --set gamma 1.7
    --set film-gamma 0.6
    --set reference-black 95
    --set reference-white 685
    --set profile dpx:user.data
    -
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/opencl.html b/ImageMagick-7.0.0-0/www/opencl.html deleted file mode 100644 index c3b426ce2..000000000 --- a/ImageMagick-7.0.0-0/www/opencl.html +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - - - - ImageMagick: Parallel Execution with OpenCL - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    The following is a list of image operators that have been OpenCL-accelerated:

    -
    -blur
    -charcoal
    -contrast
    -constrast-stretch
    -convolve
    -despeckle
    -edge
    -equalize
    -emboss
    -function
    -gaussian-blur
    -grayscale
    -modulate
    -motion-blur
    -negate
    -noise
    -radial-blur
    -resize
    -sketch
    -unsharp
    -
    -

    When the OpenCL acceleration is invoked for the first time, ImageMagick conducts a series of tests to configure the OpenCL environment according to the system hardware; therefore, it is normal to experience a higher latency the first time you use an accelerated option. The OpenCL kernels are embedded inside ImageMagick in source format. During the initial setup, ImageMagick discovers all the available OpenCL devices and compiles the kernels for each of these targets. ImageMagick also runs several performance tests internally to determine the preferred device to use. The compiled kernel code and the performance test results are stored into the cache directory so that the data can be reused by subsequent invocations of the OpenCL path. By default, the OpenCL cached data is stored in $HOME/.cache/ImageMagick on Linux and on MacOSX or in %LOCALAPPDATA%\.cache\ImageMagick on Windows. To change the cache directory, set the IMAGEMAGICK_OPENCL_CACHE_DIR environment variable. ImageMagick is able to detect hardware changes, driver updates, and new kernel sources and re-run the setup and the calibration test. You can also force ImageMagick to re-run the process by removing the content from the cache directory.

    -

    If ImageMagick includes OpenCL support, the OpenCL path is enable by default. You can disable it, simply set the environment variable MAGICK_OCL_DEVICE to OFF. You could also force the OpenCL path to use a particular class of devices by setting it to GPU or CPU.

    -

    In addition to the environment variables just mentioned, ImageMagick provides a set of APIs that allow developers to gain a finer grain control of the OpenCL acceleration. For example, use the InitImageMagickOpenCL) function to turn off OpenCL:

    -
    -InitImageMagickOpenCL(MAGICK_OPENCL_OFF, NULL, NULL, exception); 
    -
    -

    Use InitImageMagickOpenCL() to find out which OpenCL device are automagically selected by ImageMagick:

    -
    -cl_device_id selectedDevice;  // OpenCL device used by ImageMagick
    -InitImageMagickOpenCL(MAGICK_OPENCL_DEVICE_SELECT_AUTO, NULL, (void*)&selectedDevice, exception);
    -
    - -

    Or you could request ImageMagick to use a specific OpenCL device:

    -
    -cl_device_id myDevices[4];
    -cl_uint numDevices;
    -// Get all the available OpenCL devices from the runtime
    -clGetDeviceIDs(myPlatform, CL_DEVICE_TYPE_ALL, 4, myDevices, &numDevices);
    -// ask ImageMagick to use the 3rd device
    -InitImageMagickOpenCL(MAGICK_OPENCL_DEVICE_SELECT_USER, (void*)(myDevices+2), NULL, exception);
    -
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/openmp.html b/ImageMagick-7.0.0-0/www/openmp.html deleted file mode 100644 index 11ce59aee..000000000 --- a/ImageMagick-7.0.0-0/www/openmp.html +++ /dev/null @@ -1,97 +0,0 @@ - - - - - - - - - ImageMagick: Parallel Execution with OpenMP - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    Many of ImageMagick's internal algorithms are threaded to take advantage of speed-ups offered by the multicore processor chips and OpenMP. OpenMP, is an API specification for parallel programming. If your compiler supports OpenMP (e.g. gcc, Visual Studio 2005) directives, ImageMagick automatically includes support. To verify, look for the OpenMP feature of ImageMagick with this command:

    -
    --> identify -version
    -Version: ImageMagick 6.9.1-2 2015-10-14 Q16 http://www.imagemagick.org
    -Copyright: Copyright (C) 1999-2016 ImageMagick Studio LLC
    -Features: OpenMP
    -
    -

    With OpenMP enabled, most ImageMagick algorithms execute on all the cores on your system in parallel. ImageMagick typically divides the work so that each thread processes four rows of pixels. As rows are completed, OpenMP assigns more chunks of pixel rows to each thread until the algorithm completes. For example, if you have a quad-core system, and attempt to resize an image, the resizing takes place on 4 cores (8 if hyperthreading is enabled).

    -

    The Perils of Parallel Execution

    -

    It can be difficult to predict behavior in a parallel environment. Performance might depend on a number of factors including the compiler, the version of the OpenMP library, the processor type, the number of cores, the amount of memory, whether hyperthreading is enabled, the mix of applications that are executing concurrently with ImageMagick, or the particular image-processing algorithm you utilize. The only way to be certain of the optimal performance, in terms of the number of threads, is to benchmark. ImageMagick includes progressive threading when benchmarking a command and returns the elapsed time and efficiency for one or more threads. This can help you identify how many threads are the most efficient in your environment. Here is an example benchmark for threads 1-8:

    - -
    --> convert -bench 40 model.png -sharpen 0x1 null:
    -Performance[1]: 40i 0.712ips 1.000e 14.000u 0:14.040
    -Performance[2]: 40i 1.362ips 0.657e 14.550u 0:07.340
    -Performance[3]: 40i 2.033ips 0.741e 14.530u 0:04.920
    -Performance[4]: 40i 2.667ips 0.789e 14.590u 0:03.750
    -Performance[5]: 40i 3.236ips 0.820e 14.970u 0:03.090
    -Performance[6]: 40i 3.802ips 0.842e 15.280u 0:02.630
    -Performance[7]: 40i 4.274ips 0.857e 15.540u 0:02.340
    -Performance[8]: 40i 4.831ips 0.872e 15.680u 0:02.070
    -
    -

    Better performance correlates with higher values of IPS (iterations-per-second). In our example, 8 cores are optimal. However, in certain cases it might be optimal to set the number of threads to 1 (e.g. -limit thread 1) or to disable OpenMP completely. To disable this feature, add --disable-openmp to your configure script command line then rebuild and re-install ImageMagick.

    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/perl-magick.html b/ImageMagick-7.0.0-0/www/perl-magick.html deleted file mode 100644 index e04b79b36..000000000 --- a/ImageMagick-7.0.0-0/www/perl-magick.html +++ /dev/null @@ -1,2571 +0,0 @@ - - - - - - - - - ImageMagick: PerlMagick, Perl API for ImageMagick - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Installation • Overview • Example Script • Read or Write an Image • Manipulate an Image • Set an Image Attribute • Get an Image Attribute • Compare an Image to its Reconstruction • Create an Image Montage • Working with Blobs • Direct-access to Image Pixels • Miscellaneous Methods • Handling Exceptions• Constant

    - - -

    PerlMagick is an objected-oriented Perl interface to ImageMagick. Use the module to read, manipulate, or write an image or image sequence from within a Perl script. This makes it very suitable for Web CGI scripts. You must have ImageMagick 6.5.5 or above and Perl version 5.005_02 or greater installed on your system for PerlMagick to build properly.

    - -

    There are a number of useful scripts available to show you the value of PerlMagick. You can do Web based image manipulation and conversion with MagickStudio, or use L-systems to create images of plants using mathematical constructs, and finally navigate through collections of thumbnail images and select the image to view with the WebMagick Image Navigator.

    - -

    You can try PerlMagick from your Web browser at the ImageMagick Studio. Or, you can see examples of select PerlMagick functions.

    - -

    Installation

    - -

    UNIX

    - -

    Is PerlMagick available from your system RPM repository? For example, on our CentOS system, we install PerlMagick thusly:

    - -
    -yum install ImageMagick-perl
    -
    - -

    If not, you must install PerlMagick from the ImageMagick source distribution. Download the latest source release.

    - -

    Unpack the distribution with this command:

    - -
    -tar xvzf ImageMagick.tar.gz
    -
    - -

    Next configure and compile ImageMagick:

    - -
     cd ImageMagick-7.0.0 ./configure -with-perl make
    -

    If ImageMagick / PerlMagick configured and compiled without complaint, you are ready to install it on your system. Administrator privileges are required to install. To install, type

    - -
    -sudo make install
    -
    - -

    You may need to configure the dynamic linker run-time bindings:

    - -
    -sudo ldconfig /usr/local/lib
    -
    - - -

    Finally, verify the PerlMagick install worked properly, type

    - -
    -perl -e \"use Image::Magick; print Image::Magick->QuantumDepth\"
    -
    - -

    Congratulations, you have a working ImageMagick distribution and you are ready to use PerlMagick to convert, compose, or edit your images.

    - -

    Windows XP / Windows 2000

    - -

    ImageMagick must already be installed on your system. Also, the ImageMagick source distribution for Windows 2000 is required. You must also have the nmake from the Visual C++ or J++ development environment. Copy \bin\IMagick.dll and \bin\X11.dll to a directory in your dynamic load path such as c:\perl\site\5.00502.

    - -

    Next, type

    - -
    -cd PerlMagick
    -perl Makefile.nt
    -nmake
    -nmake install
    -
    - -

    See the PerlMagick Windows HowTo page for further installation instructions.

    - -

    Running the Regression Tests

    - -

    To verify a correct installation, type

    - -
    -make test
    -
    - -

    Use nmake test under Windows. There are a few demonstration scripts available to exercise many of the functions PerlMagick can perform. Type

    - -
    -cd demo
    -make
    -
    - -

    You are now ready to utilize the PerlMagick methods from within your Perl scripts.

    - -

    Overview

    - -

    Any script that wants to use PerlMagick methods must first define the methods within its namespace and instantiate an image object. Do this with:

    - -
    -use Image::Magick;
    -
    -$image = Image::Magick->new;
    -
    - -

    PerlMagick is quantum aware. You can request a specific quantum depth when you instantiate an image object:

    - -
    -use Image::Magick::Q16;
    -
    -$image = Image::Magick::Q16->new;
    -
    - -

    The new() method takes the same parameters as SetAttribute . For example,

    - -
    -$image = Image::Magick->new(size=>'384x256');
    -
    - -

    Next you will want to read an image or image sequence, manipulate it, and then display or write it. The input and output methods for PerlMagick are defined in Read or Write an Image. See Set an Image Attribute for methods that affect the way an image is read or written. Refer to Manipulate an Image for a list of methods to transform an image. Get an Image Attribute describes how to retrieve an attribute for an image. Refer to Create an Image Montage for details about tiling your images as thumbnails on a background. Finally, some methods do not neatly fit into any of the categories just mentioned. Review Miscellaneous Methods for a list of these methods.

    - -

    Once you are finished with a PerlMagick object you should consider destroying it. Each image in an image sequence is stored in virtual memory. This can potentially add up to mebibytes of memory. Upon destroying a PerlMagick object, the memory is returned for use by other Perl methods. The recommended way to destroy an object is with undef:

    - -
    -undef $image;
    -
    - -

    To delete all the images but retain the Image::Magick object use

    - -
    -@$image = ();
    -
    - -

    and finally, to delete a single image from a multi-image sequence, use

    - -
    -undef $image->[$x];
    -
    - -

    The next section illustrates how to use various PerlMagick methods to manipulate an image sequence.

    - -

    Some of the PerlMagick methods require external programs such as Ghostscript. This may require an explicit path in your PATH environment variable to work properly. For example (in Unix),

    - -
    -$ENV{PATH}' . "='/../bin:/usr/bin:/usr/local/bin';
    -
    - -

    Example Script

    - -

    Here is an example script to get you started:

    - -
    -#!/usr/local/bin/perl
    -use Image::Magick;
    -my($image, $x);
    -$image = Image::Magick->new; -$x = $image->Read('girl.png', 'logo.png', 'rose.png'); -warn "$x" if "$x";
    -$x = $image->Crop(geometry=>'100x100+100+100'); -warn "$x" if "$x";
    -$x = $image->Write('x.png'); -warn "$x" if "$x"; -
    - -

    The script reads three images, crops them, and writes a single image as a GIF animation sequence. In many cases you may want to access individual images of a sequence. The next example illustrates how this done:

    - -
    #!/usr/local/bin/perl
    -use Image::Magick;
    -my($image, $p, $q);
    -$image = new Image::Magick; -$image->Read('x1.png'); -$image->Read('j*.jpg'); -$image->Read('k.miff[1, 5, 3]'); -$image->Contrast(); -for ($x = 0; $image->[$x]; $x++) -{ - $image->[$x]->Frame('100x200') if $image->[$x]->Get('magick') eq 'GIF'; - undef $image->[$x] if $image->[$x]->Get('columns') < 100; -} -$p = $image->[1]; -$p->Draw(stroke=>'red', primitive=>'rectangle', points=>20,20 100,100'); -$q = $p->Montage(); -undef $image; -$q->Write('x.miff'); -
    - -

    Suppose you want to start out with a 100 by 100 pixel white canvas with a red pixel in the center. Try

    - -
    -$image = Image::Magick->new;
    -$image->Set(size=>'100x100');
    -$image->ReadImage('canvas:white');
    -$image->Set('pixel[49,49]'=>'red');
    -
    - -

    Here we reduce the intensity of the red component at (1,1) by half:

    - -
    -@pixels = $image->GetPixel(x=>1,y=>1);
    -$pixels[0]*=0.5;
    -$image->SetPixel(x=>1,y=>1,color=>\@pixels);
    -
    - -

    Or suppose you want to convert your color image to grayscale:

    - -
    -$image->Quantize(colorspace=>'gray');
    -
    - -

    Let's annotate an image with a Taipai TrueType font:

    - -
    -$text = 'Works like magick!';
    -$image->Annotate(font=>'kai.ttf', pointsize=>40, fill=>'green', text=>$text);
    -
    - -

    Perhaps you want to extract all the pixel intensities from an image and write them to STDOUT:

    - -
    -@pixels = $image->GetPixels(map=>'I', height=>$height, width=>$width, normalize=>true);
    -binmode STDOUT;
    -print pack('B*',join('',@pixels));
    -
    - -

    Other clever things you can do with a PerlMagick objects include

    - -
    -$i = $#$p"+1";   # return the number of images associated with object p
    -push(@$q, @$p);  # push the images from object p onto object q
    -@$p = ();        # delete the images but not the object p
    -$p->Convolve([1, 2, 1, 2, 4, 2, 1, 2, 1]);   # 3x3 Gaussian kernel
    -
    - -

    Read or Write an Image

    - -

    Use the methods listed below to either read, write, or display an image or image sequence:

    - - - -- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Read or Write Methods
    MethodParametersReturn ValueDescription
    Readone or more filenamesthe number of images readread an image or image sequence
    Writefilenamethe number of images writtenwrite an image or image sequence
    Displayserver namethe number of images displayeddisplay the image or image sequence to an X server
    Animateserver namethe number of images animatedanimate image sequence to an X server
    - -

    For convenience, methods Write(), Display(), and Animate() can take any parameter that SetAttribute knows about. For example,

    - -
    -$image->Write(filename=>'image.png', compression=>'None');
    -
    - -

    Use - as the filename to method Read() to read from standard in or to method Write() to write to standard out:

    - -
    -binmode STDOUT;
    -$image->Write('png:-');
    -
    - -

    To read an image in the GIF format from a PERL filehandle, use:

    - -
    -$image = Image::Magick->new;
    -open(IMAGE, 'image.gif');
    -$image->Read(file=>\*IMAGE);
    -close(IMAGE);
    -
    - -

    To write an image in the PNG format to a PERL filehandle, use:

    - -
    -$filename = "image.png";
    -open(IMAGE, ">$filename");
    -$image->Write(file=>\*IMAGE, filename=>$filename);
    -close(IMAGE);
    -
    - -

    Note, reading from or writing to a Perl filehandle may fail under Windows due to different versions of the C-runtime libraries between ImageMagick and the ActiveState Perl distributions or if one of the DLL's is linked with the /MT option. See Potential Errors Passing CRT Objects Across DLL Boundaries for an explanation.

    - -

    If %0Nd, %0No, or %0Nx appears in the filename, it is interpreted as a printf format specification and the specification is replaced with the specified decimal, octal, or hexadecimal encoding of the scene number. For example,

    - -
    -image%03d.miff
    -
    - -

    converts files image000.miff, image001.miff, etc.

    - -

    You can optionally add Image to any method name. For example, ReadImage() is an alias for method Read().

    - -

    Manipulate an Image

    - -

    Once you create an image with, for example, method ReadImage() you may want to operate on it. Below is a list of all the image manipulations methods available to you with PerlMagick. There are examples of select PerlMagick methods. Here is an example call to an image manipulation method:

    - -
    -$image->Crop(geometry=>'100x100+10+20');
    -$image->[$x]->Frame("100x200");
    -
    - -

    And here is a list of other image manipulation methods you can call:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Image Manipulation Methods
    MethodParametersDescription
    AdaptiveBlurgeometry=>geometry, radius=>double, sigma=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}adaptively blur the image with a Gaussian operator of the given radius and standard deviation (sigma). Decrease the effect near edges.
    AdaptiveResizegeometry=>geometry, width=>integer, height=>integer, filter=>{Point, Box, Triangle, Hermite, Hanning, Hamming, Blackman, Gaussian, Quadratic, Cubic, Catrom, Mitchell, Lanczos, Bessel, Sinc}, support=>double, blur=>doubleadaptively resize image using data dependant triangulation. Specify blur > 1 for blurry or < 1 for sharp
    AdaptiveSharpengeometry=>geometry, radius=>double, sigma=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}adaptively sharpen the image with a Gaussian operator of the given radius and standard deviation (sigma). Increase the effect near edges.
    AdaptiveThresholdgeometry=>geometry, width=>integer, height=>integer, offset=>integerlocal adaptive thresholding.
    AddNoisenoise=>{Uniform, Gaussian, Multiplicative, Impulse, Laplacian, Poisson}, attenuate=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}add noise to an image
    AffineTransformaffine=>array of float values, translate=>float, float, scale=> float, float, rotate=>float, skewX=>float, skewY=>float, interpolate={Average, Bicubic, Bilinear, Filter, Integer, Mesh, NearestNeighbor}, background=>color nameaffine transform image
    Affinityimage=>image-handle, method=>{None, FloydSteinberg, Riemersma}choose a particular set of colors from this image
    Annotatetext=>string, font=>string, family=>string, style=>{Normal, Italic, Oblique, Any}, stretch=>{Normal, UltraCondensed, ExtraCondensed, Condensed, SemiCondensed, SemiExpanded, Expanded, ExtraExpanded, UltraExpanded}, weight=>integer, pointsize=>integer, density=>geometry, stroke=>color name, strokewidth=>integer, fill=>color name, undercolor=>color name, kerning=>float, geometry=>geometry, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}, antialias=>{true, false}, x=>integer, y=>integer, affine=>array of float values, translate=>float, float, scale=>float, float, rotate=>float. skewX=>float, skewY=> float, align=>{Left, Center, Right}, encoding=>{UTF-8}, interline-spacing=>double, interword-spacing=>double, direction=>{right-to-left, left-to-right}annotate an image with text. See QueryFontMetrics to get font metrics without rendering any text.
    AutoGammachannel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}automagically adjust gamma level of image
    AutoLevelchannel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}automagically adjust color levels of image
    AutoOrient
    adjusts an image so that its orientation is suitable for viewing (i.e. top-left orientation)
    BlackThresholdthreshold=>string, , channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}force all pixels below the threshold intensity into black
    BlueShiftfactor=>double,simulate a scene at nighttime in the moonlight. Start with a factor of 1.5.
    Blurgeometry=>geometry, radius=>double, sigma=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}reduce image noise and reduce detail levels with a Gaussian operator of the given radius and standard deviation (sigma).
    Bordergeometry=>geometry, width=>integer, height=>integer, bordercolor=>color name, compose=>{Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor },surround the image with a border of color
    CannyEdgegeometry=>geometry, radius=>double, sigma=>double, 'lower-percent'=>double, 'upper-percent'=>doubleuse a multi-stage algorithm to detect a wide range of edges in the image (e.g. CannyEdge('0x1+10%+40%')).
    Charcoalgeometry=>geometry, radius=>double, sigma=>doublesimulate a charcoal drawing
    Chopgeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integer, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}chop an image
    Clampchannel=>{Red, RGB, All, etc.}set each pixel whose value is below zero to zero and any the pixel whose value is above the quantum range to the quantum range (e.g. 65535) otherwise the pixel value remains unchanged.
    Clipid=>name, inside=>{true, false},apply along a named path from the 8BIM profile.
    ClipMaskmask=>image-handleclip image as defined by the image mask
    Clutimage=>image-handle, interpolate={Average, Bicubic, Bilinear, Filter, Integer, Mesh, NearestNeighbor}, channel=>{Red, RGB, All, etc.}apply a color lookup table to an image sequence
    Coalesce
    merge a sequence of images
    Colorcolor=>color nameset the entire image to this color.
    ColorDecisionListfilename=>string,color correct with a color decision list.
    Colorizefill=>color name, blend=>stringcolorize the image with the fill color
    ColorMatrixmatrix=>array of float valuesapply color correction to the image. Although you can use variable sized matrices, typically you use a 5 x 5 for an RGBA image and a 6x6 for CMYKA. A 6x6 matrix is required for offsets (populate the last column with normalized values).
    Commentstringadd a comment to your image
    CompareLayersmethod=>{any, clear, overlay}compares each image with the next in a sequence and returns the minimum bounding region of any pixel differences it discovers. Images do not have to be the same size, though it is best that all the images are coalesced (images are all the same size, on a flattened canvas, so as to represent exactly how a specific frame should look).
    Compositeimage=>image-handle, compose=>{Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor }, mask=>image-handle, geometry=>geometry, x=>integer, y=>integer, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}, opacity=>integer, tile=>{True, False}, rotate=>double, color=>color name, blend=>geometry, interpolate=>{undefined, average, bicubic, bilinear, filter, integer, mesh, nearest-neighbor, spline}composite one image onto another. Use the rotate parameter in concert with the tile parameter.
    ConnectedComponentsconnectivity=>integer,connected-components uniquely labeled, choose from 4 or 8 w -ay connectivity.
    Contrastsharpen=>{True, False}enhance or reduce the image contrast
    ContrastStretchlevels=>string, 'black-point'=>double, 'white-point'=>double, channel=>{Red, RGB, All, etc.}improve the contrast in an image by `stretching' the range of intensity values
    Convolvecoefficients=>array of float values, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, bias=>doubleapply a convolution kernel to the image. Given a kernel order , you would supply order*order float values (e.g. 3x3 implies 9 values).
    CopyPixelsimage=>image-handle, geometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integer, offset=>geometry, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}, dx=>integer, dy=>integercopy pixels from the image as defined by the widthxheight+x+y to image at offset +dx,+dy.
    ConnectedComponentsconnectivity=>integer,connected-components uniquely labeled, choose from 4 or 8 w -ay connectivity.
    Cropgeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integer, fuzz=>double, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}crop an image
    CycleColormapamount=>integerdisplace image colormap by amount
    Decipherpassphrase=>stringconvert cipher pixels to plain pixels
    Deconstruct
    break down an image sequence into constituent parts
    Deskewgeometry=>string,threshold=>doublestraighten the image
    Despeckle reduce the speckles within an image
    Differenceimage=>image-handlecompute the difference metrics between two images
    Distortpoints=>array of float values, method=>{Affine, AffineProjection, Bilinear, Perspective, Resize, ScaleRotateTranslate}, 'virtual-pixel'=>{Background Black Constant Dither Edge Gray Mirror Random Tile Transparent White}, 'best-fit'=>{True, False}distort image
    Drawprimitive=>{point, line, rectangle, arc, ellipse, circle, path, polyline, polygon, bezier, color, matte, text, @filename}, points=>string , method=>{Point, Replace, Floodfill, FillToBorder, Reset}, stroke=>color name, fill=>color name, font=>string, pointsize=>integer, strokewidth=>float, antialias=>{true, false}, bordercolor=>color name, x=>float, y=>float, dash-offset=>float, dash-pattern=>array of float values, affine=>array of float values, translate=>float, float, scale=>float, float, rotate=>float, skewX=>float, skewY=>float, interpolate=>{undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline}, kerning=>float, text=>string, vector-graphics=>string, interline-spacing=>double, interword-spacing=>double, direction=>{right-to-left, left-to-right}annotate an image with one or more graphic primitives.
    Encipherpassphrase=>stringconvert plain pixels to cipher pixels
    Edgeradius=>doubleenhance edges within the image with a convolution filter of the given radius.
    Embossgeometry=>geometry, radius=>double, sigma=>doubleemboss the image with a convolution filter of the given radius and standard deviation (sigma).
    Enhance
    apply a digital filter to enhance a noisy image
    Equalizechannel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}
    perform histogram equalization to the image
    Extentgeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integer, fuzz=>double, background=>color name, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}set the image size
    Evaluatevalue=>double, operator=>{Add, And, Divide, LeftShift, Max, Min, Multiply, Or, Rightshift, RMS, Subtract, Xor}, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow} apply an arithmetic, relational, or logical expression to the image
    Filterkernel=>string, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, bias=>doubleapply a convolution kernel to the image.
    Flip
    reflect the image scanlines in the vertical direction
    Flop
    reflect the image scanlines in the horizontal direction
    FloodfillPaintgeometry=>geometry, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, x=>integer, y=>integer , fill=>color name, bordercolor=>color name, fuzz=>double, invert=>{True, False}changes the color value of any pixel that matches the color of the target pixel and is a neighbor. If you specify a border color, the color value is changed for any neighbor pixel that is not that color.
    ForwardFourierTransformmagnitude=>{True, False}implements the forward discrete Fourier transform (DFT)
    Framegeometry=>geometry, width=>integer, height=>integer, inner=>integer, outer=>integer, fill=>color name, compose=>{Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor },surround the image with an ornamental border
    Functionparameters=>array of float values, function=>{Sin}, 'virtual-pixel'=>{Background Black Constant Dither Edge Gray Mirror Random Tile Transparent White}apply a function to the image
    Gammagamma=>string, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}gamma correct the image
    GaussianBlurgeometry=>geometry, radius=>double, sigma=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}reduce image noise and reduce detail levels with a Gaussian operator of the given radius and standard deviation (sigma).
    GetPixelgeometry=>geometry, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, normalize=>{true, false}, x=>integer, y=>integerget a single pixel. By default normalized pixel values are returned.
    GetPixelsgeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integer, map=>string, normalize=>{true, false}get image pixels as defined by the map (e.g. "RGB", "RGBA", etc.). By default non-normalized pixel values are returned.
    Grayscalechannel=>{Average, Brightness, Lightness, Rec601Luma, Rec601Luminance, Rec709Luma, Rec709Luminance, RMS}convert image to grayscale
    HaldClutimage=>image-handle, channel=>{Red, RGB, All, etc.}apply a Hald color lookup table to an image sequence
    HoughLinegeometry=>geometry, width=>double, height=>double, threshold=>doubleidentify lines in the image (e.g. HoughLine('9x9+195')).
    Identifyfile=>file, features=>distance, unique=>{True, False}identify the attributes of an image
    Implodeamount=>double, interpolate=>{undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline}implode image pixels about the center
    InverseDiscreteFourierTransformmagnitude=>{True, False}implements the inverse discrete Fourier transform (DFT)
    Kuwaharageometry=>geometry, radius=>double, sigma=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}edge preserving noise reduction filter
    Labelstringassign a label to an image
    Layersmethod=>{coalesce, compare-any, compare-clear, compare-over, composite, dispose, flatten, merge, mosaic, optimize, optimize-image, optimize-plus, optimize-trans, remove-dups, remove-zero}, compose=>{Undefined, Add, Atop, Blend, Bumpmap, Clear, ColorBurn, ColorDodge, Colorize, CopyBlack, CopyBlue, CopyCMYK, Cyan, CopyGreen, Copy, CopyMagenta, CopyOpacity, CopyRed, RGB, CopyYellow, Darken, Dst, Difference, Displace, Dissolve, DstAtop, DstIn, DstOut, DstOver, Dst, Exclusion, HardLight, Hue, In, Lighten, LinearLight, Luminize, Minus, Modulate, Multiply, None, Out, Overlay, Over, Plus, ReplaceCompositeOp, Saturate, Screen, SoftLight, Src, SrcAtop, SrcIn, SrcOut, SrcOver, Src, Subtract, Threshold, Xor }, dither=>{true, false}compare each image the GIF disposed forms of the previous image in the sequence. From this, attempt to select the smallest cropped image to replace each frame, while preserving the results of the animation.
    Levellevels=>string, 'black-point'=>double, 'gamma'=>double, 'white-point'=>double, channel=>{Red, RGB, All, etc.}adjust the level of image contrast
    LevelColorsinvert=>>{True, False}, 'black-point'=>string, 'white-point'=>string, channel=>{Red, RGB, All, etc.}level image with the given colors
    LinearStretchlevels=>string, 'black-point'=>double, 'white-point'=>doublelinear with saturation stretch
    LiquidResizegeometry=>geometry, width=>integer, height=>integer, delta-x=>double, rigidity=>doublerescale image with seam-carving.
    Magnify
    double the size of the image with pixel art scaling
    Maskmask=>image-handlecomposite image pixels as defined by the mask
    MatteFloodfillgeometry=>geometry, x=>integer, y=>integer , matte=>integer, bordercolor=>color name, fuzz=>double, invert=>{True, False}changes the matte value of any pixel that matches the color of the target pixel and is a neighbor. If you specify a border color, the matte value is changed for any neighbor pixel that is not that color.
    MeanShiftgeometry=>geometry, width=>double, height=>double, distance=>doubledelineate arbitrarily shaped clusters in the image (e.g. MeanShift('7x7+10%')).
    MedianFiltergeometry=>geometry, width=>integer, height=>integer, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}replace each pixel with the median intensity pixel of a neighborhood.
    Minify
    half the size of an image
    Modegeometry=>geometry, width=>integer, height=>integer, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}make each pixel the predominant color of the neighborhood.
    Modulatefactor=>geometry, brightness=>double, saturation=>double, hue=>double, lightness=>double, whiteness=>double, blackness=>double vary the brightness, saturation, and hue of an image by the specified percentage
    Morphologykernel=>string, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, iterations=>integerapply a morphology method to the image.
    MotionBlurgeometry=>geometry, radius=>double, sigma=>double, angle=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}reduce image noise and reduce detail levels with a Gaussian operator of the given radius and standard deviation (sigma) at the given angle to simulate the effect of motion
    Negategray=>{True, False}, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}replace each pixel with its complementary color (white becomes black, yellow becomes blue, etc.)
    Normalizechannel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}
    transform image to span the full range of color values
    OilPaintradius=>integersimulate an oil painting
    Opaquecolor=>color name, -fill=>color name, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, invert=>{True, False}change this color to the fill color within the image
    OrderedDitherthreshold=>{threshold, checks, o2x2, o3x3, o4x4, o8x8, h4x4a, h6x6a, h8x8a, h4x4o, h6x6o, h8x8o, h16x16o, hlines6x4}, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}order dither image
    Perceptibleepsilon=>double, channel=>{Red, RGB, All, etc.}set each pixel whose value is less than |epsilon| to -epsilon or epsilon (whichever is closer) otherwise the pixel value remains unchanged..
    Polaroidcaption=>string, angle=>double, pointsize=>double, font=>string, stroke=> color name, strokewidth=>integer, fill=>color name, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}, background=>color namesimulate a Polaroid picture.
    Posterizelevels=>integer, dither=>{True, False}reduce the image to a limited number of color level
    Profilename=>string, profile=>blob, rendering-intent=>{Undefined, Saturation, Perceptual, Absolute, Relative}, black-point-compensation=>{True, False}add or remove ICC or IPTC image profile; name is formal name (e.g. ICC or filename; set profile to '' to remove profile
    Quantizecolors=>integer, colorspace=>{RGB, Gray, Transparent, OHTA, XYZ, YCbCr, YIQ, YPbPr, YUV, CMYK, sRGB, HSL, HSB}, treedepth=> integer, dither=>{True, False}, dither-method=>{Riemersma, Floyd-Steinberg}, measure_error=>{True, False}, global_colormap=>{True, False}, transparent-color=>colorpreferred number of colors in the image
    Raisegeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integer, raise=>{True, False}lighten or darken image edges to create a 3-D effect
    ReduceNoisegeometry=>geometry, width=>integer, height=>integer, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}reduce noise in the image with a noise peak elimination filter
    Remapimage=>image-handle, dither=>{true, false}, dither-method=>{Riemersma, Floyd-Steinberg}replace the colors of an image with the closest color from a reference image.
    Resampledensity=>geometry, x=>double, y=>double, filter=>{Point, Box, Triangle, Hermite, Hanning, Hamming, Blackman, Gaussian, Quadratic, Cubic, Catrom, Mitchell, Lanczos, Bessel, Sinc}, support=>doubleresample image to desired resolution. Specify blur > 1 for blurry or < 1 for sharp
    Resizegeometry=>geometry, width=>integer, height=>integer, filter=>{Point, Box, Triangle, Hermite, Hanning, Hamming, Blackman, Gaussian, Quadratic, Cubic, Catrom, Mitchell, Lanczos, Bessel, Sinc}, support=>double, blur=>doublescale image to desired size. Specify blur > 1 for blurry or < 1 for sharp
    Rollgeometry=>geometry, x=>integer, y=>integerroll an image vertically or horizontally
    Rotatedegrees=>double, background=>color namerotate an image
    RotationalBlurgeometry=>geometry, angle=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}radial blur the image.
    Samplegeometry=>geometry, width=>integer, height=>integerscale image with pixel sampling.
    Scalegeometry=>geometry, width=>integer, height=>integerscale image to desired size
    Segmentcolorspace=>{RGB, Gray, Transparent, OHTA, XYZ, YCbCr, YCC, YIQ, YPbPr, YUV, CMYK}, verbose={True, False}, cluster-threshold=>double, smoothing-threshold=doublesegment an image by analyzing the histograms of the color components and identifying units that are homogeneous
    SelectiveBlurgeometry=>geometry, radius=>double, sigma=>double, threshold=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}selectively blur pixels within a contrast threshold.
    Separatechannel=>{Red, RGB, All, etc.}separate a channel from the image into a grayscale image
    Shadegeometry=>geometry, azimuth=>double, elevation=>double, gray=>{true, false}shade the image using a distant light source
    SetPixelgeometry=>geometry, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, color=>array of float values, x=>integer, y=>integer, color=>array of float valuesset a single pixel. By default normalized pixel values are expected.
    Shadowgeometry=>geometry, opacity=>double, sigma=>double, x=>integer, y=>integersimulate an image shadow
    Sharpengeometry=>geometry, radius=>double, sigma=>double, bias=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}sharpen the image with a Gaussian operator of the given radius and standard deviation (sigma).
    Shavegeometry=>geometry, width=>integer, height=>integershave pixels from the image edges
    Sheargeometry=>geometry, x=>double, y=>double fill=>color nameshear the image along the X or Y axis by a positive or negative shear angle
    SigmoidalContrastgeometry=>string, 'contrast'=>double, 'mid-point'=>double channel=>{Red, RGB, All, etc.}, sharpen=>{True, False}sigmoidal non-lineraity contrast control. Increase the contrast of the image using a sigmoidal transfer function without saturating highlights or shadows. Contrast indicates how much to increase the contrast (0 is none; 3 is typical; 20 is a lot); mid-point indicates where midtones fall in the resultant image (0 is white; 50% is middle-gray; 100% is black). To decrease contrast, set sharpen to False.
    Signature
    generate an SHA-256 message digest for the image pixel stream
    Sketchgeometry=>geometry, radius=>double, sigma=>double, angle=>doublesketch the image with a Gaussian operator of the given radius and standard deviation (sigma) at the given angle
    Solarizegeometry=>string, threshold=>double, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}negate all pixels above the threshold level
    SparseColorpoints=>array of float values, method=>{Barycentric, Bilinear, Shepards, Voronoi}, 'virtual-pixel'=>{Background Black Constant Dither Edge Gray Mirror Random Tile Transparent White}interpolate the image colors around the supplied points
    Splicegeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integer, fuzz=>double, background=>color name, gravity=>{NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}splice an image
    Spreadradius=>double, interpolate=>{undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline}displace image pixels by a random amount
    Statisticgeometry=>geometry, width=>integer, height=>integer, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}, type=>{Median, Mode, Mean, Maximum, Minimum, ReduceNoise, RMS}replace each pixel with corresponding statistic from the neighborhood.
    Steganoimage=>image-handle, offset=>integerhide a digital watermark within the image
    Stereoimage=>image-handle, x=>integer, y=>integercomposites two images and produces a single image that is the composite of a left and right image of a stereo pair
    Strip
    strip an image of all profiles and comments.
    Swirldegrees=>double, interpolate=>{undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline}swirl image pixels about the center
    Texturetexture=>image-handlename of texture to tile onto the image background
    Thumbnailgeometry=>geometry, width=>integer, height=>integerchanges the size of an image to the given dimensions and removes any associated profiles.
    Thresholdthreshold=>string, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}threshold the image
    Tintfill=>color name, blend=>stringtint the image with the fill color.
    Transparentcolor=>color name, invert=>{True, False}make this color transparent within the image
    Transpose
    flip image in the vertical direction and rotate 90 degrees
    Transverse
    flop image in the horizontal direction and rotate 270 degrees
    Trim
    remove edges that are the background color from the image
    UnsharpMaskgeometry=>geometry, radius=>double, sigma=>double, gain=>double, threshold=>doublesharpen the image with the unsharp mask algorithm.
    Vignettegeometry=>geometry, radius=>double, sigma=>double, x=>integer, y=>integer, background=>color nameoffset the edges of the image in vignette style
    Wavegeometry=>geometry, amplitude=>double, wavelength=>double, interpolate=>{undefined, average, bicubic, bilinear, mesh, nearest-neighbor, spline}alter an image along a sine wave
    WhiteThresholdthreshold=>string, , channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow}force all pixels above the threshold intensity into white
    - -

    Note, that the geometry parameter is a short cut for the width and height parameters (e.g. geometry=>'106x80' is equivalent to width=>106, height=>80 ).

    - -

    You can specify @filename in both Annotate() and Draw(). This reads the text or graphic primitive instructions from a file on disk. For example,

    - -
    -image->Draw(fill=>'red', primitive=>'rectangle',
    - points=>'20,20 100,100  40,40 200,200  60,60 300,300');
    -
    - -

    Is equivalent to

    - -
    -$image->Draw(fill=>'red', primitive=>'@draw.txt');
    -
    - -

    Where draw.txt is a file on disk that contains this:

    - -
    -rectangle 20, 20 100, 100
    -rectangle 40, 40 200, 200
    -rectangle 60, 60 300, 300
    -
    - -

    The text parameter for methods, Annotate(), Comment(), Draw(), and Label() can include the image filename, type, width, height, or other image attribute by embedding these special format characters:

    - -
    %b   file size
    -%c   comment
    -%d   directory
    -%e   filename extension
    -%f   filename
    -%g   page geometry
    -%h   height
    -%i   input filename
    -%k   number of unique colors
    -%l   label
    -%m   magick
    -%n   number of scenes
    -%o   output filename
    -%p   page number
    -%q   quantum depth
    -%r   image class and colorspace
    -%s   scene number
    -%t   top of filename
    -%u   unique temporary filename
    -%w   width
    -%x   x resolution
    -%y   y resolution
    -%z   image depth
    -%C   image compression type
    -%D   image dispose method
    -%H   page height
    -%Q   image compression quality
    -%T   image delay
    -%W   page width
    -%X   page x offset
    -%Y   page y offset
    -%@   bounding box
    -%#   signature
    -%%   a percent sign
    -\n   newline
    -\r   carriage return
    -
    - -

    For example,

    - -
    -text=>"%m:%f %wx%h"
    -
    - -

    produces an annotation of MIFF:bird.miff 512x480 for an image titled bird.miff and whose width is 512 and height is 480.

    - -

    You can optionally add Image to any method name. For example, TrimImage() is an alias for method Trim().

    - -

    Most of the attributes listed above have an analog in convert. See the documentation for a more detailed description of these attributes.

    - -

    Set an Image Attribute

    - -

    Use method Set() to set an image attribute. For example,

    - -
    -$image->Set(dither=>'True');
    -$image->[$x]->Set(delay=>3);
    -
    - -

    Where this example uses 'True' and this document says '{True, False}', -you can use the case-insensitive strings 'True' and 'False', or you -can use the integers 1 and 0.

    - -

    When you call Get() on a Boolean attribute, Image::Magick returns 1 or 0, not a string.

    - -

    And here is a list of all the image attributes you can set:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Image Attributes
    AttributeValuesDescription
    adjoin{True, False}join images into a single multi-image file
    alpha{On, Off, Opaque, Transparent, Copy, Extract, Set}control of and special operations involving the alpha/matte channel
    antialias{True, False}remove pixel aliasing
    area-limitintegerset pixel area resource limit.
    attenuatedoublelessen (or intensify) when adding noise to an image.
    authenticatestringdecrypt image with this password.
    backgroundcolor nameimage background color
    blue-primaryx-value, y-valuechromaticity blue primary point (e.g. 0.15, 0.06)
    bordercolorcolor nameset the image border color
    clip-maskimageassociate a clip mask with the image.
    colormap[i]color namecolor name (e.g. red) or hex value (e.g. #ccc) at position -i
    commentstringset the image comment
    compression{None, BZip, Fax, Group4, JPEG, JPEG2000, LosslessJPEG, LZW, RLE, Zip}type of image compression
    debug{All, Annotate, Blob, Cache, Coder, Configure, Deprecate, Draw, Exception, Locale, None, Resource, Transform, X11}display copious debugging information
    delayintegerthis many 1/100ths of a second must expire before displaying the next image in a sequence
    densitygeometryvertical and horizontal resolution in pixels of the image
    depthintegerimage depth
    direction{Undefined, right-to-left, left-to-rightrender text right-to-left or left-to-right
    disk-limitintegerset disk resource limit
    dispose{Undefined, None, Background, Previous}layer disposal method
    dither{True, False}apply error diffusion to the image
    displaystringspecifies the X server to contact
    extractgeometryextract area from image
    filefilehandleset the image filehandle
    filenamestringset the image filename
    fillcolorThe fill color paints any areas inside the outline of drawn shape.
    fontstringuse this font when annotating the image with text
    fuzzintegercolors within this distance are considered equal
    gammadoublegamma level of the image
    Gravity{Forget, NorthWest, North, NorthEast, West, Center, East, SouthWest, South, SouthEast}type of image gravity
    green-primaryx-value, y-valuechromaticity green primary point (e.g. 0.3, 0.6)
    index[x, y]stringcolormap index at position (x, y)
    interlace{None, Line, Plane, Partition, JPEG, GIF, PNG}the type of interlacing scheme
    iterationsintegeradd Netscape loop extension to your GIF animation
    labelstringset the image label
    loopintegeradd Netscape loop extension to your GIF animation
    magickstringset the image format
    map-limitintegerset map resource limit
    maskimageassociate a mask with the image.
    matte{True, False}enable the image matte channel
    mattecolorcolor nameset the image matte color
    memory-limitintegerset memory resource limit
    monochrome{True, False}transform the image to black and white
    optionstringassociate an option with an image format (e.g. option=>'ps:imagemask'
    orientation{top-left, top-right, bottom-right, bottom-left, left-top, right-top, right-bottom, left-bottom}image orientation
    page{ Letter, Tabloid, Ledger, Legal, Statement, Executive, A3, A4, A5, B4, B5, Folio, Quarto, 10x14} or geometrypreferred size and location of an image canvas
    pixel[x, y]stringhex value (e.g. #ccc) at position (x, y)
    pointsizeintegerpointsize of the Postscript or TrueType font
    qualityintegerJPEG/MIFF/PNG compression level
    red-primaryx-value, y-valuechromaticity red primary point (e.g. 0.64, 0.33)
    sampling-factorgeometryhorizontal and vertical sampling factor
    sceneintegerimage scene number
    serverstringspecifies the X server to contact
    sizestringwidth and height of a raw image
    strokecolorThe stroke color paints along the outline of a shape.
    texturestringname of texture to tile onto the image background
    tile-offsetgeometryimage tile offset
    time-limitintegerset time resource limit in seconds
    type{Bilevel, Grayscale, GrayscaleMatte, Palette, PaletteMatte, TrueColor, TrueColorMatte, ColorSeparation, ColorSeparationMatte}image type
    units{ Undefined, PixelsPerInch, PixelsPerCentimeter}units of image resolution
    verbose{True, False}print detailed information about the image
    virtual-pixel{Background Black Constant Dither Edge Gray Mirror Random Tile Transparent White}the virtual pixel method
    white-pointx-value, y-valuechromaticity white point (e.g. 0.3127, 0.329)
    - -

    Note, that the geometry parameter is a short cut for the width and height parameters (e.g. geometry=>'106x80' is equivalent to width=>106, height=>80).

    - -

    SetAttribute() is an alias for method Set().

    - -

    Most of the attributes listed above have an analog in -convert. See the documentation for a more detailed description of these attributes.

    - -

    Get an Image Attribute

    - -

    Use method Get() to get an image attribute. For example,

    - -
    -($a, $b, $c) = $image->Get('colorspace', 'magick', 'adjoin');
    -$width = $image->[3]->Get('columns');
    -
    - -

    In addition to all the attributes listed in Set an Image Attribute , you can get these additional attributes:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Image Attributes
    AttributeValuesDescription
    areaintegercurrent area resource consumed
    base-columnsintegerbase image width (before transformations)
    base-filenamestringbase image filename (before transformations)
    base-rowsintegerbase image height (before transformations)
    class{Direct, Pseudo}image class
    colorsintegernumber of unique colors in the image
    columnsintegerimage width
    copyrightstringget PerlMagick's copyright
    directorystringtile names from within an image montage
    elapsed-timedoubleelapsed time in seconds since the image was created
    errordoublethe mean error per pixel computed with methods Compare() or Quantize()
    bounding-boxstringimage bounding box
    diskintegercurrent disk resource consumed
    filesizeintegernumber of bytes of the image on disk
    formatstringget the descriptive image format
    geometrystringimage geometry
    heightintegerthe number of rows or height of an image
    idintegerImageMagick registry id
    mean-errordoublethe normalized mean error per pixel computed with methods Compare() or Quantize()
    mapintegercurrent memory-mapped resource consumed
    matte{True, False}whether or not the image has a matte channel
    maximum-errordoublethe normalized max error per pixel computed with methods Compare() or Quantize()
    memoryintegercurrent memory resource consumed
    mimestringMIME of the image format
    montagegeometrytile size and offset within an image montage
    page.xintegerx offset of image virtual canvas
    page.yintegery offset of image virtual canvas
    rowsintegerthe number of rows or height of an image
    signaturestringSHA-256 message digest associated with the image pixel stream
    taint{True, False}True if the image has been modified
    total-ink-densitydoublereturns the total ink density for a CMYK image
    transparent-colorcolor nameset the image transparent color
    user-timedoubleuser time in seconds since the image was created
    versionstringget PerlMagick's version
    widthintegerthe number of columns or width of an image
    x-resolutionintegerx resolution of the image
    y-resolutionintegery resolution of the image
    - -

    GetAttribute() is an alias for method Get().

    - -

    Most of the attributes listed above have an analog in -convert. See the documentation for a more detailed description of these attributes.

    - -

    Compare an Image to its Reconstruction

    - -

    Mathematically and visually annotate the difference between an image and its reconstruction with the Compare() method. The method supports these parameters:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Compare Parameters
    ParameterValuesDescription
    channeldoubleselect image channels, the default is all channels except alpha.
    fuzzdoublecolors within this distance are considered equal
    imageimage-referencethe image reconstruction
    metricAE, MAE, MEPP, MSE, PAE, PSNR, RMSEmeasure differences between images with this metric
    - -

    In this example, we compare the ImageMagick logo to a sharpened reconstruction:

    - -
    -use Image::Magick;
    -
    -$logo=Image::Magick->New();
    -$logo->Read('logo:');
    -$sharp=Image::Magick->New();
    -$sharp->Read('logo:');
    -$sharp->Sharpen('0x1');
    -$difference=$logo->Compare(image=>$sharp, metric=>'rmse');
    -print $difference->Get('error'), "\n";
    -$difference->Display();
    -
    - -

    In addition to the reported root mean squared error of around 0.024, a difference image is displayed so you can visually identify the difference between the images.

    - -

    Create an Image Montage

    - -

    Use method Montage() to create a composite image by combining several separate images. The images are tiled on the composite image with the name of the image optionally appearing just below the individual tile. For example,

    - -
    -$image->Montage(geometry=>'160x160', tile=>'2x2', texture=>'granite:');
    -
    - -

    And here is a list of Montage() parameters you can set:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Montage Parameters
    ParameterValuesDescription
    backgroundcolor namebackground color name
    borderintegerimage border width
    filenamestringname of montage image
    fillcolor namefill color for annotations
    fontstringX11 font name
    framegeometrysurround the image with an ornamental border
    geometrygeometrypreferred tile and border size of each tile of the composite -image (e.g. 120x120+4+3>)
    gravityNorthWest, North, NorthEast, West, Center, East, SouthWest, -South, SouthEastdirection image gravitates to within a tile
    labelstringassign a label to an image
    modeFrame, Unframe, Concatenatethumbnail framing options
    pointsizeintegerpointsize of the Postscript or TrueType font
    shadow{True, False}add a shadow beneath a tile to simulate depth
    strokecolor namestroke color for annotations
    texturestringname of texture to tile onto the image background
    tilegeometrythe number of tiles per row and page (e.g. 6x4)
    titlestringassign a title to the image montage
    transparentstringmake this color transparent within the image
    - -

    Note, that the geometry parameter is a short cut for the width and height parameters (e.g. geometry=>'106x80' is equivalent to width=>106, height=>80).

    - -

    MontageImage() is an alias for method Montage().

    - -

    Most of the attributes listed above have an analog in montage. See the documentation for a more detailed description of these attributes.

    - -

    Working with Blobs

    - -

    A blob contains data that directly represent a particular image -format in memory instead of on disk. PerlMagick supports -blobs in any of these image formats and provides methods to convert a blob to or from a particular image format.

    - - - - - - - - - - - - - - - - - - - - - - - - - -
    Blob Methods
    MethodParametersReturn ValueDescription
    ImageToBlobany image attributean array of image data in the respective image formatconvert an image or image sequence to an array of blobs
    BlobToImageone or more blobsthe number of blobs converted to an imageconvert one or more blobs to an image
    - -

    ImageToBlob() returns the image data in their respective formats. You can then print it, save it to an ODBC database, write it to a file, or pipe it to a display program:

    - -
    -@blobs = $image->ImageToBlob();
    -open(DISPLAY,"| display -") || die;
    -binmode DISPLAY;
    -print DISPLAY $blobs[0];
    -close DISPLAY;
    -
    - -

    Method BlobToImage() returns an image or image sequence converted from the supplied blob:

    - -
    -@blob=$db->GetImage();
    -$image=Image::Magick->new(magick=>'jpg');
    -$image->BlobToImage(@blob);
    -
    - -

    Direct-access to Image Pixels

    - -

    Use these methods to obtain direct access to the image pixels:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Direct-access to Image Pixels
    MethodParametersDescription
    GetAuthenticPixelsgeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integerreturn authentic pixels as a C pointer
    GetVirtualPixelsgeometry=>geometry, width=>integer, height=>integer, x=>integer, y=>integerreturn virtual pixels as a const C pointer
    GetAuthenticIndexQueuereturn colormap indexes or black pixels as a C pointer
    GetVirtualIndexQueuereturn colormap indexes or black pixels as a const C pointer
    SyncAuthenticPixelssync authentic pixels to pixel cache
    - -

    Miscellaneous Methods

    - -

    The Append() method append a set of images. For example,

    - -
    -$p = $image->Append(stack=>{true,false});
    -
    - -

    appends all the images associated with object $image. By default, images are stacked left-to-right. Set stack to True to stack them top-to-bottom.

    - -

    The Clone() method copies a set of images. For example,

    - -
    -$q = $p->Clone();
    -
    - -

    copies all the images from object $p to $q. You can use this method for single or multi-image sequences.

    - -

    The ComplexImages() method performs complex mathematics on an image sequence. For example,

    - -
    -$p = $image->ComplexImages('conjugate');
    -
    - -

    The EvaluateImages() method applies an arithmetic, logical or relational expression to a set of images. For example,

    - - -
    -$p = $image->EvaluateImages('mean');
    -
    - -

    averages all the images associated with object $image.

    - -

    The Features() method returns features for each channel in the image in each of four directions (horizontal, vertical, left and right diagonals) for the specified distance. The features include the angular second momentum, contrast, correlation, sum of squares: variance, inverse difference moment, sum average, sum varience, sum entropy, entropy, difference variance, difference entropy, information measures of correlation 1, information measures of correlation 2, and maximum correlation coefficient. Values in RGB, CMYK, RGBA, or CMYKA order (depending on the image type).

    - -
    -@features = $image->Features(1);
    -
    - -

    Finally, the Transform() method accepts a fully-qualified geometry specification for cropping or resizing one or more images. For example,

    - -
    -$p = $images->Transform(crop=>'100x100+10+60');
    -
    - -

    The Flatten() method flattens a set of images and returns it. For example,

    - -
    -$p = $images->Flatten(background=>'none');
    -$p->Write('flatten.png');
    -
    - -

    The sequence of images is replaced by a single image created by composing each image after the first over the first image.

    - -

    The Fx() method applies a mathematical expression to a set of images and returns the results. For example,

    - -
    -$p = $image->Fx(expression=>'(g+b)/2.0',channel=>'red');
    -$p->Write('fx.miff');
    -
    - -

    replaces the red channel with the average of the green and blue channels.

    - -

    See FX, The Special Effects Image Operator for a detailed discussion of this method.

    - -

    Histogram() returns the unique colors in the image and a count for each one. The returned values are an array of red, green, blue, opacity, and count values.

    - -

    The Morph() method morphs a set of images. Both the image pixels and size are linearly interpolated to give the appearance of a meta-morphosis from one image to the next:

    - -
    -$p = $image->Morph(frames=>integer);
    -
    - -

    where frames is the number of in-between images to generate. The default is 1.

    - -

    Mosaic() creates an mosaic from an image sequence.

    - -

    Method Mogrify() is a single entry point for the image manipulation methods (Manipulate an Image). The parameters are the name of a method followed by any parameters the method may require. For example, these calls are equivalent:

    - -
    -$image->Crop('340x256+0+0');
    -$image->Mogrify('crop', '340x256+0+0');
    -
    - -

    Method MogrifyRegion() applies a transform to a region of the image. It is similar to Mogrify() but begins with the region geometry. For example, suppose you want to brighten a 100x100 region of your image at location (40, 50):

    - -
    -$image->MogrifyRegion('100x100+40+50', 'modulate', brightness=>50);
    -
    - -

    Ping() is a convenience method that returns information about an image without having to read the image into memory. It returns the width, height, file size in bytes, and the file format of the image. You can specify more than one filename but only one filehandle:

    - -
    -($width, $height, $size, $format) = $image->Ping('logo.png');
    -($width, $height, $size, $format) = $image->Ping(file=>\*IMAGE);
    -($width, $height, $size, $format) = $image->Ping(blob=>$blob);
    -
    - -

    This a more efficient and less memory intensive way to query if an image exists and what its characteristics are.

    - -

    Poly() builds a polynomial from the image sequence and the corresponding terms (coefficients and degree pairs):

    - -
    -$p = $image->Poly([0.5,1.0,0.25,2.0,1.0,1.0]);
    -
    - -

    PreviewImage() tiles 9 thumbnails of the specified image with an image processing operation applied at varying strengths. This may be helpful pin-pointing an appropriate parameter for a particular image processing operation. Choose from these operations: Rotate, Shear, Roll, Hue, Saturation, Brightness, Gamma, Spiff, Dull, Grayscale, Quantize, Despeckle, ReduceNoise, AddNoise, Sharpen, Blur, Threshold, EdgeDetect, Spread, Solarize, Shade, Raise, Segment, Swirl, Implode, Wave, OilPaint, CharcoalDrawing, JPEG. Here is an example:

    - -
    -$preview = $image->Preview('Gamma');
    -$preview->Display();
    -
    - -

    To have full control over text positioning you need font metric information. Use

    - -
    -($x_ppem, $y_ppem, $ascender, $descender, $width, $height, $max_advance) =
    -  $image->QueryFontMetrics(parameters);
    -
    - -

    Where parameters is any parameter of the Annotate method. The return values are:

    - -
      -
    1. character width
    2. -
    3. character height
    4. -
    5. ascender
    6. -
    7. descender
    8. -
    9. text width
    10. -
    11. text height
    12. -
    13. maximum horizontal advance
    14. -
    15. bounds: x1
    16. -
    17. bounds: y1
    18. -
    19. bounds: x2
    20. -
    21. bounds: y2
    22. -
    23. origin: x
    24. -
    25. origin: y
    26. -
    - -

    Use QueryMultilineFontMetrics() to get the maximum text width and height for multiple lines of text.

    - -

    Call QueryColor() with no parameters to return a list of known colors names or specify one or more color names to get these attributes: red, green, blue, and opacity value.

    - -
    -@colors = $image->QueryColor();
    -($red, $green, $blue, $opacity) = $image->QueryColor('cyan');
    -($red, $green, $blue, $opacity) = $image->QueryColor('#716bae');
    -
    - -

    QueryColorname() accepts a color value and returns its respective name or hex value;

    - -
    -$name = $image->QueryColorname('rgba(80,60,0,0)');
    -
    - -

    Call QueryFont() with no parameters to return a list of known fonts or specify one or more font names to get these attributes: font name, description, family, style, stretch, weight, encoding, foundry, format, metrics, and glyphs values.

    - -
    -@fonts = $image->QueryFont();
    -$weight = ($image->QueryFont('Helvetica'))[5];
    -
    - -

    Call QueryFormat() with no parameters to return a list of known image formats or specify one or more format names to get these attributes: adjoin, blob support, raw, decoder, encoder, description, and module.

    - -
    -@formats = $image->QueryFormat();
    -($adjoin, $blob_support, $raw, $decoder, $encoder, $description, $module) =
    -  $image->QueryFormat('gif');
    -
    - -

    Call MagickToMime() with the image format name to get its MIME type such as images/tiff from tif.

    - -
    -$mime = $image->MagickToMime('tif');
    -
    - -

    Use RemoteCommand() to send a command to an already running display or animate application. The only parameter is the name of the image file to display or animate.

    - -
    -$image->RemoteCommand('image.jpg');
    -
    - -

    The Smush() method smushes a set of images together. For example,

    - -
    -$p = $image->Smush(stack=>{true,false},offset=>integer);
    -
    - -

    smushes together all the images associated with object $image. By default, images are smushed left-to-right. Set stack to True to smushed them top-to-bottom.

    - -

    Statistics() returns the image statistics for each channel in the image. The returned values are an array of depth, minima, maxima, mean, standard deviation, kurtosis, skewness, and entropy values in RGB, CMYK, RGBA, or CMYKA order (depending on the image type).

    - -
    -@statistics = $image->Statistics();
    -
    - -

    Finally, the Transform() method accepts a fully-qualified geometry specification for cropping or resizing one or more images. For example,

    - -
    -$p = $image->Transform(crop=>'100x100+0+0');
    -
    - -

    You can optionally add Image to any method name above. For example, PingImage() is an alias for method Ping().

    - -

    Handling Exceptions

    - -

    All PerlMagick methods return an undefined string context upon success. If any problems occur, the error is returned as a string with an embedded numeric status code. A status code less than 400 is a warning. This means that the operation did not complete but was recoverable to some degree. A numeric code greater or equal to 400 is an error and indicates the operation failed completely. Here is how exceptions are returned for the different methods:

    - -

    Methods which return a number (e.g. Read(), Write()):

    - -
    -$x = $image->Read(...);
    -warn "$x" if "$x";      # print the error message
    -$x =~ /(\d+)/;
    -print $1;               # print the error number
    -print 0+$x;             # print the number of images read
    -
    - -

    Methods which operate on an image (e.g. Resize(), Crop()):

    - -
    -$x = $image->Crop(...);
    -warn "$x" if "$x";      # print the error message
    -$x =~ /(\d+)/;
    -print $1;               # print the error number
    -
    - -

    Methods which return images (EvaluateSequence(), Montage(), Clone()) should be checked for errors this way:

    - -
    -$x = $image->Montage(...);
    -warn "$x" if !ref($x);  # print the error message
    -$x =~ /(\d+)/;
    -print $1;               # print the error number
    -
    - -

    Here is an example error message:

    - -
    -Error 400: Memory allocation failed
    -
    - -

    Review the complete list of error and warning codes.

    - -

    The following illustrates how you can use a numeric status code:

    - -
    -$x = $image->Read('rose.png');
    -$x =~ /(\d+)/;
    -die "unable to continue" if ($1 == ResourceLimitError);
    -
    - -

    Constants

    - -

    PerlMagick includes these constants:

    - -
    BlobError
    -BlobWarning
    -CacheError
    -CacheWarning
    -CoderError
    -CoderWarning
    -ConfigureError
    -ConfigureWarning
    -CorruptImageError
    -CorruptImageWarning
    -DelegateError
    -DelegateWarning
    -DrawError
    -DrawWarning
    -ErrorException
    -FatalErrorException
    -FileOpenError
    -FileOpenWarning
    -ImageError
    -ImageWarning
    -MissingDelegateError
    -MissingDelegateWarning
    -ModuleError
    -ModuleWarning
    -Opaque
    -OptionError
    -OptionWarning
    -QuantumDepth
    -QuantumRange
    -RegistryError
    -RegistryWarning
    -ResourceLimitError
    -ResourceLimitWarning
    -StreamError
    -StreamWarning
    -Success
    -Transparent
    -TypeError
    -TypeWarning
    -WarningException
    -XServerError
    -XServerWarning
    -
    - -

    You can access them like this:

    - -
    -Image::Magick->QuantumDepth
    -
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/porting.html b/ImageMagick-7.0.0-0/www/porting.html deleted file mode 100644 index 0a1375a88..000000000 --- a/ImageMagick-7.0.0-0/www/porting.html +++ /dev/null @@ -1,651 +0,0 @@ - - - - - - - - - ImageMagick: Porting to ImageMagick Version 7 - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    - -

    ImageMagick Version 7 • High Dynamic Range Imaging • Pixel Channels • Alpha • Grayscale • Masks • MagickCore API • Header Files • Deprecated Features Removed • Command-line Interface • Version 7 Change Summary

    - -

    The design of ImageMagick is an evolutionary process, with the design and implementation efforts serving to influence and guide further progress in the other. With ImageMagick version 7 we aim to improve the design based on lessons learned from the version 6 implementation. ImageMagick was originally designed to display RGB images to an X Windows server. Over time we extended support to RGBA images and then to the CMYK and CMYKA image format. With ImageMagick version 7, we extend support to arbitrary colorspaces with an arbitrary number of pixel channels. Other design changes are in the works and we will document them here so be sure to revisit periodically.

    - -

    To support variable pixel channels in the MagickCore API, pixel handling has changed when getting or setting the pixel channels. You can access channels as an array, pixel[i], or use an accessor method such as GetPixelRed() or SetPixelRed(). There are some modest changes to the MagickCore and MagickWand API's. The Magick++ and PerlMagick API's have not changed and matches that of the ImageMagick version 6.

    - -

    The shell API (command line) of ImageMagick version 7 is also undergoing -a major overhaul, with specific emphasis on the ability to read 'options' not -only from the command line, but also from scripts, and file streams. This -allows for the use of 'co-processing' programming techniques or performing -image handling using 'deamon/server backends', and even multi-machine -distributed processing.

    - -

    With shell API overhaul other improvements are being made, including: -better reporting of which option failed, the consolidation and deprecation of -options, and more global use of 'image properties' (more commonly known as -'percent escapes' in option arguments.

    - -

    ImageMagick version 7 is available now as an Beta release. Look for an official release around 1st Q 2016. An official ImageMagick version 7 release depends on how smoothly the Beta cycle progresses. During the Beta cycle, version 6 developers can attempt to port their software to version 7.

    - -

    Once ImageMagick version 7 is released, we will continue to support and enhance version 6 for a minimum of 10 years.

    - -

    High Dynamic Range Imaging

    -

    ImageMagick version 7 enables high dynamic range imaging (HDRI) by default. HDRI accurately represents the wide range of intensity levels found in real scenes ranging from the brightest direct sunlight to the deepest darkest shadows. In addition, image processing results are more accurate. The disadvantage is it requires more memory and may result in slower processing times. If you see differences in the results of your version 6 command-line with version 7, it is likely due to HDRI. You may need to add -clamp to your command-line to constrain pixels to the 0 .. QuantumRange range, or disable HDRI when you build ImageMagick version 7. To disable HDRI (recommended for smart phone builds such as iOS or production sites where performance is a premium), simply add --disable-hdri to the configure script command line when building ImageMagick.

    - -

    Pixel Channels

    -

    A pixel is comprised of one or more color values, or channels (e.g. red pixel channel).

    -

    Prior versions of ImageMagick (4-6), support 4 to 5 pixel channels (RGBA or CMYKA). The first 4 channels are accessed with the PixelPacket data structure. The structure includes 4 members of type Quantum (typically 16-bits) of red, green, blue, and opacity. The black channel or colormap indexes are supported by a separate method and structure, IndexPacket. As an example, here is a code snippet from ImageMagick version 6 that negates the color components (but not the alpha component) of the image pixels:

    - - - - - -

    ImageMagick version 7 supports any number of channels from 1 to 32 (and beyond) and simplifies access with a single method that returns an array of pixel channels of type Quantum. Source code that compiles against prior versions of ImageMagick requires refactoring to work with ImageMagick version 7. We illustrate with an example. Let's naively refactor the version 6 code snippet from above so it works with the ImageMagick version 7 API:

    - - - - - -

    Let's do that again but take full advantage of the new variable pixel channel support:

    - - - - - -

    Note, how we use GetPixelChannels() to advance to the next set of pixel channels.

    - -

    The colormap indexes and black pixel channel (for the CMYK colorspace) are no longer stored in the index channel, previously accessed with GetAuthenticIndexQueue() and GetCacheViewAuthenticIndexQueue(). Instead they are now a first class pixel channel and accessed as a member of the pixel array (e.g. pixel[4]) or with the convenience pixel accessor methods GetPixelIndex(), SetPixelIndex(), GetPixelBlack(), and SetPixelBlack().

    - -

    As a consequence of using an array structure for variable pixel channels, auto-vectorization compilers have additional opportunities to speed up pixel loops.

    - -

    Pixel Accessors

    -

    You can access pixel channel as array elements (e.g. pixel[1]) or use convenience accessors to get or set pixel channels:

    - -
    -GetPixela()                  SetPixela()
    -GetPixelAlpha()              SetPixelAlpha()
    -GetPixelb()                  SetPixelb()
    -GetPixelBlack()              SetPixelBlack()
    -GetPixelBlue()               SetPixelBlue()
    -GetPixelCb()                 SetPixelCb()
    -GetPixelCr()                 SetPixelCr()
    -GetPixelCyan()               SetPixelCyan()
    -GetPixelGray()               SetPixelGray()
    -GetPixelGreen()              SetPixelGreen()
    -GetPixelIndex()              SetPixelIndex()
    -GetPixelL()                  SetPixelL()
    -GetPixelMagenta()            SetPixelMagenta()
    -GetPixelReadMask()           SetPixelReadMask()
    -GetPixelWriteMask()          SetPixelWriteMask()
    -GetPixelMetacontentExtent()  SetPixelMetacontentExtent()
    -GetPixelOpacity()            SetPixelOpacity()
    -GetPixelRed()                SetPixelRed()
    -GetPixelYellow()             SetPixelYellow()
    -GetPixelY()                  SetPixelY()
    -
    - -

    You can find these accessors defined in the header file, MagickCore/pixel-accessor.h

    - -

    Pixel Traits

    -

    Each pixel channel includes one or more of these traits:

    -
    -
    Undefined
    -
    no traits associated with this pixel channel
    -
    Copy
    -
    do not update this pixel channel, just copy it
    -
    Update
    -
    update this pixel channel
    -
    Blend
    -
    blend this pixel channel with the alpha mask if it's enabled
    -
    -

    We provide these methods to set and get pixel traits:

    -
    -GetPixelAlphaTraits()    SetPixelAlphaTraits()
    -GetPixelBlackTraits()    SetPixelBlackTraits()
    -GetPixelBlueTraits()     SetPixelBlueTraits()
    -GetPixelCbTraits()       SetPixelCbTraits()
    -GetPixelChannelTraits()  SetPixelChannelTraits()
    -GetPixelCrTraits()       SetPixelCrTraits()
    -GetPixelGrayTraits()     SetPixelGrayTraits()
    -GetPixelGreenTraits()    SetPixelGreenTraits()
    -GetPixelIndexTraits()    SetPixelIndexTraits()
    -GetPixelMagentaTraits()  SetPixelMagentaTraits()
    -GetPixelRedTraits()      SetPixelRedTraits()
    -GetPixelYellowTraits()   SetPixelYellowTraits()
    -GetPixelYTraits()        SetPixelYTraits()
    -
    -

    For convenience you can set the active trait for a set of pixel channels with a channel mask and this method:

    -
    -SetImageChannelMask()
    -
    - -

    Previously MagickCore methods had channel analogs, for example, NegateImage() and NegateImageChannels(). The channel analog methods are no longer necessary because the pixel channel traits specify whether to act on a particular pixel channel or whether to blend with the alpha mask. For example, instead of

    -
    -NegateImageChannel(image,channel);
    -
    -

    we use:

    -
    -channel_mask=SetImageChannelMask(image,channel);
    -NegateImage(image,exception);
    -(void) SetImageChannelMask(image,channel_mask);
    -
    - -

    Pixel User Channels

    -

    In version 7, we introduce pixel user channels. Traditionally we utilize 4 channels, red, green, blue, and alpha. For CMYK we also have a black channel. User channels are designed to contain whatever additional channel information that makes sense for your application. Some examples include extra channels in TIFF or PSD images or perhaps you require a channel with infrared information for the pixel. You can associate traits with the user channels so that they when they are acted upon by an image processing algorithm (e.g. blur) the pixels are copied, acted upon by the algorithm, or even blended with the alpha channel if that makes sense.

    -

    Pixel Metacontent

    -

    In version 7, we introduce pixel metacontent. Metacontent is content about content. So rather than being the content itself, it's something that describes or is associated with the content. Here the content is a pixel. The pixel metacontent is for your exclusive use (internally the data is just copied, it is not modified) and is accessed with these MagickCore API methods:

    -
    -SetImageMetacontentExtent()
    -GetImageMetacontentExtent()
    -GetVirtualMetacontent()
    -GetAuthenticMetacontent()
    -GetCacheViewAuthenticMetacontent()
    -GetCacheViewVirtualMetacontent()
    -
    - -

    Alpha

    -

    We support alpha now, previously opacity. With alpha, a value of 0 means that the pixel does not have any coverage information and is transparent; i.e. there was no color contribution from any geometry because the geometry did not overlap this pixel. A value of QuantumRange means that the pixel is opaque because the geometry completely overlapped the pixel. As a consequence, in version 7, the PixelInfo structure member alpha has replaced the previous opacity member. Another consequence is the alpha part of a sRGB value in hexadecimal notation is now reversed (e.g. #0000 is fully transparent).

    -

    Colorspace

    -

    The Rec601Luma and Rec709Luma colorspaces are no longer supported. Instead, specify the gray colorspace and choose from these intensity options:

    -
    -Rec601Luma
    -Rec601Luminance
    -Rec709Luma
    -Rec709Luminance
    -
    -

    For example,

    -
    -convert myImage.png -intensity Rec709Luminance -colorspace gray myImage.jpg
    -
    - -

    Grayscale

    -

    Previously, grayscale images were Rec601Luminance and consumed 4 channels: red, green, blue, and alpha. With version 7, grayscale consumes only 1 channel requiring far less resources as a result.

    - -

    Masks

    -

    Version 7 supports masks for most image operators. As an example, here are two methods to compute the statistics of any pixel selected by the image mask:

    -
    -identify -verbose -clip statue.tif
    -identify -verbose -read-mask mask.png statue.tif
    -
    - -

    MagickCore API

    -

    Here are a list of changes to the MagickCore API:

    -
      -
    • Almost all image processing algorithms are now channel aware.
    • -
    • The MagickCore API adds an ExceptionInfo argument to those methods that lacked it in version 6, e.g. NegateImage(image,MagickTrue,exception);
    • -
    • All method channel analogs have been removed (e.g. BlurImageChannel()), they are no longer necessary, use pixel traits instead.
    • -
    • Public and private API calls are now declared with the GCC visibility attribute. The MagickCore and MagickWand dynamic libraries now only export public struct and function declarations.
    • -
    • The InterpolatePixelMethod enum is now PixelInterpolateMethod.
    • -
    • The IntegerPixel storage type is removed (use LongPixel instead) and LongLongPixel is added
    • -
    • Image signatures have changed to account for variable pixel channels.
    • -
    • All color packet structures, PixelPacket, LongPacket, and DoublePacket, are consolidated to a single color structure, PixelInfo.
    • -
    • The ChannelMoments structure member I is now invariant. I conflicts with the complex.h header.
    • -
    • We added a length parameter to FormatMagickSize() to permit variable length buffers.
    • -
    -

    MagickWand API

    -

    Here are a list of changes to the MagickWand API:

    -
      -
    • The DrawMatte() method is now called DrawAlpha().
    • -
    • The MagickSetImageBias() and MagickSetImageClipMask() methods are no longer supported.
    • -
    -

    Header Files

    -

    Prior versions of ImageMagick (4-6) reference the ImageMagick header files as magick/ and wand/. ImageMagick 7 instead uses MagickCore/ and MagickWand/ respectively. For example,

    -
    #include <MagickCore/MagickCore.h>
    -#include <MagickWand/MagickWand.h>
    - -

    Deprecated Features Removed

    -

    All deprecated features from ImageMagick version 6 are removed in version 7. These include the Magick-config and Wand-config configuration utilities. Instead use:

    - -
    MagickCore-config
    -MagickWand-config
    -
    -

    The FilterImage() method has been removed. Use ConvolveImage() instead.

    - -

    In addition, all deprecated MagickCore and MagickWand methods are no longer available in version 7.

    - - -

    Shell API or Command-line Interface

    - -

    As mentioned the primary focus of the changes to the Shell API or Command -Line Interface is the abstraction so that not only can options be -read from command line arguments, but also from a file (script) or from a file -stream (interactive commands, or co-processing).

    - -

    To do this the CLI parser needed to be re-written, so as to always perform -all options, in a strict, do-it-as-you-see it order. Previously in IMv6 -options were performed in groups (known as 'FireOptions), this awkwardness is -now gone. However the strict order means that you can no longer give operations -before providing an image for the operations to work on. To do so will now -produce an error.

    - -

    Error reporting is now reporting exactly which option (by argument count on -command line, or line,column in scripts) caused the 'exception'. This is not -complete as yet but getting better. Also not complete is 'regard-warnings' -handling or its replacement, which will allow you to ignore reported errors -and continue processing (as appropriate due to error) in co-processes or -interactive usage.

    - -

    The parenthesis options used to 'push' the current image list, and image -settings (EG: '(' and ')' ) on to a stack now has -a completely separate image settings stack. That is parenthesis 'push/pull' -image lists, and curly braces (EG: '{' and '}' ) will -'push/pull' image settings.

    - -

    Of course due to the previously reported changes to the underlying channel -handling will result be many side effects to almost all options. Here are some -specific

    - -

    Most algorithms update the red, green, blue, black (for CMYK), and alpha -channels. Most operators will blend alpha the other color channels, but other -operators (and situations) may require this blending to be disabled, and is -currently done by removing alpha from teh active channels via --channel option. (e.g. convert castle.gif -channel RGB --negate castle.png).

    - -

    Reading gray-scale images generate an image with only one channel. If -that image is to then accept color the -colorspace setting needs to -be applied to expand the one channel into separate RGB (or other) channels. -

    -

    Previously, command-line arguments were limited to 4096 characters, with ImageMagick version 7 the limit has increased to 131072 characters.

    - -

    Command Changes

    -

    Here are a list of changes to the ImageMagick commands:

    -
    -
    magick
    -
    The "magick" command is the new primary command of the Shell - API, replacing the old "convert" command. This allows you to - create a 'magick script' of the form "#!/path/to/command/magick - -script", or pipe options into a command "magick -script - -, as abackground process.
    - -
    magick-script
    -
    This the same as "magick", (only command name is different) - but which has an implicit "-script" option. This allows you to - use it in an "env" style script form. That is a magick script - starts with the 'she-bang' line of "#!/usr/bin/env - magick-script" allowing the script interpreter to be found anywhere - on the users command "PATH". This is required to get around - a "one argument she-bang bug" that is common on most UNIX systems - (including Linux, but not MacOSX).
    - -
    - -

    Behavioral Changes

    -

    Image settings are applied to each image on the command line. To associate a setting with a particular image, use parenthesis to remove ambiguity. In this example we assign a unique page offset to each image:

    -
    -convert \( -page +10+20 first.png \) \( -page +100+200 second.png \) ...
    -
    - -

    By default, image operations such as convolution blends alpha with each channel. To convolve each channel independently, deactivate the alpha channel as follows:

    -
    -convert ... -alpha discrete -blur 0x1 ...
    -
    -

    To remove the alpha values from your image, use -alpha off.

    -

    Some options have changed in ImageMagick version 7. These include:

    -
    -
    +combine
    -
    This option now requires an argument, the image colorspace (e.g. +combine sRGB).
    -
    - -

    New Options

    -

    ImageMagick version 7 supports these new options, though most are limited -to the "magick" command, or to use in "magick" -scripts.

    - -
    -
    { ... }
    -
    Save (and restore) the current image settings (internally known as the - "image_info" structure). This is automatically done with parenthesis (EG: - '(' and ')') is "-regard-parenthesis" has - been set, just as in IMv6. Caution is advised to prevent un-balanced - braces errors.
    - -
    --
    -
    End of options, to be used in IMv7 "mogrify" command to - explicitly separate the operations to be applied and the images that - are to be processed 'in-place'. (not yet implemented). However if - not provided, "-read" can still be used to differentiate - secondary image reads (for use in things like alpha composition) from - the 'in-place' image being processed.
    - -
    In other commands (such as "magick") it is equivalent to a explicit - "-read" (see below) of the next option as a image (as it was in - IMv6).
    - -
    -alpha discrete
    -
    treat the alpha channel independently (do not blend).
    - -
    -channel-fx expression
    -
    -

    exchange, extract, or copy one or more image channels.

    - -

    The expression consists of one or more channels, either mnemonic or numeric (e.g. red or 0, green or 1, etc.), separated by certain operation symbols as follows:

    - -
    -<=>  exchange two channels (e.g. red<=>blue)
    -=>   copy one channel to another channel (e.g. red=>green)
    -=    assign a constant value to a channel (e.g. red=50%)
    -,    write new image with channels in the specified order (e.g. red, green)
    -;    add a new output image for the next set of channel operations (e.g. red; green; blue)
    -|    move to the next input image for the source of channel data (e.g. | gray=>alpha)
    -
    - -

    For example, to create 3 grayscale images from the red, green, and blue channels of an image, use:

    - -
    --channel-fx "red; green; blue"
    -
    - -

    A channel without an operation symbol implies separate (i.e, semicolon).

    - -

    Here we take an sRGB image and a grayscale image and inject the grayscale image into the alpha channel:

    -
    -convert wizard.png mask.pgm -channel-fx '| gray=>alpha' wizard-alpha.png 
    -
    -

    Use a similar command to define a read mask:

    -
    -convert wizard.png mask.pgm -channel-fx '| gray=>read-mask' wizard-mask.png 
    -
    - -

    Add -debug pixel prior to the -channel-fx option to track the channel morphology.

    - -
    - -
    -exit
    -
    Stop processing at this point. No further options will be processed after - this option. Can be used in a script to force the "magick" - command to exit, without actually closing the pipeline that it is - processing options from.
    - -
    May also be used as a 'final' option on the "magick" command - line, instead of a implicit output image, to completely prevent any image - write. ASIDE: even the "NULL:" coder requires at least one - image, for it to 'not write'! This option does not require any images at - all.
    - -
    -read {image}
    -
    Explicit read of an image, rather than an implicit read. This allows you - to read from filenames that start with an 'option' character, and which - otherwise could be mistaken as an option (unknown or otherwise). This will - eventually be used in "mogrify" to allow the reading of - secondary images, and allow the use of image list operations within that - command.
    - -
    -read-mask
    -
    prevent updates to image pixels specified by the mask
    - -
    -region
    -
    not yet implemented in "magick". (very soon)
    - -
    -script {file}
    -
    In "magick", stop the processing of command line arguments as - image operations, and read all further options from the given file or - pipeline.
    -
    -write-mask
    -
    prevent pixels from being written.
    - -
    - -

    Changed Options

    -

    These options are known to have changed, in some way.

    -
    -
    -bias
    -
    The option is no longer recognized. Use -define convolve:bias=value instead.
    -
    -draw
    -
    The matte primitive is now alpha (e.g. -draw 'alpha 0,0 floodfill').
    -
    -negate
    -
    currently negates all channels, including alpha if present. As such you - may need to use the -channel option to prevent alpha negation.
    -
    - -

    Deprecated warning given, but will work (for now)

    -
    -
    -affine
    -
    Replaced by -draw "affine ...". (see transform)
    -
    -average
    -
    Replaced by -evaluate-sequence Mean.
    -
    -box
    -
    Replaced by -undercolor.
    -
    -deconstruct
    -
    Replaced by -layers CompareAny.
    -
    -gaussian
    -
    Replaced by -gaussian-blur.
    -
    -/+map
    -
    Replaced by -/+remap.
    -
    -/+mask
    -
    Replaced by -/+read-mask, -/+write-mask.
    -
    -/+matte
    -
    Replaced by -alpha Set/Off.
    -
    -transform
    -
    Replaced by -distort Affine "...".
    -
    - -

    Deprecated warning given, and ignored (for now)

    -

    Almost 'plus' (+) option that did not do anything has been marked as -deprecated, and does nothing. It does not even have associated code. For -example "+annotate", "+resize", "+clut", and "+draw" .

    - -
    -
    -affinity
    -
    Replaced by -remap.
    -
    -maximum
    -
    Replaced by -evaluate-sequence Max.
    -
    -median
    -
    Replaced by -evaluate-sequence Median.
    -
    -minimum
    -
    Replaced by -evaluate-sequence Min.
    -
    -recolor
    -
    Replaced by -color-matrix.
    -
    - -

    Removed / Replaced Options ("no such option" error and abort)

    - -
    -
    -origin
    -
    old option, unknown meaning.
    -
    -pen
    -
    Replaced by -fill.
    -
    -passphrase
    -
    old option, unknown meaning
    -
    -

    Version 7 Change Summary

    -

    Changes from ImageMagick version 6 to version 7 are summarized here:

    -

    High Dynamic Range Imaging

    -
      -
    • ImageMagick version 7 enables HDRI by default. Expect more accurate image processing results with higher memory requirement and possible slower processing times.
    • -
    -

    Pixels

    -
      -
    • Pixels are no longer addressed with PixelPacket structure members (e.g. red, green, blue, opacity) but as an array of channels (e.g. pixel[PixelRedChannel]).
    • -
    • Use convenience macros to access pixel channels (e.g. GetPixelRed(), SetPixelRed()).
    • -
    • The black channel for the CMYK colorspace is no longer stored in the index channel, previously accessed with GetAuthenticIndexQueue() and GetCacheViewAuthenticIndexQueue(). Instead it is now a pixel channel and accessed with the convenience pixel macros GetPixelBlack() and SetPixelBlack().
    • -
    • The index channel for colormapped images is no longer stored in the index channel, previously accessed with GetAuthenticIndexQueue() and GetCacheViewAuthenticIndexQueue(). Instead it is now a pixel channel and accessed with the convenience pixel macros GetPixelIndex() and SetPixelIndex().
    • -
    • Use GetPixelChannels() to advance to the next set of pixel channels.
    • -
    • Use the metacontent channel to associate metacontent with each pixel.
    • -
    • All color packet structures, PixelPacket, LongPacket, and DoublePacket, are consolidated to a single color structure, PixelInfo.
    • -
    -

    Alpha

    -
      -
    • We support alpha rather than opacity (0 transparent; QuantumRange opaque).
    • -
    • Use GetPixelAlpha() or SetPixelAlpha() to get or set the alpha pixel channel value.
    • -
    -

    Grayscale

    -
      -
    • Grayscale images consume one pixel channel in ImageMagick version 7. To process RGB, set the colorspace to RGB (e.g. -colorspace sRGB).
    • -
    -

    Masks

    -
      -
    • ImageMagick version 6 only supports read mask in limited circumstances. Version 7 supports both a read and write mask. The read mask is honored by most image-processing algorithms.
    • -
    -

    MagickCore API

    -
      -
    • Almost all image processing algorithms are now channel aware.
    • -
    • MagickCore, version 7, adds an ExceptionInfo argument to those methods that lacked it in version 6, e.g. NegateImage(image,MagickTrue,exception);
    • -
    • All method channel analogs have been removed (e.g. BlurImageChannel()), they are no longer necessary, use pixel traits instead.
    • -
    • Public and private API calls are now declared with the GCC visibility attribute. The MagickCore and MagickWand dynamic libraries now only export public struct and function declarations.
    • -
    • The InterpolatePixelMethod enum is now PixelInterpolateMethod.
    • -
    • To account for variable pixel channels, images may now return a different signature.
    • -
    -

    Deprecated Methods

    -
      -
    • All ImageMagick version 6 MagickCore and MagickWand deprecated methods are removed and no longer available in ImageMagick version 7.
    • -
    • All MagickCore channel method analogs are removed (e.g. NegateImageChannels()). For version 7, use pixel traits instead.
    • -
    • The FilterImage() method has been removed. Use ConvolveImage() instead.
    • -
    -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/quantize.html b/ImageMagick-7.0.0-0/www/quantize.html deleted file mode 100644 index 205255e04..000000000 --- a/ImageMagick-7.0.0-0/www/quantize.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - - - - - ImageMagick: Color Reduction Utilizing Adaptive Spatial Subdivision - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Algorithm Description • Measuring Color Reduction Error

    - -

    This document describes how ImageMagick performs color reduction on an image. To fully understand what follows, you should have a knowledge of basic imaging techniques and the tree data structure and terminology.

    - -

    Algorithm Description

    - -

    For purposes of color allocation, an image is a set of n pixels, where each pixel is a point in RGB space. RGB space is a 3-dimensional vector space, and each pixel, p(i), is defined by an ordered triple of red, green, and blue coordinates, (r(i), g(i), b(i)).

    - -

    Each primary color component (red, green, or blue) represents an intensity which varies linearly from 0 to a maximum value, Cmax, which corresponds to full saturation of that color. Color allocation is defined over a domain consisting of the cube in RGB space with opposite vertices at (0, 0, 0) and (Cmax, Cmax, Cmax). ImageMagick requires Cmax= 255.

    - -

    The algorithm maps this domain onto a tree in which each node represents a cube within that domain. In the following discussion, these cubes are defined by the coordinate of two opposite vertices: The vertex nearest the origin in RGB space and the vertex farthest from the origin.

    - -

    The tree's root node represents the entire domain, (0,0,0) through (Cmax, Cmax, Cmax). Each lower level in the tree is generated by subdividing one node's cube into eight smaller cubes of equal size. This corresponds to bisecting the parent cube with planes passing through the midpoints of each edge.

    - -

    The basic algorithm operates in three phases:

    - -
      -
    1. Classification
    2. -
    3. Reduction
    4. -
    5. Assignment
    6. -
    - -

    Classification

    - -

    Classification builds a color description tree for the image. Reduction collapses the tree until the number it represents, at most, is the number of colors desired in the output image. Assignment defines the output image's color map and sets each pixel's color by reclassification in the reduced tree. Our goal is to minimize the numerical discrepancies between the original colors and quantized colors. To learn more about quantization error, see Measuring Color Reduction Error.

    - -

    Classification begins by initializing a color description tree of sufficient depth to represent each possible input color in a leaf. However, it is impractical to generate a fully-formed color description tree in the classification phase for realistic values of Cmax. If color components in the input image are quantized to k-bit precision, so that Cmax = 2^k-1, the tree would need k levels below the root node to allow representing each possible input color in a leaf. This becomes prohibitive because the tree's total number of nodes:

    - -
    -total nodes = 1+Sum(8^i), i=1,k
    -
    -For k=8,
    -nodes = 1 + (8^1+8^2+....+8^8)
    -      = 1 + 8(8^8 - 1)/(8 - 1)
    -      = 19,173,961
    -
    - -

    Therefore, to avoid building a fully populated tree, ImageMagick:

    - -
      -
    1. initializes data structures for nodes only as they are needed;
    2. -
    3. chooses a maximum depth for the tree as a function of the desired number of colors in the output image (currently the base-two logarithm of Cmax).
    4. -
    - -
    -For Cmax=255,
    -maximum tree depth = log2(256)
    -                   = 8
    -
    - -

    A tree of this depth generally allows the best representation of the source image with the fastest computational speed and the least amount of memory. However, the default depth is inappropriate for some images. Therefore, the caller can request a specific tree depth.

    - -

    For each pixel in the input image, classification scans downward from the root of the color description tree. At each level of the tree, it identifies the single node which represents a cube in RGB space containing the pixels' color. It updates the following data for each such node:

    - -
    -
    n1
    -
    number of pixels whose color is contained in the RGB cube which this node represents;
    -
    n2
    -
    number of pixels whose color is not represented in a node at lower depth in the tree; initially, n2=0 for all nodes except leaves of the tree.
    -
    Sr,Sg,Sb
    -
    sums of the red, green, and blue component values for all pixels not classified at a lower depth. The combination of these sums and n2 will ultimately characterize the mean color of a set of pixels represented by this node.
    -
    E
    -
    the distance squared in RGB space between each pixel contained within a node and the nodes' center. This represents the quantization error for a node.
    -
    - -

    Reduction

    - -

    Reduction repeatedly prunes the tree until the number of nodes with n2 > 0 is less than or equal to the maximum number of colors allowed in the output image. On any given iteration over the tree, it selects those nodes whose E value is minimal for pruning and merges their color statistics upward. It uses a pruning threshold, Ep, to govern node selection as follows:

    - -
    -Ep = 0
    -while number of nodes with (n2 > 0) > required maximum number of colors
    -   prune all nodes such that E <= Ep
    -   Set Ep  to minimum E in remaining nodes
    -
    - -

    This has the effect of minimizing any quantization error when merging two nodes together.

    - -

    When a node to be pruned has offspring, the pruning procedure invokes itself recursively in order to prune the tree from the leaves upward. The values of n2, Sr, Sg, and Sb in a node being pruned are always added to the corresponding data in that node's parent. This retains the pruned node's color characteristics for later averaging.

    - -

    For each node, n2 pixels exist for which that node represents the smallest volume in RGB space containing those pixel's colors. When n2 > 0 the node will uniquely define a color in the output image. At the beginning of reduction, n2 = 0 for all nodes except the leaves of the tree which represent colors present in the input image.

    - -

    The other pixel count, n1, indicates the total number of colors within the cubic volume which the node represents. This includes n1 - n2 pixels whose colors should be defined by nodes at a lower level in the tree.

    - -

    Assignment

    - -

    Assignment generates the output image from the pruned tree. The output image consists of two parts:

    -
      -
    1. A color map, which is an array of color descriptions (RGB triples) for each color present in the output image.
    2. - -
    3. A pixel array, which represents each pixel as an index into the color map array.
    4. -
    - -

    First, the assignment phase makes one pass over the pruned color description tree to establish the image's color map. For each node with n2 > 0, it divides Sr, Sg, and Sb by n2. This produces the mean color of all pixels that classify no lower than this node. Each of these colors becomes an entry in the color map.

    - -

    Finally, the assignment phase reclassifies each pixel in the pruned tree to identify the deepest node containing the pixel's color. The pixel's value in the pixel array becomes the index of this node's mean color in the color map.

    - -

    Empirical evidence suggests that the distances in color spaces such as YUV, or YIQ correspond to perceptual color differences more closely than do distances in RGB space. These color spaces may give better results when color reducing an image. Here the algorithm is as described except each pixel is a point in the alternate color space. For convenience, the color components are normalized to the range 0 to a maximum value, Cmax. The color reduction can then proceed as described.

    - -

    Measuring Color Reduction Error

    - -

    Depending on the image, the color reduction error may be obvious or invisible. Images with high spatial frequencies (such as hair or grass) will show error much less than pictures with large smoothly shaded areas (such as faces). This because the high-frequency contour edges introduced by the color reduction process are masked by the high frequencies in the image.

    - -

    To measure the difference between the original and color reduced images (the total color reduction error), ImageMagick sums over all pixels in an image the distance squared in RGB space between each original pixel value and its color reduced value. ImageMagick prints several error measurements including the mean error per pixel, the normalized mean error, and the normalized maximum error.

    - -

    The normalized error measurement can be used to compare images. In general, the closer the mean error is to zero the more the quantized image resembles the source image. Ideally, the error should be perceptually-based, since the human eye is the final judge of quantization quality.

    - -

    These errors are measured and printed when the -colors and -verbose options are specified on the convert command line:

    - -
    - - - - - - - - - - - - - -
    mean error per pixelis the mean error for any single pixel in the image.
    normalized mean square erroris the normalized mean square quantization error for any single pixel in the image. This distance measure is normalized to a range between 0 and 1. It is independent of the range of red, green, and blue values in the image.
    normalized maximum square erroris the largest normalized square quantization error for any single pixel in the image. This distance measure is normalized to a range between of red, green, and blue values in the image.
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/resources.html b/ImageMagick-7.0.0-0/www/resources.html deleted file mode 100644 index 847776312..000000000 --- a/ImageMagick-7.0.0-0/www/resources.html +++ /dev/null @@ -1,379 +0,0 @@ - - - - - - - - - ImageMagick: Resources - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Configuration Files • Modules • Fonts • Environment Variables

    - -

    ImageMagick depends on a number of external resources including configuration files, loadable modules, fonts, and environment variables.

    - -

    Configuration Files

    - -

    ImageMagick depends on a number of external configuration files detailed here:

    - -
    -
    coder.xml
    -
    Associate an image format with the specified coder module. - - ImageMagick has a number of coder modules to support the reading and/or writing of an image format (e.g. JPEG). Some coder modules support more than one associated image format and the mapping between an associated format and its respective coder module is defined in this configuration file. For example, the PNG coder module not only supports the PNG image format, but the JNG and MNG formats as well. -
    - -
    colors.xml
    -
    Associate a color name with its red, green, blue, and alpha intensities. - - A number of command line options require a color parameter. It is often convenient to refer to a color by name (e.g. white) rather than by hex value (e.g. #fff). This file maps a color name to its equivalent red, green, blue, and alpha intensities (e.g. for white, red = 255, green = 255, blue = 255, and alpha = 0). -
    - -
    configure.xml
    -
    Set ImageMagick build parameters and system-wide environment variables (e.g. MAGICK_TEMPORARY_PATH). - As ImageMagick is built, a number of build parameters are saved to this configuration file. They include the version, release date, dependent delegate libraries, and quantum depth among others. -
    - -
    delegates.xml
    -
    Associate delegate programs with certain image formats. - - ImageMagick relies on a number of delegate programs to support certain image formats such as ufraw-batch to read raw camera formats or Ghostscript to read Postscript images. Use this configuration file to map an input or output format to an external delegate program. -
    - -
    english.xml
    -
    Associate message tags with English translations.
    - -
    francais.xml
    -
    Associate message tags with French translations.
    - -
    locale.xml
    -
    Associate message tags with a translation for your locale. - - ImageMagick has a number of informational, warning, and error messages that are represented as tags. Tags are short descriptions of a message such as - FileNotFound or MemoryAllocationFailed. This configuration file lists locales that have a translation for each tag recognized by ImageMagick. Currently only English and French translations are available in the english.xml and francais.xml configuration files. -
    - -
    log.xml
    -
    Configure logging parameters. - ImageMagick is capable of spewing copious amounts of informational or debugging statements. Use this file to configure how the information will appear in a log message and where you want the logging messages posted. -
    - -
    magic.xml
    -
    Associate an image format with a unique identifier. - Many image formats have identifiers that uniquely identify a particular image format. For example, the GIF image format always begins with GIF8 as the first 4 characters of the image. ImageMagick uses this information to quickly determine the type of image it is dealing with when it reads an image. -
    - -
    mime.xml
    -
    Associate an internet media type with a unique identifier. - Many files and data streams have identifiers that uniquely identify a -particular internet media type. For example, files in the "Corel Draw -drawing" format (mime type="application/vnd.corel-draw") are associated with -the filename pattern *.cdr, and also have an initial string of the -characters "CDRXvrsn". ImageMagick uses combinations of this information, -when available, to attempt to quickly determine the internet media type of a -file or data stream. -
    - -
    policy.xml
    -
    Configure ImageMagick policies. - By default any coder, delegate, filter, or file path is permitted. Use a policy to deny access to, for example, the MPEG video delegate, or permit reading images from a file system but deny writing to that same file system. Or use the resource policy to set resource limits. Policies are useful for multi-user servers that want to limit the overall impact ImageMagick has on the system. For example, to limit the maximum image size in memory to 100MB: - -
    -<policy domain="resource" name="area" value="100MB"/>
    -
    - -Any image larger than this area limit is cached to disk rather than memory. - -Use width to limit the maximum width of an image in pixels. Exceed this limit and an exception is thrown and processing stops. - -
    -<policy domain="resource" name="width" value="100MP"/>
    -
    - -To limit the elapsed time of any ImageMagick command to 5 minutes, use this policy: - -
    -<policy domain="resource" name="time" value="300"/>
    -
    -Define arguments for the memory, map, area, and disk resources with SI prefixes (.e.g 100MB). In addition, resource policies are maximums for each instance of ImageMagick (e.g. policy memory limit 1GB, the -limit 2GB option exceeds policy maximum so memory limit is 1GB).
    - -
    quantization-table.xml
    -
    Custom JPEG quantization tables. Activate with -define:q-table=quantization-table.xml.
    - -
    thresholds.xml
    -
    Set threshold maps for ordered posterized dither.
    - -
    type.xml
    -
    Configure fonts. - Define the font name, family, foundry, style, format, metrics, and glyphs for any font you want to use within ImageMagick. -
    - -
    type-ghostscript.xml
    -
    Configure Ghostscript fonts. - The Ghostscript package includes a number of fonts that can be accessed with ImageMagick. -
    - -
    type-windows.xml
    -
    Associate names with Windows font glyphs.
    -
    - -

    Under Unix and Linux, ImageMagick searches for each of the configuration files listed above by looking in the locations given below, in order, and loads them if found:

    - -
    -$MAGICK_CONFIGURE_PATH
    -$PREFIX/etc/ImageMagick-7 
    -$PREFIX/share/ImageMagick-7 
    -$XDG_CACHE_HOME/ImageMagick
    -$HOME/.config/ImageMagick/
    -<client path>/etc/ImageMagick/
    -
    - -

    The environmental variable $PREFIX is the default install path (e.g. /usr/local). The client path is the execution path of your ImageMagick client (e.g. /usr/local) .

    - -

    For the Unix or Linux pre-compiled uninstalled binary distributions, the configuration load order is:

    - -
    -$MAGICK_CONFIGURE_PATH
    -$MAGICK_HOME/etc/ImageMagick
    -$MAGICK_HOME/share/ImageMagick-7.0.0 
    -$PREFIX/share/ImageMagick-7.0.0 
    -$XDG_CACHE_HOME/ImageMagick
    -$HOME/.config/ImageMagick/
    -<client path>/etc/ImageMagick/
    -<current directory>
    -
    - -

    Under Windows, ImageMagick searches for these configuration files in the following order, and loads them if found:

    - -
    -$MAGICK_CONFIGURE_PATH
    -<windows registry>
    -$PREFIX/config
    -$USERPROFILE/.config/ImageMagick/
    -<client path>
    -
    - -

    Above, $PREFIX is the default install path, typically c:\\Program Files\\ImageMagick-7.0.0.

    - -

    For an uninstalled Windows installation, the configuration load order is:

    - -
    -$MAGICK_CONFIGURE_PATH
    -$MAGICK_HOME
    -$USERPROFILE/.config/ImageMagick/
    -client path
    -<current directory>
    -
    - -

    If a configuration file cannot not be found, ImageMagick relies on built-in default values.

    - -

    Modules

    - -

    Coders

    -

    An image coder (i.e. encoder / decoder) is responsible for registering, optionally classifying, optionally reading, optionally writing, and unregistering one image format (e.g. PNG, GIF, JPEG, etc.). ImageMagick searches for coders in the following order and it uses the first match found:

    - -
    -$MAGICK_HOME/lib/ImageMagick-7.0.0/modules-Q16/coders/
    -<client path>/../lib/ImageMagick-7.0.0/modules-Q16/coders/
    -$MAGICK_HOME/lib/ImageMagick-7.0.0/modules-Q16/coders
    -$MAGICK_HOME/share/ImageMagick-7.0.0/modules-Q16/coders
    -$XDG_CACHE_HOME/ImageMagick
    -$HOME/.config/ImageMagick/
    -<client path>/lib/ImageMagick-7.0.0/modules-Q16/coders
    -
    - -

    Filters

    -

    ImageMagick provides a convenient mechanism for adding your own custom image processing algorithms. ImageMagick searches for filters in the following order and it uses the first match found:

    -
    -$MAGICK_HOME/lib/ImageMagick-7.0.0/modules-Q16/filters/
    -<client path>/../lib/ImageMagick-7.0.0/modules-Q16/filters/
    -$MAGICK_HOME/lib/ImageMagick-7.0.0/modules-Q16/filters
    -$MAGICK_HOME/share/ImageMagick-7.0.0/modules-Q16/filters
    -$XDG_CACHE_HOME/ImageMagick
    -$HOME/.config/ImageMagick/
    -<client path>/lib/ImageMagick-7.0.0/modules-Q16/filters
    -
    - -

    Fonts

    - -

    ImageMagick is able to load raw TrueType and Postscript font files. It searches for the font configuration file, type.xml, in the following order, and loads them if found:

    - -
    -$MAGICK_CONFIGURE_PATH
    -$MAGICK_HOME/etc/ImageMagick/
    -$MAGICK_HOME/share/ImageMagick-7.0.0/
    -$XDG_CACHE_HOME/ImageMagick
    -$HOME/.config/ImageMagick/
    -<client path>/etc/ImageMagick/
    -$MAGICK_FONT_PATH
    -
    - -

    Environment Variables

    - -

    Environment variables recognized by ImageMagick include:

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    HOMESet path to search for configuration files in $HOME/.config/ImageMagick if the directory exists.
    LD_LIBRARY_PATHSet path to the ImageMagick shareable libraries and other dependent libraries.
    MAGICK_AREA_LIMITSet the maximum width * height of an image that can reside in the pixel cache memory. Images that exceed the area limit are cached to disk (see MAGICK_DISK_LIMIT) and optionally memory-mapped.
    MAGICK_CODER_FILTER_PATHSet search path to use when searching for filter process modules (invoked via -process). This path permits the user to extend ImageMagick's image processing functionality by adding loadable modules to a preferred location rather than copying them into the ImageMagick installation directory. The formatting of the search path is similar to operating system search paths (i.e. colon delimited for Unix, and semi-colon delimited for Microsoft Windows). This user specified search path is searched before trying the default search path.
    MAGICK_CODER_MODULE_PATHSet path where ImageMagick can locate its coder modules. This path permits the user to arbitrarily extend the image formats supported by ImageMagick by adding loadable coder modules from an preferred location rather than copying them into the ImageMagick installation directory. The formatting of the search path is similar to operating system search paths (i.e. colon delimited for Unix, and semi-colon delimited for Microsoft Windows). This user specified search path is searched before trying the default search path.
    MAGICK_CONFIGURE_PATHSet path where ImageMagick can locate its configuration files. Use this search path to search for configuration (.xml) files. The formatting of the search path is similar to operating system search paths (i.e. colon delimited for Unix, and semi-colon delimited for Microsoft Windows). This user specified search path is searched before trying the default search path.
    MAGICK_DEBUGSet debug options. See -debug for a description of debugging options.
    MAGICK_DISK_LIMITSet maximum amount of disk space in bytes permitted for use by the pixel cache. When this limit is exceeded, the pixel cache is not be created and an error message is returned.
    MAGICK_ERRORMODESet the process error mode (Windows only). A typical use might be a value of 1 to prevent error mode dialogs from displaying a message box and hanging the application.
    MAGICK_FILE_LIMITSet maximum number of open pixel cache files. When this limit is exceeded, any subsequent pixels cached to disk are closed and reopened on demand. This behavior permits a large number of images to be accessed simultaneously on disk, but with a speed penalty due to repeated open/close calls.
    MAGICK_FONT_PATHSet path ImageMagick searches for TrueType and Postscript Type1 font files. This path is only consulted if a particular font file is not found in the current directory.
    MAGICK_HEIGHT_LIMITSet the maximum height of an image.
    MAGICK_HOMESet the path at the top of ImageMagick installation directory. This path is consulted by uninstalled builds of ImageMagick which do not have their location hard-coded or set by an installer.
    MAGICK_MAP_LIMITSet maximum amount of memory map in bytes to allocate for the pixel cache. When this limit is exceeded, the image pixels are cached to disk (see MAGICK_DISK_LIMIT).
    MAGICK_MEMORY_LIMITSet maximum amount of memory in bytes to allocate for the pixel cache from the heap. When this limit is exceeded, the image pixels are cached to memory-mapped disk (see MAGICK_MAP_LIMIT).
    MAGICK_OCL_DEVICESet to off to disable hardware acceleration of certain accelerated algorithms (e.g. blur, convolve, etc.).
    MAGICK_PRECISIONSet the maximum number of significant digits to be printed.
    MAGICK_SHRED_PASSESIf you want to keep the temporary files ImageMagick creates private, overwrite them with zeros or random data before they are removed. On the first pass, the file is zeroed. For subsequent passes, random data is written.
    MAGICK_SYNCHRONIZESet to "true" to ensure all image data is fully flushed and synchronized to disk. There is a performance penalty, however, the benefits include ensuring a valid image file in the event of a system crash and early reporting if there is not enough disk space for the image pixel cache.
    MAGICK_TEMPORARY_PATHSet path to store temporary files.
    MAGICK_THREAD_LIMITSet maximum parallel threads. Many ImageMagick algorithms run in parallel on multi-processor systems. Use this environment variable to set the maximum number of threads that are permitted to run in parallel.
    MAGICK_THROTTLEPeriodically yield the CPU for at least the time specified in milliseconds.
    MAGICK_TIME_LIMITSet maximum time in seconds. When this limit is exceeded, an exception is thrown and processing stops.
    MAGICK_WIDTH_LIMITSet the maximum width of an image.
    - -

    Define arguments for the MAGICK_AREA_LIMIT, MAGICK_DISK_LIMIT, MAGICK_MAP_LIMIT, and MAGICK_MEMORY_LIMIT environment variables with SI prefixes (.e.g 100MB). MAGICK_WIDTH_LIMIT and MAGICK_HEIGHT_LIMIT accepts pixel suffixes such as MP for mega-pixels (e.g. 100MP).

    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/search.html b/ImageMagick-7.0.0-0/www/search.html deleted file mode 100644 index 93f0a4bf6..000000000 --- a/ImageMagick-7.0.0-0/www/search.html +++ /dev/null @@ -1,108 +0,0 @@ - - - - - - - - - ImageMagick: Search - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    -
    - - ImageMagick Search - - - - - - - - - - - - - -
    - - - - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/sitemap.html b/ImageMagick-7.0.0-0/www/sitemap.html deleted file mode 100644 index aee4b4284..000000000 --- a/ImageMagick-7.0.0-0/www/sitemap.html +++ /dev/null @@ -1,229 +0,0 @@ - - - - - - - - - ImageMagick: Site Map - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    ImageMagick Overview • Download ImageMagick • Install ImageMagick • Command-line Tools • Program Interfaces • Image Formats • Getting Help • Support ImageMagick • Miscellaneous Topics

    - -

    Use this ImageMagick sitemap to quickly jump to one of the areas of interest listed below. If you can't find what you want on this page, try our site search.

    - -

    ImageMagick Overview

    - -
    -
  • Introduction: convert, edit, or compose images from the command-line or program interface.
  • -
  • Examples of ImageMagick usage: a few examples that show what you can do with an image using ImageMagick.
  • -
  • Anthony Thyssen's examples of ImageMagick usage: a comprehensive tutorial of using ImageMagick from the command line.
  • -
  • Color names: how to specify a color name, a hex color, or a numerical RGB, RGBA, HSL, HSLA, CMYK, or CMYKA color.
  • -
  • Color management: accurate color management with color profiles or in lieu of-- built-in gamma compression or expansion as demanded by the colorspace.
  • -
  • Resources: ImageMagick depends on external resources including configuration files, loadable modules, fonts, and environment variables.
  • -
  • Parallel execution: ImageMagick is threaded to take advantage of speed-ups offered by the multicore processor chips.
  • -
  • Architecture: get to know more about the software and algorithms behind ImageMagick.
  • -
  • License: the legally binding and authoritative terms and conditions for use, reproduction, and distribution of ImageMagick.
  • -
  • Export classification: export control status of ImageMagick.
  • -
  • ImageMagick version 7: ImageMagick version 7 is in development, learn how it differs from previous versions.
  • -
  • History: how ImageMagick was conceived and developed.
  • -
    - -

    Download ImageMagick

    - -
    -
  • Download ImageMagick: ImageMagick source and binary distributions are available from a variety of FTP and Web mirrors.
  • -
  • -
  • Unix source: Unix source distributions.
  • -
  • Windows source: Windows source distributions.
  • -
  • Unix and Windows binaries: Unix and Windows binary distributions.
  • -
  • Git repository: stable and development source releases.
  • -
  • MagickWand for PHP: a native PHP-extension to the ImageMagick MagickWand API.
  • -
  • Delegate libraries: ImageMagick depends on a number of optional delegate libraries to extend its functionality.
  • -
  • -
    - -

    Install ImageMagick

    - -

    You can install ImageMagick from source. However, if don't have a proper development environment or if you're anxious to get started, download a ready-to-run Unix or Windows executable.

    -
    -
  • Install from source: ImageMagick builds under Windows, Mac OS X, and Linux.
  • -
  • Install from a binary distribution: install a ready-to-run Unix or Windows executable.
  • -
  • Install ImageMagickObject COM+ component: install the Windows ImageMagick COM+ component.
  • -
    - -

    Command-line Tools

    -
    -
  • Command-line tools: overview of the ImageMagick commands.
  • -
  • -
  • animate: animates an image sequence on any X server.
  • -
  • compare: mathematically and visually annotate the difference between an image and its reconstruction.
  • -
  • composite: overlaps one image over another.
  • -
  • conjure: interprets and executes scripts written in the Magick Scripting Language (MSL).
  • -
  • convert: convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and more.
  • -
  • display: displays an image or image sequence on any X server.
  • -
  • identify: describes the format and characteristics of one or more image files.
  • -
  • import: saves any visible window on an X server and outputs it as an image file.
  • -
  • mogrify: resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and more.
  • -
  • montage: create a composite image by combining several separate images.
  • -
  • stream: a lightweight tool to stream one or more pixel components of the image or portion of the image to your choice of storage formats.
  • -
  • -
  • Command line processing: the anatomy of the command line.
  • -
  • Command line options: annotated list of all options that can appear on the command-line.
  • -
  • Fx: apply a mathematical expression to an image or image channels.
  • -
  • Fred's ImageMagick Scripts: a plethora of command-line scripts that perform geometric transforms, blurs, sharpens, edging, noise removal, and color manipulations.
  • -
    - -

    Program Interfaces

    - -
    -
  • Program interfaces: application programming interfaces.
  • -
  • -
  • ChMagick: is a Ch an embeddable MagickCore C/C++ interpreter for cross-platform scripting.
  • -
  • CL-Magick: provides a Common Lisp interface to the ImageMagick library.
  • -
  • G2F: implements an Ada 95 binding to a subset of the low-level MagickCore library.
  • -
  • Magick++: provides an object-oriented C++ interface to ImageMagick.
  • -
  • IMagick: is a native PHP extension to create and modify images using the ImageMagick API.
  • -
  • JMagick: provides an object-oriented Java interface to ImageMagick.
  • -
  • MagickCore: C API, recommended for wizard-level developers.
  • -
  • MagickWand: convert, compose, and edit images from the C language.
  • -
  • MagickWand for PHP: a native PHP-extension to the ImageMagick MagickWand API.
  • -
  • nMagick: is a port of the ImageMagick library to the haXe and Neko platforms.
  • -
  • PascalMagick: a Pascal binding for the MagickWand API and also the low-level MagickCore library.
  • -
  • PerlMagick: convert, compose, and edit images from the Perl language.
  • -
  • PythonMagick: an object-oriented Python interface to ImageMagick.
  • -
  • RMagick: is an interface between the Ruby programming language and ImageMagick.
  • -
  • TclMagick: a native Tcl-extension to the ImageMagick MagickWand API.
  • -
  • -
    - -

    Image Formats

    -
    -
  • Supported image formats: annotated list of all image formats that ImageMagick can read and/or write.
  • -
  • Motion picture digital images: use SMPTE DPX Version 2.0 to process images used by the motion picture (film and high-definition) industry.
  • -
  • High dynamic-range images: accurately represent the wide range of intensity levels found in real scenes ranging from the brightest direct sunlight to the deepest darkest shadows.
  • -
  • Magick Vector Graphics: a modularized language for describing two-dimensional vector and mixed vector/raster graphics in ImageMagick.
  • -
  • Magick Image File Format: MIFF is ImageMagick's own platform-independent format for storing bitmap images.
  • -
    - -

    Getting Help

    - -
    -
  • Definitive Guide to ImageMagick: this book explains ImageMagick in a practical, learn-by-example fashion.
  • -
  • ImageMagick Tricks: this book is packed with examples of photo manipulations, logo creation, animations, and complete web projects.
  • -
  • Discourse server: get help from fellow ImageMagick users and developers, post to these forums.
  • -
  • Contact the Wizards: for bug reports (only if you do not want to sign up to the discourse server), a source or documentation patch, a security or license issue, or if you want to be a sponsor of the ImageMagick project.
  • -
    - -

    Support ImageMagick

    - -
    -
  • Report bugs and vulnerabilities: our highest priority is to fix security defects and bug reports, usually within 48 hours of your report. The bug discourse server requires that you register. If you do not want to register, you can contact the ImageMagick developers with a convenient web form.
  • -
  • Sponsor ImageMagick: contribute bug fixes, enhancements, hardware, funds, etc. to ensure the ImageMagick project thrives.
  • -
    - -

    Miscellaneous Topics

    - -
    -
  • Animation: create a GIF animation sequence from a group of images.
  • -
  • Canny edge detection: extract edges from an image using the Canny technique.
  • -
  • Color management: accurate color management with color profiles or in lieu of-- built-in gamma compression or expansion as demanded by the colorspace.
  • -
  • Command-line processing: utilize ImageMagick from the command line.
  • -
  • Connected Component Labeling: uniquely label connected regions in an image.
  • -
  • Composite: overlap one image over another.
  • -
  • Connected Component Labeling: uniquely label connected regions in an image.
  • -
  • Decorate: add a border or frame to an image.
  • -
  • Discrete Fourier transform: implements the forward and inverse DFT.
  • -
  • Distributed pixel cache: offload intermediate pixel storage to one or more remote servers .
  • -
  • Draw: add shapes or text to an image.
  • -
  • Encipher or decipher an image: convert ordinary images into unintelddgible gibberish and back again.
  • -
  • Escapes: utilize percent escapes in a number of options, for example in -format or in montage -label, to print various properties and other settings associated with an - image.
  • -
  • Format conversion: convert an image from one format to another (e.g. PNG to JPEG).
  • -
  • Generalized pixel distortion: correct for, or induce image distortions including perspective.
  • -
  • Heterogeneous distributed processing: certain algorithms are OpenCL-enabled to take advantage of speed-ups offered by executing in concert across heterogeneous platforms consisting of CPUs, GPUs, and other processors.
  • -
  • High dynamic-range images: accurately represent the wide range of intensity levels found in real scenes ranging from the brightest direct sunlight to the deepest darkest shadows.
  • -
  • Hough lines: fit straight lines to edges in an image using the Hough transform technique.
  • -
  • Image calculator: apply a mathematical expression to an image or image channels.
  • -
  • Image gradients: create a gradual blend of two colors whose shape is horizontal, vertical, circular, or elliptical.
  • -
  • Image identification: describe the format and attributes of an image.
  • -
  • ImageMagick on the iPhone: convert, edit, or compose images on your iPhone.
  • -
  • Kuwahara Filter: apply an edge perserving noise and color reduction filter to an image.
  • -
  • Large image support: read, process, or write mega-, giga-, or tera-pixel image sizes.
  • -
  • Mean-shift: apply a color reduction technique to an image.
  • -
  • Montage: juxtapose image thumbnails on an image canvas.
  • -
  • Morphology of shapes: extract features, describe shapes and recognize patterns in images.
  • -
  • Motion picture support: read and write the common image formats used in digital film work.
  • -
  • Special effects: blur, sharpen, threshold, or tint an image.
  • -
  • Text & comments: insert descriptive or artistic text in an image.
  • -
  • Threads of execution support: ImageMagick is thread safe and most internal algorithms execute in parallel to take advantage of speed-ups offered by multicore processor chips.
  • -
  • Transform: resize, rotate, crop, or trim an image.
  • -
  • Transparency: render portions of an image invisible.
  • -
  • Virtual pixel support: convenient access to pixels outside the image region.
  • -
    -
    - - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/sponsors.html b/ImageMagick-7.0.0-0/www/sponsors.html deleted file mode 100644 index 18fdcc9b8..000000000 --- a/ImageMagick-7.0.0-0/www/sponsors.html +++ /dev/null @@ -1,49 +0,0 @@ - - - - - ImageMagick: Sponsors - - - - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    diff --git a/ImageMagick-7.0.0-0/www/stream.html b/ImageMagick-7.0.0-0/www/stream.html deleted file mode 100644 index 93a25e88e..000000000 --- a/ImageMagick-7.0.0-0/www/stream.html +++ /dev/null @@ -1,268 +0,0 @@ - - - - - - - - - ImageMagick: Command-line Tools: Stream - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Example Usage • Option Summary

    - -

    Stream is a lightweight tool to stream one or more pixel components of the image or portion of the image to your choice of storage formats. It writes the pixel components as they are read from the input image a row at a time making stream desirable when working with large images or when you require raw pixel components.

    - -

    Example Usage

    - -

    We list a few examples of the stream command here to illustrate its usefulness and ease of use. To get started, lets stream the red, green, blue components of a 640x480 JPEG image to disk as unsigned characters:

    - -
    -stream -map rgb -storage-type char image.jpg pixels.dat
    -display -depth 8 -size 640x480 rgb:pixels.dat
    -
    - -

    Here we extract a 100x100 region from a TIFF image in the grayscale format as doubles:

    - -
    -stream -map i -storage-type double -extract 100x100+30+40 image.tif gray.raw
    -
    - -

    You can also associate the region to extract with the image filename:

    - -
    -stream -map i -storage-type double 'image.tif[100x100+30+40]' gray.raw
    -
    - - -

    Option Summary

    - -

    The stream command recognizes these options. Click on an option to get more details about how that option works.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    OptionDescription
    -authenticate valuedecrypt image with this password
    -channel typeapply option to select image channels
    -colorspace typeset image colorspace
    -debug eventsdisplay copious debugging information
    -define format:optiondefine one or more image format options
    -density geometryhorizontal and vertical density of the image
    -depth valueimage depth
    -extract geometryextract area from image
    -helpprint program options
    -interlace typetype of image interlacing scheme
    -interpolate methodpixel color interpolation method
    -limit type valuepixel cache resource limit
    -list typeColor, Configure, Delegate, Format, Magic, Module, Resource, or Type
    -log formatformat of debugging information
    -map componentsstore pixels in this format.
    -monitormonitor progress
    -quantize colorspacereduce image colors in this colorspace
    -quietsuppress all warning messages
    -regard-warningspay attention to warning messages.
    -respect-parenthesessettings remain in effect until parenthesis boundary.
    -sampling-factor geometryhorizontal and vertical sampling factor
    -seed valueseed a new sequence of pseudo-random numbers
    -set attribute valueset an image attribute
    -size geometrywidth and height of image
    -storage-type typestore pixels with this storage type.
    -synchronizesynchronize image to storage device
    -taintmark the image as modified
    -transparent-color colortransparent color
    -verboseprint detailed information about the image
    -versionprint version information
    -virtual-pixel methodaccess method for pixels outside the boundaries of the image
    - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/support.html b/ImageMagick-7.0.0-0/www/support.html deleted file mode 100644 index 0a9a3a029..000000000 --- a/ImageMagick-7.0.0-0/www/support.html +++ /dev/null @@ -1,151 +0,0 @@ - - - - - - - - - ImageMagick: Support ImageMagick Development - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    Contribute a Bug Fix or Enhancement • Support the ImageMagick Project

    - - - - -

    We want to thank the following sponsors of the ImageMagick project, including:

    - -
    -
    [Network Redux] We manage everything so you don't have to.

    -
    [TransloadIt] The world's most versatile file uploading and processing service

    -
    -
    - -

    Contribute a Bug Fix or Enhancement

    -

    Post any ImageMagick patches to the Issues forum if you think you have found and fixed a bug or security vulnerability. Post to the Developers forum if you want to propose an enhancement for discussion.

    - -

    Support the ImageMagick Project

    - -

    ImageMagick has been available for free since the early 1990's. It has consistently been one of the most comprehensive free image processing packages available, but, unlike competing packages, it continues to be supported and enhanced. Today, ImageMagick is more comprehensive and better supported than ever.

    -

    ImageMagick has enjoyed considerable support from commercial users. Since ImageMagick is not restricted from use in commercial or proprietary applications, it is used to support thousands of commercial web sites and is used in professional digital image and movie studios as well as publishing shops. It is also used as a component of a number of commercial applications. Many of these commercial users have made contributions to ImageMagick, large and small, often anonymous, but always appreciated.

    -

    ImageMagick Studio LLC is looking for support from individuals or companies that use ImageMagick, or would like to help support free software. If you or your company depends on ImageMagick, supporting ImageMagick is a way to express your gratitude and to contribute back to the further development of ImageMagick.

    -

    ImageMagick support can take many forms. The following are some possibilities:

    -
      -
    • Contribute source code or patches to help improve ImageMagick.
    • -
    • Send us a licensed copy of Microsoft Visual Studio 2015.
    • -
    • Send us a licensed copy of Adobe Photoshop.
    • -
    • Lend us developers to add support for additional image formats or to finish integrating support for the SVG specification.
    • -
    • Extend our FFT algorithm to support non-square images.
    • -
    • Port our Unix build environment from Autoconf / Automake to CMake.
    • -
    • Provide technical writers to assist with the development of commercial-grade technical documentation.
    • -
    • Donate a quality SWOP or Eurostandard ICC profile to use as a default CMYK to RGB conversion profile.
    • -
    • Donate a workstation with a modern processor and plenty of memory and disk. We would use it for our primary development environment.
    • -
    • Donate an Apple Macbook Pro or desktop so we can build and test ImageMagick in the Apple Development environment.
    • -
    • Make a monetary contribution:
    - -

    Donations can be anonymous, or public.

    -
    -Support the ImageMagick Project -

    Paypal

    -

    For direct monetary contributions, click on the donate button to contribute thru Paypal or with a credit card:

    - -
      -
      - - - -
      -
    - -

    Flattr

    -

    Flattr is a microdonation system. You donate a small amount every month and - click Flattr buttons on worthy sites to share the donation among those sites, similar to a tip jar (for more details see Wikipedia's Flattr article).

    -
      -
      Flattr this -
      -
    -

    Litecoin

    -

    Our Litecoin Address is: LcZLAmym4EMvUPc9koagkccRLYQbsgGwmj. Or you can reference the below QR code:

    -
      -
      Click to Donate to ImageMagick via Litecoin
      -
    -

    Check

    -

    Check, in USD funds, made payable to - ImageMagick Studio LLC, and send to:

    -
      -
      -ImageMagick Studio LLC
      -P.O. Box 40
      -Landenberg, PA  19350
      -USA
      -
      -
    -
    -
    -

    If you prefer a recurring subscription or if you have any questions about supporting ImageMagick, please contact us. -

    - - -
    - -
    - - - -
    - - diff --git a/ImageMagick-7.0.0-0/www/webp.html b/ImageMagick-7.0.0-0/www/webp.html deleted file mode 100644 index 2f9aa88f0..000000000 --- a/ImageMagick-7.0.0-0/www/webp.html +++ /dev/null @@ -1,178 +0,0 @@ - - - - - - - - - ImageMagick: WebP Encoding Options - - - - - - - - - - - - - - - - - - - - -
    -
    -
    - - - -
    -
    -
    -
    -

    ImageMagick's WebP image format accepts a plethora of encoding options as detailed below. As an example, suppose you are interested in these options:

    - -
      -
    • quality of 50
    • -
    • lossless compression
    • -
    - -

    Use this command:

    - -
    -convert wizard.png -quality 50 -define webp:lossless=true wizard.webp
    -
    - -

    Here is a complete list of WebP encoding options:

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    alpha-compression=valueencode the alpha plane: 0 = none, 1 = compressed.
    alpha-filtering=valuepredictive filtering method for alpha plane: 0=none, 1=fast, 2=best.
    alpha-quality=valuethe compression value for alpha compression between 0 and 100. Lossless compression of alpha is achieved using a value of 100, while the lower values result in a lossy compression. The default is 100.
    auto-filter=true, falsewhen enabled, the algorithm spends additional time optimizing the filtering strength to reach a well-balanced quality.
    emulate-jpeg-size=true, falsereturn a similar compression to that of JPEG but with less degradation.
    filter-sharpness=valuefilter sharpness.
    filter-strength=valuethe strength of the deblocking filter, between 0 (no filtering) and 100 (maximum filtering). A value of 0 turns off any filtering. Higher values increase the strength of the filtering process applied after decoding the image. The higher the value, the smoother the image appears. Typical values are usually in the range of 20 to 50.
    filter-type=valuefilter type: 0 = simple, 1 = strong
    image-hint=default, photo, picture, graphthe hint about the image type.
    lossless=true, falseencode the image without any loss.
    low-memory=true, falsereduce memory usage.
    method=valuethe compression method to use. It controls the trade off between encoding speed and the compressed file size and quality. Possible values range from 0 to 6. Default value is 4. When higher values are utilized, the encoder spends more time inspecting additional encoding possibilities and decide on the quality gain. Lower value might result in faster processing time at the expense of larger file size and lower compression quality.
    preprocessing=valueChoose from: 0=none, 1=segment-smooth, 2=pseudo-random dithering.
    partitions=valueprogressive decoding: choose 0 to 3.
    partition-limit=valueChoose 0 for no quality degradation and 100 for maximum degradation.
    pass=valuemaximum number of passes to target compression size or PSNR.
    segment=valueChoose from 1 to 4, the maximum numbher of segments to use.
    show-compressed=true, false
    sns-strength=valuethe amplitude of the spatial noise shaping. Spatial noise shaping (SNS) refers to a general collection of built-in algorithms used to decide which area of the picture should use relatively less bits, and where else to better transfer these bits. The possible range goes from 0 (algorithm is off) to 100 (the maximal effect). The default value is 80.
    target-size=valuea target size (in bytes) to try and reach for the compressed output. The compressor makes several passes of partial encoding in order to get as close as possible to this target.
    target-psnr=valuedesired minimal distortion.
    thread-level=valueenable multi-threaded encoding.
    -
    - -
    - - - -
    - - diff --git a/Makefile.in b/Makefile.in index 1213c929f..870c43876 100644 --- a/Makefile.in +++ b/Makefile.in @@ -4956,15 +4956,14 @@ UTILITIES_CONFIGURE = \ utilities/montage.1.in \ utilities/stream.1.in -MAGICK_UTILITIES = animate compare composite conjure display identify import magick-script mogrify montage stream UTILITIES_EXTRA_DIST = \ - $(MAGICK_UTILITIES) \ $(UTILITIES_MANS) \ $(UTILITIES_TESTS) UTILITIES_CLEANFILES = # Link these utilities to 'magick'. +MAGICK_UTILITIES = animate compare composite conjure display identify import magick-script mogrify montage stream UTILITIES_INSTALL_EXEC_LOCAL_TARGETS = install-exec-local-utilities UTILITIES_UNINSTALL_LOCAL_TARGETS = uninstall-local-utilities diff --git a/common.shi.in b/common.shi.in index 46e66efa2..fdb8a43c2 100644 --- a/common.shi.in +++ b/common.shi.in @@ -3,14 +3,14 @@ top_srcdir='@abs_top_srcdir@' top_builddir='@abs_top_builddir@' set -a -COMPARE="@abs_top_builddir@/utilities/compare" -COMPOSITE="@abs_top_builddir@/utilities/composite" -CONJURE="@abs_top_builddir@/utilities/conjure" -CONVERT="@abs_top_builddir@/utilities/convert" -DISPLAY="@abs_top_builddir@/utilities/display" -IDENTIFY="@abs_top_builddir@/utilities/identify" +COMPARE="@abs_top_builddir@/utilities/magick compare" +COMPOSITE="@abs_top_builddir@/utilities/magick composite" +CONJURE="@abs_top_builddir@/utilities/magick conjure" +CONVERT="@abs_top_builddir@/utilities/magick convert" +DISPLAY="@abs_top_builddir@/utilities/magick display" +IDENTIFY="@abs_top_builddir@/utilities/magick identify" MAGICK="@abs_top_builddir@/utilities/magick" -MONTAGE="@abs_top_builddir@/utilities/montage" +MONTAGE="@abs_top_builddir@/utilities/magick montage" VALIDATE="@abs_top_builddir@/tests/validate" DRAWTEST="@abs_top_builddir@/tests/drawtest" WANDTEST="@abs_top_builddir@/tests/wandtest" diff --git a/configure b/configure index 6bb1d93e9..fe2a32544 100755 --- a/configure +++ b/configure @@ -4523,7 +4523,7 @@ MAGICK_PATCHLEVEL_VERSION=0 MAGICK_VERSION=7.0.0-0 -MAGICK_GIT_REVISION=17940:33ce5a3:20160401 +MAGICK_GIT_REVISION=17941:39da8e7:20160401 # Substitute library versioning diff --git a/utilities/Makefile.am b/utilities/Makefile.am index 135cc0b5a..e9cdcd4b2 100644 --- a/utilities/Makefile.am +++ b/utilities/Makefile.am @@ -55,16 +55,16 @@ UTILITIES_CONFIGURE = \ utilities/montage.1.in \ utilities/stream.1.in -MAGICK_UTILITIES=animate compare composite conjure display identify import magick-script mogrify montage stream UTILITIES_EXTRA_DIST = \ - $(MAGICK_UTILITIES) \ $(UTILITIES_MANS) \ $(UTILITIES_TESTS) UTILITIES_CLEANFILES = # Link these utilities to 'magick'. +MAGICK_UTILITIES=animate compare composite conjure display identify import magick-script mogrify montage stream + UTILITIES_INSTALL_EXEC_LOCAL_TARGETS=install-exec-local-utilities install-exec-local-utilities: $(mkdir_p) $(DESTDIR)$(bindir) diff --git a/utilities/animate b/utilities/animate deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/animate +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/compare b/utilities/compare deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/compare +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/composite b/utilities/composite deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/composite +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/conjure b/utilities/conjure deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/conjure +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/convert b/utilities/convert deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/convert +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/display b/utilities/display deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/display +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/identify b/utilities/identify deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/identify +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/import b/utilities/import deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/import +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/magick-script b/utilities/magick-script deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/magick-script +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/magick.c b/utilities/magick.c index 5b03e7519..0c2d38461 100644 --- a/utilities/magick.c +++ b/utilities/magick.c @@ -115,6 +115,17 @@ static int MagickMain(int argc,char **argv) MagickCommands[i].extent); if (offset == 0) break; + if (argc > 1) + { + offset=LocaleNCompare(MagickCommands[i].name,argv[1], + MagickCommands[i].extent); + if (offset == 0) + { + argc--; + argv++; + break; + } + } } i%=(sizeof(MagickCommands)/sizeof(MagickCommands[0])); status=MagickCommandGenesis(image_info,MagickCommands[i].command,argc,argv, diff --git a/utilities/mogrify b/utilities/mogrify deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/mogrify +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/montage b/utilities/montage deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/montage +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file diff --git a/utilities/stream b/utilities/stream deleted file mode 120000 index 2e0026488..000000000 --- a/utilities/stream +++ /dev/null @@ -1 +0,0 @@ -magick \ No newline at end of file