MagickCore 7.1.0
Convert, Edit, Or Compose Bitmap Images
|
#include "MagickCore/studio.h"
#include "MagickCore/artifact.h"
#include "MagickCore/cache.h"
#include "MagickCore/cache-view.h"
#include "MagickCore/channel.h"
#include "MagickCore/colorspace-private.h"
#include "MagickCore/composite-private.h"
#include "MagickCore/distort.h"
#include "MagickCore/exception.h"
#include "MagickCore/exception-private.h"
#include "MagickCore/gem.h"
#include "MagickCore/image.h"
#include "MagickCore/linked-list.h"
#include "MagickCore/list.h"
#include "MagickCore/matrix.h"
#include "MagickCore/matrix-private.h"
#include "MagickCore/memory_.h"
#include "MagickCore/monitor-private.h"
#include "MagickCore/option.h"
#include "MagickCore/pixel.h"
#include "MagickCore/pixel-accessor.h"
#include "MagickCore/resample.h"
#include "MagickCore/resample-private.h"
#include "MagickCore/registry.h"
#include "MagickCore/resource_.h"
#include "MagickCore/semaphore.h"
#include "MagickCore/shear.h"
#include "MagickCore/string_.h"
#include "MagickCore/string-private.h"
#include "MagickCore/thread-private.h"
#include "MagickCore/token.h"
#include "MagickCore/transform.h"
Go to the source code of this file.
Macros | |
#define | DistortResizeImageTag "Distort/Image" |
#define | DistortImageTag "Distort/Image" |
#define | InitalBounds(p) |
#define | ExpandBounds(p) |
#define | ScaleFilter(F, A, B, C, D) |
#define | SparseColorTag "Distort/SparseColor" |
Functions | |
static void | AffineArgsToCoefficients (double *affine) |
static void | CoefficientsToAffineArgs (double *coeff) |
static void | InvertAffineCoefficients (const double *coeff, double *inverse) |
static void | InvertPerspectiveCoefficients (const double *coeff, double *inverse) |
static size_t | poly_number_terms (double order) |
static double | poly_basis_fn (ssize_t n, double x, double y) |
static const char * | poly_basis_str (ssize_t n) |
static double | poly_basis_dx (ssize_t n, double x, double y) |
static double | poly_basis_dy (ssize_t n, double x, double y) |
MagickExport Image * | AffineTransformImage (const Image *image, const AffineMatrix *affine_matrix, ExceptionInfo *exception) |
static double | MagickRound (double x) |
static double * | GenerateCoefficients (const Image *image, DistortMethod *method, const size_t number_arguments, const double *arguments, size_t number_values, ExceptionInfo *exception) |
MagickExport Image * | DistortResizeImage (const Image *image, const size_t columns, const size_t rows, ExceptionInfo *exception) |
MagickExport Image * | DistortImage (const Image *image, DistortMethod method, const size_t number_arguments, const double *arguments, MagickBooleanType bestfit, ExceptionInfo *exception) |
MagickExport Image * | RotateImage (const Image *image, const double degrees, ExceptionInfo *exception) |
MagickExport Image * | SparseColorImage (const Image *image, const SparseColorMethod method, const size_t number_arguments, const double *arguments, ExceptionInfo *exception) |
#define DistortImageTag "Distort/Image" |
#define DistortResizeImageTag "Distort/Image" |
#define ExpandBounds | ( | p | ) |
#define InitalBounds | ( | p | ) |
#define ScaleFilter | ( | F, | |
A, | |||
B, | |||
C, | |||
D | |||
) |
#define SparseColorTag "Distort/SparseColor" |
|
inlinestatic |
Definition at line 79 of file distort.c.
Referenced by GenerateCoefficients().
MagickExport Image * AffineTransformImage | ( | const Image * | image, |
const AffineMatrix * | affine_matrix, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 283 of file distort.c.
References AffineProjectionDistortion, DistortImage(), _Image::filename, GetMagickModule, IsEventLogging(), LogMagickEvent(), MagickCoreSignature, MagickFalse, MagickTrue, _AffineMatrix::rx, _AffineMatrix::ry, _ExceptionInfo::signature, _Image::signature, _AffineMatrix::sx, _AffineMatrix::sy, TraceEvent, _AffineMatrix::tx, and _AffineMatrix::ty.
Referenced by DeskewImage().
|
inlinestatic |
Definition at line 87 of file distort.c.
Referenced by DistortImage().
MagickExport Image * DistortImage | ( | const Image * | image, |
DistortMethod | method, | ||
const size_t | number_arguments, | ||
const double * | arguments, | ||
MagickBooleanType | bestfit, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1754 of file distort.c.
References AcquireAuthenticCacheView(), AcquireQuantumMemory(), AcquireResampleFilterTLS(), AffineDistortion, _Image::alpha_trait, _PixelInfo::alpha_trait, ArcDistortion, _Image::background_color, BarrelDistortion, BarrelInverseDistortion, BilinearDistortion, BilinearForwardDistortion, BilinearReverseDistortion, BlendPixelTrait, CloneImage(), CoefficientsToAffineArgs(), _Image::colorspace, _Image::columns, CompositePixelInfoBlend(), ConformPixelInfo(), Cylinder2PlaneDistortion, DePolarDistortion, DestroyCacheView(), DestroyImage(), DestroyResampleFilterTLS(), DirectClass, DistortImageTag, DistortResizeImage(), ExpandBounds, _Image::filename, FormatLocaleFile(), FormatLocaleString(), GenerateCoefficients(), GetImageArtifact(), GetMagickModule, GetMagickPrecision(), GetOpenMPThreadId(), GetPixelChannels(), GetPixelInfo(), _RectangleInfo::height, InitalBounds, InvertAffineCoefficients(), InvertPerspectiveCoefficients(), IsEventLogging(), IsGrayColorspace(), IsPixelInfoGray(), IsStringTrue(), LogMagickEvent(), Magick2PI, magick_restrict, MagickCoreSignature, MagickEpsilon, MagickFalse, MagickPathExtent, MagickPI, MagickPI2, MagickRound(), MagickTrue, _Image::matte_color, NoValue, OptionError, OptionWarning, _Image::page, ParseAbsoluteGeometry(), PerceptibleReciprocal(), PerspectiveDistortion, Plane2CylinderDistortion, PolarDistortion, poly_basis_dx(), poly_basis_dy(), poly_basis_fn(), poly_basis_str(), PolynomialDistortion, _Image::progress_monitor, QueueCacheViewAuthenticPixels(), RadiansToDegrees(), RelinquishMagickMemory(), ResamplePixelColor(), ResizeDistortion, ResourceLimitError, RigidAffineDistortion, _Image::rows, ScaleFilter, SetImageColorspace(), SetImageProgress(), SetImageStorageClass(), SetPixelViaPixelInfo(), ShepardsDistortion, _ExceptionInfo::signature, _Image::signature, sRGBColorspace, StringToDouble(), SyncCacheViewAuthenticPixels(), ThrowMagickException(), TraceEvent, UndefinedPixelTrait, UndefinedVirtualPixelMethod, _RectangleInfo::width, _PointInfo::x, _RectangleInfo::x, _PointInfo::y, and _RectangleInfo::y.
Referenced by AffineTransformImage(), DistortResizeImage(), and RotateImage().
MagickExport Image * DistortResizeImage | ( | const Image * | image, |
const size_t | columns, | ||
const size_t | rows, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1544 of file distort.c.
References AffineDistortion, _Image::alpha_trait, CloneImage(), _Image::columns, _Image::compose, CompositeImage(), CopyAlphaCompositeOp, CropImage(), DestroyImage(), DistortImage(), ExtractAlphaChannel, _Image::filename, GetImageVirtualPixelMethod(), GetMagickModule, _RectangleInfo::height, IsEventLogging(), LogMagickEvent(), MagickCoreSignature, MagickFalse, MagickTrue, OffAlphaChannel, OpaqueAlphaChannel, _Image::page, _Image::rows, SetAlphaChannel, SetImageAlphaChannel(), SetImageVirtualPixelMethod(), _ExceptionInfo::signature, _Image::signature, TraceEvent, TransparentVirtualPixelMethod, UndefinedPixelTrait, _RectangleInfo::width, _RectangleInfo::x, and _RectangleInfo::y.
Referenced by DistortImage().
|
static |
Definition at line 372 of file distort.c.
References AcquireMagickMatrix(), AcquireQuantumMemory(), AffineArgsToCoefficients(), AffineDistortion, AffineProjectionDistortion, ArcDistortion, BarrelDistortion, BarrelInverseDistortion, BilinearForwardDistortion, BilinearReverseDistortion, _Image::columns, CommandOptionToMnemonic(), Cylinder2PlaneDistortion, DegreesToRadians(), DePolarDistortion, GaussJordanElimination(), GetImageArtifact(), GetMagickModule, InvertAffineCoefficients(), InvertPerspectiveCoefficients(), LeastSquaresAddTerms(), Magick2PI, MagickDistortOptions, MagickEpsilon, MagickFalse, MagickMax, MagickMin, MagickPI, MagickPI2, MagickRound(), OptionError, _Image::page, PerspectiveDistortion, PerspectiveProjectionDistortion, Plane2CylinderDistortion, PolarDistortion, poly_basis_fn(), poly_number_terms(), PolynomialDistortion, RelinquishMagickMatrix(), RelinquishMagickMemory(), ResourceLimitError, RigidAffineDistortion, _Image::rows, ScaleRotateTranslateDistortion, ShepardsDistortion, StringToDouble(), ThrowMagickException(), _RectangleInfo::x, and _RectangleInfo::y.
Referenced by DistortImage(), and SparseColorImage().
|
static |
Definition at line 94 of file distort.c.
References PerceptibleReciprocal().
Referenced by DistortImage(), and GenerateCoefficients().
|
static |
Definition at line 108 of file distort.c.
References PerceptibleReciprocal().
Referenced by DistortImage(), and GenerateCoefficients().
|
inlinestatic |
Definition at line 362 of file distort.c.
Referenced by DistortImage(), and GenerateCoefficients().
|
static |
Definition at line 209 of file distort.c.
Referenced by DistortImage(), and poly_basis_dy().
|
static |
|
static |
Definition at line 153 of file distort.c.
Referenced by DistortImage(), and GenerateCoefficients().
|
static |
Definition at line 181 of file distort.c.
Referenced by DistortImage().
|
static |
Definition at line 144 of file distort.c.
References MagickEpsilon.
Referenced by GenerateCoefficients().
MagickExport Image * RotateImage | ( | const Image * | image, |
const double | degrees, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 2948 of file distort.c.
References BackgroundVirtualPixelMethod, CloneImage(), DegreesToRadians(), DestroyImage(), DistortImage(), _Image::filename, GetMagickModule, IntegralRotateImage(), IsEventLogging(), LogMagickEvent(), MagickCoreSignature, MagickEpsilon, MagickFalse, MagickTrue, ScaleRotateTranslateDistortion, SetImageVirtualPixelMethod(), _ExceptionInfo::signature, _Image::signature, TraceEvent, _PointInfo::x, and _PointInfo::y.
Referenced by AutoOrientImage(), PolaroidImage(), and PreviewImage().
MagickExport Image * SparseColorImage | ( | const Image * | image, |
const SparseColorMethod | method, | ||
const size_t | number_arguments, | ||
const double * | arguments, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 3033 of file distort.c.
References AcquireAuthenticCacheView(), _PixelInfo::alpha, _Image::alpha_trait, BarycentricColorInterpolate, BilinearColorInterpolate, _PixelInfo::black, _PixelInfo::blue, ClampPixel(), CloneImage(), CMYKColorspace, _Image::colorspace, _Image::columns, DestroyCacheView(), DestroyImage(), DirectClass, _Image::filename, FormatLocaleFile(), GenerateCoefficients(), GetCacheViewAuthenticPixels(), GetImageArtifact(), GetMagickModule, GetPixelAlphaTraits(), GetPixelBlackTraits(), GetPixelBlueTraits(), GetPixelChannels(), GetPixelGreenTraits(), GetPixelInfo(), GetPixelInfoPixel(), GetPixelRedTraits(), _PixelInfo::green, InverseColorInterpolate, IsEventLogging(), IsStringTrue(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, MagickMaximumValue, MagickTrue, ManhattanColorInterpolate, _Image::progress_monitor, QuantumRange, _PixelInfo::red, RelinquishMagickMemory(), _Image::rows, SentinelDistortion, SetImageProgress(), SetImageStorageClass(), SetPixelViaPixelInfo(), ShepardsColorInterpolate, ShepardsDistortion, _ExceptionInfo::signature, _Image::signature, SparseColorTag, SyncCacheViewAuthenticPixels(), TraceEvent, UndefinedPixelTrait, UpdatePixelTrait, and VoronoiColorInterpolate.