MagickCore  6.9.11
morphology.c File Reference
Include dependency graph for morphology.c:

Go to the source code of this file.

Macros

#define Minimize(assign, value)   assign=MagickMin(assign,value)
 
#define Maximize(assign, value)   assign=MagickMax(assign,value)
 
#define KernelRank   3
 
#define KernelRank   3
 
#define MorphologyTag   "Morphology/Image"
 

Functions

static size_t fact (size_t n)
 
static void CalcKernelMetaData (KernelInfo *)
 
static void ExpandMirrorKernelInfo (KernelInfo *)
 
static void ExpandRotateKernelInfo (KernelInfo *, const double)
 
static void RotateKernelInfo (KernelInfo *, double)
 
static KernelInfoLastKernelInfo (KernelInfo *kernel)
 
static KernelInfoParseKernelArray (const char *kernel_string)
 
static KernelInfoParseKernelName (const char *kernel_string)
 
MagickExport KernelInfoAcquireKernelInfo (const char *kernel_string)
 
MagickExport KernelInfoAcquireKernelBuiltIn (const KernelInfoType type, const GeometryInfo *args)
 
MagickExport KernelInfoCloneKernelInfo (const KernelInfo *kernel)
 
MagickExport KernelInfoDestroyKernelInfo (KernelInfo *kernel)
 
static MagickBooleanType SameKernelInfo (const KernelInfo *kernel1, const KernelInfo *kernel2)
 
static ssize_t MorphologyPrimitive (const Image *image, Image *result_image, const MorphologyMethod method, const ChannelType channel, const KernelInfo *kernel, const double bias, ExceptionInfo *exception)
 
static ssize_t MorphologyPrimitiveDirect (Image *image, const MorphologyMethod method, const ChannelType channel, const KernelInfo *kernel, ExceptionInfo *exception)
 
MagickExport ImageMorphologyApply (const Image *image, const ChannelType channel, const MorphologyMethod method, const ssize_t iterations, const KernelInfo *kernel, const CompositeOperator compose, const double bias, ExceptionInfo *exception)
 
MagickExport ImageMorphologyImage (const Image *image, const MorphologyMethod method, const ssize_t iterations, const KernelInfo *kernel, ExceptionInfo *exception)
 
MagickExport ImageMorphologyImageChannel (const Image *image, const ChannelType channel, const MorphologyMethod method, const ssize_t iterations, const KernelInfo *kernel, ExceptionInfo *exception)
 
MagickExport void ScaleGeometryKernelInfo (KernelInfo *kernel, const char *geometry)
 
MagickExport void ScaleKernelInfo (KernelInfo *kernel, const double scaling_factor, const GeometryFlags normalize_flags)
 
MagickExport void ShowKernelInfo (const KernelInfo *kernel)
 
MagickExport void UnityAddKernelInfo (KernelInfo *kernel, const double scale)
 
MagickExport void ZeroKernelNans (KernelInfo *kernel)
 

Macro Definition Documentation

◆ KernelRank [1/2]

#define KernelRank   3

Referenced by AcquireKernelBuiltIn().

◆ KernelRank [2/2]

#define KernelRank   3

◆ Maximize

#define Maximize (   assign,
  value 
)    assign=MagickMax(assign,value)

Definition at line 92 of file morphology.c.

Referenced by CalcKernelMetaData(), MorphologyPrimitive(), and ParseKernelArray().

◆ Minimize

#define Minimize (   assign,
  value 
)    assign=MagickMin(assign,value)

◆ MorphologyTag

#define MorphologyTag   "Morphology/Image"

Function Documentation

◆ AcquireKernelBuiltIn()

MagickExport KernelInfo* AcquireKernelBuiltIn ( const KernelInfoType  type,
const GeometryInfo args 
)

◆ AcquireKernelInfo()

◆ CalcKernelMetaData()

◆ CloneKernelInfo()

◆ DestroyKernelInfo()

◆ ExpandMirrorKernelInfo()

static void ExpandMirrorKernelInfo ( KernelInfo kernel)

