From: cristy Date: Sat, 10 Sep 2011 02:10:07 +0000 (+0000) Subject: (no commit message) X-Git-Tag: 7.0.1-0~7036 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6435bd963ca7d67d62eaf024e0f3d8a40ec47d0d;p=imagemagick --- diff --git a/MagickCore/effect.c b/MagickCore/effect.c index dace1f17f..aaa9325c2 100644 --- a/MagickCore/effect.c +++ b/MagickCore/effect.c @@ -2832,7 +2832,7 @@ MagickExport Image *PreviewImage(const Image *image,const PreviewType preview, % The format of the RadialBlurImage method is: % % Image *RadialBlurImage(const Image *image,const double angle, -% ExceptionInfo *exception) +% const double blur,ExceptionInfo *exception) % % A description of each parameter follows: % @@ -2840,11 +2840,13 @@ MagickExport Image *PreviewImage(const Image *image,const PreviewType preview, % % o angle: the angle of the radial blur. % +% o blur: the blur. +% % o exception: return any errors or warnings in this structure. % */ MagickExport Image *RadialBlurImage(const Image *image, - const double angle,ExceptionInfo *exception) + const double angle,const double bias,ExceptionInfo *exception) { CacheView *blur_view, @@ -2859,9 +2861,6 @@ MagickExport Image *RadialBlurImage(const Image *image, MagickOffsetType progress; - PixelInfo - bias; - MagickRealType blur_radius, *cos_theta, @@ -2924,7 +2923,6 @@ MagickExport Image *RadialBlurImage(const Image *image, */ status=MagickTrue; progress=0; - GetPixelInfo(image,&bias); image_view=AcquireCacheView(image); blur_view=AcquireCacheView(blur_image); #if defined(MAGICKCORE_OPENMP_SUPPORT) @@ -2983,7 +2981,11 @@ MagickExport Image *RadialBlurImage(const Image *image, step=n-1; } normalize=0.0; - qixel=bias; + qixel.red=bias; + qixel.green=bias; + qixel.blue=bias; + qixel.black=bias; + qixel.alpha=bias; if (((GetPixelAlphaTraits(image) & UpdatePixelTrait) == 0) || (image->matte == MagickFalse)) { diff --git a/MagickCore/effect.h b/MagickCore/effect.h index 295d58e3a..ac462de56 100644 --- a/MagickCore/effect.h +++ b/MagickCore/effect.h @@ -87,7 +87,7 @@ extern MagickExport Image *MotionBlurImage(const Image *,const double,const double,const double, const double,ExceptionInfo *), *PreviewImage(const Image *,const PreviewType,ExceptionInfo *), - *RadialBlurImage(const Image *,const double,ExceptionInfo *), + *RadialBlurImage(const Image *,const double,const double,ExceptionInfo *), *SelectiveBlurImage(const Image *,const double,const double,const double, ExceptionInfo *), *ShadeImage(const Image *,const MagickBooleanType,const double,const double, diff --git a/MagickCore/magick-config.h b/MagickCore/magick-config.h index efe979e75..1df0a4fa8 100644 --- a/MagickCore/magick-config.h +++ b/MagickCore/magick-config.h @@ -436,15 +436,15 @@ #endif /* Define if you have the header file. */ -#ifndef MAGICKCORE_HAVE_LCMS2_H -#define MAGICKCORE_HAVE_LCMS2_H 1 -#endif +/* #undef HAVE_LCMS2_H */ /* Define if you have the header file. */ /* #undef HAVE_LCMS2_LCMS2_H */ /* Define if you have the header file. */ -/* #undef HAVE_LCMS_H */ +#ifndef MAGICKCORE_HAVE_LCMS_H +#define MAGICKCORE_HAVE_LCMS_H 1 +#endif /* Define if you have the header file. */ /* #undef HAVE_LCMS_LCMS_H */ @@ -1167,7 +1167,9 @@ #endif /* Define if you have JBIG library */ -/* #undef JBIG_DELEGATE */ +#ifndef MAGICKCORE_JBIG_DELEGATE +#define MAGICKCORE_JBIG_DELEGATE 1 +#endif /* Define if you have JPEG version 2 "Jasper" library */ #ifndef MAGICKCORE_JP2_DELEGATE @@ -1196,7 +1198,9 @@ #endif /* Define if you have LQR library */ -/* #undef LQR_DELEGATE */ +#ifndef MAGICKCORE_LQR_DELEGATE +#define MAGICKCORE_LQR_DELEGATE 1 +#endif /* Define if using libltdl to support dynamically loadable modules */ #ifndef MAGICKCORE_LTDL_DELEGATE @@ -1208,7 +1212,7 @@ /* Define to the system default library search path. */ #ifndef MAGICKCORE_LT_DLSEARCH_PATH -#define MAGICKCORE_LT_DLSEARCH_PATH "/lib64:/usr/lib64:/lib:/usr/lib:/usr/lib64/R/lib:/usr/lib64/alliance/lib:/usr/lib64/atlas:/opt/modules/pkg/intel/f77/10.0.025/lib:/usr/lib64/kicad:/usr/lib/llvm:/usr/lib64/llvm:/usr/local/lib:/usr/lib64/mpich2/lib/:/usr/lib64/mysql:/usr/lib64/octave/3.4.2:/usr/lib64/openmotif:/usr/lib64/qt-3.3/lib:/usr/lib64/tcl8.5/tclx8.4:/usr/lib/wine/:/usr/lib64/wine/:/usr/lib64/xulrunner-2" +#define MAGICKCORE_LT_DLSEARCH_PATH "/lib64:/usr/lib64:/lib:/usr/lib:/usr/lib64/R/lib:/usr/lib64/atlas:/opt/modules/pkg/intel/f77/10.0.025/lib:/usr/lib64/llvm:/usr/local/lib:/usr/lib64/mysql:/usr/lib64/nvidia:/usr/lib64/qt-3.3/lib:/usr/lib64/xulrunner-2" #endif /* The archive extension */ @@ -1455,7 +1459,9 @@ /* Define if you have WEBP library */ -/* #undef WEBP_DELEGATE */ +#ifndef MAGICKCORE_WEBP_DELEGATE +#define MAGICKCORE_WEBP_DELEGATE 1 +#endif /* Define to use the Windows GDI32 library */ /* #undef WINGDI32_DELEGATE */ diff --git a/MagickWand/magick-image.c b/MagickWand/magick-image.c index a0a1fe31b..dcfbbfe98 100644 --- a/MagickWand/magick-image.c +++ b/MagickWand/magick-image.c @@ -7513,7 +7513,7 @@ WandExport MagickBooleanType MagickQuantizeImages(MagickWand *wand, % The format of the MagickRadialBlurImage method is: % % MagickBooleanType MagickRadialBlurImage(MagickWand *wand, -% const double angle) +% const double angle,const double bias) % % A description of each parameter follows: % @@ -7521,9 +7521,11 @@ WandExport MagickBooleanType MagickQuantizeImages(MagickWand *wand, % % o angle: the angle of the blur in degrees. % +% o bias: the bias. +% */ WandExport MagickBooleanType MagickRadialBlurImage(MagickWand *wand, - const double angle) + const double angle,const double bias) { Image *blur_image; @@ -7534,7 +7536,7 @@ WandExport MagickBooleanType MagickRadialBlurImage(MagickWand *wand, (void) LogMagickEvent(WandEvent,GetMagickModule(),"%s",wand->name); if (wand->images == (Image *) NULL) ThrowWandException(WandError,"ContainsNoImages",wand->name); - blur_image=RadialBlurImage(wand->images,angle,wand->exception); + blur_image=RadialBlurImage(wand->images,angle,bias,wand->exception); if (blur_image == (Image *) NULL) return(MagickFalse); ReplaceImageInList(&wand->images,blur_image); diff --git a/MagickWand/magick-image.h b/MagickWand/magick-image.h index b89e6eb43..23c3e7b9d 100644 --- a/MagickWand/magick-image.h +++ b/MagickWand/magick-image.h @@ -203,7 +203,7 @@ extern WandExport MagickBooleanType const size_t,const MagickBooleanType,const MagickBooleanType), MagickQuantizeImages(MagickWand *,const size_t,const ColorspaceType, const size_t,const MagickBooleanType,const MagickBooleanType), - MagickRadialBlurImage(MagickWand *,const double), + MagickRadialBlurImage(MagickWand *,const double,const double), MagickRaiseImage(MagickWand *,const size_t,const size_t,const ssize_t, const ssize_t,const MagickBooleanType), MagickRandomThresholdImage(MagickWand *,const double,const double), diff --git a/MagickWand/mogrify.c b/MagickWand/mogrify.c index 0120b22aa..bfcee2706 100644 --- a/MagickWand/mogrify.c +++ b/MagickWand/mogrify.c @@ -2359,8 +2359,9 @@ WandExport MagickBooleanType MogrifyImage(ImageInfo *image_info,const int argc, Radial blur image. */ (void) SyncImageSettings(mogrify_info,*image); - mogrify_image=RadialBlurImage(*image,InterpretLocaleValue(argv[i+1], - (char **) NULL),exception); + flags=ParseGeometry(argv[i+1],&geometry_info); + mogrify_image=RadialBlurImage(*image,geometry_info.rho, + geometry_info.sigma,exception); break; } if (LocaleCompare("raise",option+1) == 0) diff --git a/PerlMagick/Magick.xs b/PerlMagick/Magick.xs index 82ebb9abe..929f5e892 100644 --- a/PerlMagick/Magick.xs +++ b/PerlMagick/Magick.xs @@ -423,7 +423,7 @@ static struct { "WhiteThreshold", { {"threshold", StringReference}, {"channel", MagickChannelOptions} } }, { "RadialBlur", { {"geometry", StringReference}, {"angle", RealReference}, - {"channel", MagickChannelOptions} } }, + {"bias", RealReference}, {"channel", MagickChannelOptions} } }, { "Thumbnail", { {"geometry", StringReference}, {"width", IntegerReference}, {"height", IntegerReference} } }, { "Strip", }, @@ -9634,15 +9634,16 @@ Mogrify(ref,...) { flags=ParseGeometry(argument_list[0].string_reference, &geometry_info); - if ((flags & SigmaValue) == 0) - geometry_info.sigma=1.0; } if (attribute_flag[1] != 0) geometry_info.rho=argument_list[1].real_reference; if (attribute_flag[2] != 0) - channel=(ChannelType) argument_list[2].integer_reference; + geometry_info.sigma=argument_list[2].real_reference; + if (attribute_flag[3] != 0) + channel=(ChannelType) argument_list[3].integer_reference; channel_mask=SetPixelChannelMask(image,channel); - image=RadialBlurImage(image,geometry_info.rho,exception); + image=RadialBlurImage(image,geometry_info.rho,geometry_info.sigma, + exception); if (image != (Image *) NULL) (void) SetPixelChannelMask(image,channel_mask); break;