◆ ExpandRotateKernelInfo()

static void ExpandRotateKernelInfo ( KernelInfo kernel,
const double  angle 
)

◆ fact()

static size_t fact ( size_t  n)
inlinestatic

Definition at line 96 of file morphology.c.

Referenced by AcquireKernelBuiltIn().

◆ LastKernelInfo()

static KernelInfo* LastKernelInfo ( KernelInfo kernel)
inlinestatic

◆ MorphologyApply()

MagickExport Image* MorphologyApply ( const Image image,
const ChannelType  channel,
const MorphologyMethod  method,
const ssize_t  iterations,
const KernelInfo kernel,
const CompositeOperator  compose,
const double  bias,
ExceptionInfo exception 
)

◆ MorphologyImage()

MagickExport Image* MorphologyImage ( const Image image,
const MorphologyMethod  method,
const ssize_t  iterations,
const KernelInfo kernel,
ExceptionInfo exception 
)

Definition at line 4356 of file morphology.c.

References DefaultChannels, and MorphologyImageChannel().

◆ MorphologyImageChannel()

◆ MorphologyPrimitive()

static ssize_t MorphologyPrimitive ( const Image image,
Image result_image,
const MorphologyMethod  method,
const ChannelType  channel,
const KernelInfo kernel,
const double  bias,
ExceptionInfo exception 
)
static

Definition at line 2559 of file morphology.c.

References AcquireAuthenticCacheView(), AcquireQuantumMemory(), AcquireVirtualCacheView(), _DoublePixelPacket::blue, BlueChannel, ClampToQuantum(), CMYKColorspace, _Image::colorspace, _Image::columns, ConvolveMorphology, DestroyCacheView(), DilateIntensityMorphology, DilateMorphology, ErodeIntensityMorphology, ErodeMorphology, GetCacheViewAuthenticIndexQueue(), GetCacheViewAuthenticPixels(), GetCacheViewVirtualIndexQueue(), GetCacheViewVirtualPixels(), GetOpenMPMaximumThreads(), GetOpenMPThreadId(), GetPixelBlue, GetPixelGreen, GetPixelIndex, GetPixelIntensity(), GetPixelOpacity, GetPixelRed, _DoublePixelPacket::green, GreenChannel, KernelInfo::height, HitAndMissMorphology, _DoublePixelPacket::index, IndexChannel, IsNaN, IterativeDistanceMorphology, magick_restrict, MagickCoreSignature, MagickFalse, MagickTrue, _Image::matte, Maximize, Minimize, MorphologyTag, _DoublePixelPacket::opacity, OpacityChannel, PerceptibleReciprocal(), _Image::progress_monitor, QuantumRange, QuantumScale, _DoublePixelPacket::red, RedChannel, RelinquishMagickMemory(), ResourceLimitFatalError, _Image::rows, SetImageProgress(), SetPixelAlpha, SetPixelBlue, SetPixelGreen, SetPixelIndex, SetPixelOpacity, SetPixelRed, _ExceptionInfo::signature, KernelInfo::signature, _Image::signature, SyncCacheViewAuthenticPixels(), SyncChannels, ThickenMorphology, ThinningMorphology, ThrowFatalException, _Image::type, UndefinedMorphology, KernelInfo::values, KernelInfo::width, KernelInfo::x, and KernelInfo::y.

Referenced by MorphologyApply().

◆ MorphologyPrimitiveDirect()

◆ ParseKernelArray()

◆ ParseKernelName()

◆ RotateKernelInfo()

◆ SameKernelInfo()

static MagickBooleanType SameKernelInfo ( const KernelInfo kernel1,
const KernelInfo kernel2 
)
static

◆ ScaleGeometryKernelInfo()

◆ ScaleKernelInfo()

◆ ShowKernelInfo()

◆ UnityAddKernelInfo()

MagickExport void UnityAddKernelInfo ( KernelInfo kernel,
const double  scale 
)

◆ ZeroKernelNans()

MagickExport void ZeroKernelNans ( KernelInfo kernel)