MagickCore
6.9.10
Convert, Edit, Or Compose Bitmap Images
|
Go to the documentation of this file.
18 #ifndef MAGICKCORE_THRESHOLD_H
19 #define MAGICKCORE_THRESHOLD_H
21 #if defined(__cplusplus) || defined(c_plusplus)
68 #if defined(__cplusplus) || defined(c_plusplus)
ColorspaceType colorspace
Definition: image.h:158
char * map_id
Definition: threshold.c:99
MagickExport MagickBooleanType PerceptibleImage(Image *, const double)
#define QuantumScale
Definition: magick-type.h:120
MagickExport MagickBooleanType RandomThresholdImage(Image *, const char *, ExceptionInfo *)
#define MagickMinimumValue
Definition: magick-type.h:117
#define MagickExport
Definition: method-attribute.h:80
MagickBooleanType debug
Definition: image.h:290
char filename[MaxTextExtent]
Definition: image.h:278
static double KapurThreshold(const Image *image, const double *histogram, ExceptionInfo *exception)
Definition: threshold.c:398
MagickProgressMonitor progress_monitor
Definition: image.h:264
MagickExport MagickBooleanType PerceptibleImageChannel(Image *image, const ChannelType channel, const double epsilon)
Definition: threshold.c:2124
MagickExport Image * CloneImage(const Image *image, const size_t columns, const size_t rows, const MagickBooleanType detach, ExceptionInfo *exception)
Definition: image.c:788
#define TransparentOpacity
Definition: image.h:28
MagickBooleanType matte
Definition: image.h:171
MagickExport MagickBooleanType SetImageProgress(const Image *image, const char *tag, const MagickOffsetType offset, const MagickSizeType extent)
Definition: monitor.c:136
#define OpaqueOpacity
Definition: image.h:27
@ PsiValue
Definition: geometry.h:34
static RandomInfo ** AcquireRandomInfoThreadSet(void)
Definition: random-private.h:40
MagickExport const char * GetStringInfoPath(const StringInfo *string_info)
Definition: string.c:1362
@ SyncChannels
Definition: magick-type.h:180
MagickRealType red
Definition: pixel.h:122
@ DirectClass
Definition: magick-type.h:187
@ BlueChannel
Definition: magick-type.h:165
#define GetMagickModule()
Definition: log.h:29
MagickExport CacheView * DestroyCacheView(CacheView *cache_view)
Definition: cache-view.c:256
MagickExport void GetMagickPixelPacket(const Image *image, MagickPixelPacket *pixel)
Definition: pixel.c:2242
unsigned int MagickStatusType
Definition: magick-type.h:127
@ RedChannel
Definition: magick-type.h:160
double psi
Definition: geometry.h:111
#define SetPixelOpacity(pixel, value)
Definition: pixel-accessor.h:81
ChannelType
Definition: magick-type.h:158
@ XiValue
Definition: geometry.h:31
MagickExport MagickBooleanType WhiteThresholdImageChannel(Image *image, const ChannelType channel, const char *thresholds, ExceptionInfo *exception)
Definition: threshold.c:2615
#define MagickCoreSignature
Definition: method-attribute.h:86
@ TriangleThresholdMethod
Definition: threshold.h:30
MagickExport MagickBooleanType BilevelImage(Image *image, const double threshold)
Definition: threshold.c:813
MagickExport ssize_t FormatLocaleString(char *magick_restrict string, const size_t length, const char *magick_restrict format,...)
Definition: locale.c:502
MagickExport MagickBooleanType BlackThresholdImage(Image *image, const char *threshold)
Definition: threshold.c:972
MagickExport const IndexPacket * GetCacheViewVirtualIndexQueue(const CacheView *cache_view)
Definition: cache-view.c:638
size_t height
Definition: threshold.c:104
ssize_t * levels
Definition: threshold.c:108
@ IndexChannel
Definition: magick-type.h:171
MagickExport PixelPacket * GetCacheViewAuthenticPixels(CacheView *cache_view, const ssize_t x, const ssize_t y, const size_t columns, const size_t rows, ExceptionInfo *exception)
Definition: cache-view.c:473
double sigma
Definition: geometry.h:109
#define magick_restrict
Definition: MagickCore.h:41
MagickExport MagickBooleanType WhiteThresholdImageChannel(Image *, const ChannelType, const char *, ExceptionInfo *)
Definition: threshold.c:2615
#define SetPixelRed(pixel, value)
Definition: pixel-accessor.h:82
MagickExport MagickBooleanType BlackThresholdImage(Image *, const char *)
#define SetPixelRGBO(pixel, packet)
Definition: pixel-accessor.h:96
MagickExport const char * GetXMLTreeAttribute(XMLTreeInfo *xml_info, const char *tag)
Definition: xml-tree.c:778
MagickExport MagickBooleanType OrderedDitherImage(Image *image)
Definition: threshold.c:1745
size_t columns
Definition: image.h:174
MagickExport MagickBooleanType AcquireImageColormap(Image *image, const size_t colors)
Definition: colormap.c:102
#define SetPixelGreen(pixel, value)
Definition: pixel-accessor.h:77
Definition: geometry.h:106
Quantum IndexPacket
Definition: pixel.h:129
MagickBooleanType ListThresholdMapFile(FILE *file, const char *xml, const char *filename, ExceptionInfo *exception)
Definition: threshold.c:1603
@ sRGBColorspace
Definition: colorspace.h:40
double xi
Definition: geometry.h:110
#define GetPixelRed(pixel)
Definition: pixel-accessor.h:50
@ ResourceLimitError
Definition: exception.h:55
MagickExport MagickBooleanType BilevelImage(Image *, const double)
MagickExport MagickBooleanType OrderedDitherImageChannel(Image *image, const ChannelType channel, ExceptionInfo *exception)
Definition: threshold.c:1754
Definition: cache-view.c:66
MagickExport MagickBooleanType SetImageProperty(Image *image, const char *property, const char *value)
Definition: property.c:4131
MagickExport char * DestroyString(char *string)
Definition: string.c:820
@ ChiValue
Definition: geometry.h:41
MagickExport MagickBooleanType SyncImage(Image *image)
Definition: image.c:3689
@ MagickTrue
Definition: magick-type.h:194
MagickExport const char * GetXMLTreeContent(XMLTreeInfo *xml_info)
Definition: xml-tree.c:935
MagickExport MagickBooleanType ListThresholdMaps(FILE *, ExceptionInfo *)
#define GetPixelAlpha(pixel)
Definition: pixel-accessor.h:36
MagickRealType index
Definition: pixel.h:126
#define GetPixelIndex(indexes)
Definition: pixel-accessor.h:44
MagickExport MagickBooleanType SyncCacheViewAuthenticPixels(CacheView *magick_restrict cache_view, ExceptionInfo *exception)
Definition: cache-view.c:1000
MagickRealType blue
Definition: pixel.h:124
static double TriangleThreshold(const Image *image, const double *histogram, ExceptionInfo *exception)
Definition: threshold.c:576
MagickExport MagickBooleanType BlackThresholdImageChannel(Image *image, const ChannelType channel, const char *thresholds, ExceptionInfo *exception)
Definition: threshold.c:983
static Quantum ClampToQuantum(const MagickRealType quantum)
Definition: quantum.h:88
#define ThresholdImageTag
MagickExport ThresholdMap * DestroyThresholdMap(ThresholdMap *)
@ TraceEvent
Definition: log.h:38
MagickExport void * AcquireMagickMemory(const size_t size)
Definition: memory.c:473
PixelPacket * colormap
Definition: image.h:180
Definition: xml-tree.c:77
MagickExport MagickBooleanType RandomThresholdImageChannel(Image *image, const ChannelType channel, const char *thresholds, ExceptionInfo *exception)
Definition: threshold.c:2283
double rho
Definition: geometry.h:108
MagickExport ssize_t FormatLocaleFile(FILE *file, const char *magick_restrict format,...)
Definition: locale.c:407
static RandomInfo ** DestroyRandomInfoThreadSet(RandomInfo **random_info)
Definition: random-private.h:27
@ KapurThresholdMethod
Definition: threshold.h:28
static Quantum ClampPixel(const MagickRealType value)
Definition: pixel-accessor.h:111
MagickExport MagickBooleanType ClampImage(Image *)
#define SetPixelAlpha(pixel, value)
Definition: pixel-accessor.h:67
unsigned int blue
Definition: pixel.h:99
MagickExport IndexPacket * GetCacheViewAuthenticIndexQueue(CacheView *cache_view)
Definition: cache-view.c:564
MagickExport MagickBooleanType BilevelImageChannel(Image *, const ChannelType, const double)
MagickExport MagickBooleanType ClampImage(Image *image)
Definition: threshold.c:1142
MagickExport CacheView * AcquireAuthenticCacheView(const Image *image, ExceptionInfo *exception)
Definition: cache-view.c:111
MagickExport unsigned long GetRandomSecretKey(const RandomInfo *random_info)
Definition: random.c:745
double chi
Definition: geometry.h:112
MagickExport MagickBooleanType AutoThresholdImage(Image *image, const AutoThresholdMethod method, ExceptionInfo *exception)
Definition: threshold.c:668
MagickExport MagickBooleanType OrderedPosterizeImageChannel(Image *image, const ChannelType channel, const char *threshold_map, ExceptionInfo *exception)
Definition: threshold.c:1830
@ ConfigureEvent
Definition: log.h:43
static MagickBooleanType IsMagickGray(const MagickPixelPacket *pixel)
Definition: color-private.h:91
MagickExport int LocaleCompare(const char *p, const char *q)
Definition: locale.c:1440
unsigned int index
Definition: pixel.h:101
@ OpacityChannel
Definition: magick-type.h:168
size_t colors
Definition: image.h:177
MagickExport MagickBooleanType ListThresholdMaps(FILE *file, ExceptionInfo *exception)
Definition: threshold.c:1681
MagickExport Image * AdaptiveThresholdImage(const Image *image, const size_t width, const size_t height, const ssize_t offset, ExceptionInfo *exception)
Definition: threshold.c:168
ExceptionInfo exception
Definition: image.h:287
@ OptionError
Definition: exception.h:57
@ OTSUThresholdMethod
Definition: threshold.h:29
#define SetPixelBlue(pixel, value)
Definition: pixel-accessor.h:71
@ MagickFalse
Definition: magick-type.h:193
MagickBooleanType(* MagickProgressMonitor)(const char *, const MagickOffsetType, const MagickSizeType, void *)
Definition: monitor.h:26
MagickExport XMLTreeInfo * NewXMLTree(const char *xml, ExceptionInfo *exception)
Definition: xml-tree.c:1950
#define GetPixelBlue(pixel)
Definition: pixel-accessor.h:38
#define ThresholdsFilename
Definition: threshold.c:91
static double OTSUThreshold(const Image *image, const double *histogram, ExceptionInfo *exception)
Definition: threshold.c:497
ssize_t divisor
Definition: threshold.c:107
static Quantum PerceptibleThreshold(const Quantum quantum, const double epsilon)
Definition: threshold.c:2102
#define GetPixelOpacity(pixel)
Definition: pixel-accessor.h:49
@ UndefinedThresholdMethod
Definition: threshold.h:27
MagickExport MagickBooleanType AutoThresholdImage(Image *, const AutoThresholdMethod, ExceptionInfo *)
@ DefaultChannels
Definition: magick-type.h:181
MagickExport XMLTreeInfo * DestroyXMLTree(XMLTreeInfo *xml_info)
Definition: xml-tree.c:557
MagickExport MagickStatusType ParseGeometry(const char *geometry, GeometryInfo *geometry_info)
Definition: geometry.c:857
MagickExport ThresholdMap * GetThresholdMap(const char *map_id, ExceptionInfo *exception)
Definition: threshold.c:1544
MagickExport XMLTreeInfo * GetNextXMLTreeTag(XMLTreeInfo *xml_info)
Definition: xml-tree.c:743
static double PerceptibleReciprocal(const double x)
Definition: pixel-accessor.h:124
#define QuantumRange
Definition: magick-type.h:86
@ CMYKColorspace
Definition: colorspace.h:39
MagickExport MagickBooleanType PerceptibleImage(Image *image, const double epsilon)
Definition: threshold.c:2114
MagickExport MagickBooleanType RandomThresholdImage(Image *image, const char *thresholds, ExceptionInfo *exception)
Definition: threshold.c:2272
size_t rows
Definition: image.h:175
MagickExport MagickBooleanType RandomThresholdImageChannel(Image *, const ChannelType, const char *, ExceptionInfo *)
size_t signature
Definition: exception.h:124
MagickExport ThresholdMap * GetThresholdMap(const char *, ExceptionInfo *)
Definition: threshold.c:1544
MagickExport char * ConstantString(const char *source)
Definition: string.c:697
size_t signature
Definition: image.h:307
MagickBooleanType
Definition: magick-type.h:192
static const char * MinimalThresholdMap
Definition: threshold.c:115
MagickExport double GetPseudoRandomValue(RandomInfo *random_info)
Definition: random.c:612
@ PercentValue
Definition: geometry.h:49
MagickExport void * GetNextValueInLinkedList(LinkedListInfo *list_info)
Definition: hashmap.c:606
MagickExport void * RelinquishMagickMemory(void *memory)
Definition: memory.c:1077
static RandomInfo * random_info
Definition: resource.c:110
unsigned int red
Definition: pixel.h:97
Definition: exception.h:103
#define SetPixelIndex(indexes, value)
Definition: pixel-accessor.h:78
ClassType storage_class
Definition: image.h:155
MagickExport MagickBooleanType OrderedDitherImageChannel(Image *, const ChannelType, ExceptionInfo *)
static long StringToLong(const char *magick_restrict value)
Definition: string-private.h:68
MagickDoubleType MagickRealType
Definition: magick-type.h:125
MagickExport MagickBooleanType BlackThresholdImageChannel(Image *, const ChannelType, const char *, ExceptionInfo *)
@ CompositeChannels
Definition: magick-type.h:172
MagickExport Image * AdaptiveThresholdImage(const Image *, const size_t, const size_t, const ssize_t, ExceptionInfo *)
Definition: threshold.c:168
MagickExport CacheView * AcquireVirtualCacheView(const Image *image, ExceptionInfo *exception)
Definition: cache-view.c:153
@ PseudoClass
Definition: magick-type.h:188
MagickExport Image * DestroyImage(Image *image)
Definition: image.c:1187
MagickExport MagickBooleanType PerceptibleImageChannel(Image *, const ChannelType, const double)
MagickExport ThresholdMap * GetThresholdMapFile(const char *xml, const char *filename, const char *map_id, ExceptionInfo *exception)
Definition: threshold.c:1326
MagickExport MagickBooleanType OrderedPosterizeImage(Image *image, const char *threshold_map, ExceptionInfo *exception)
Definition: threshold.c:1819
MagickExport MagickBooleanType ClampImageChannel(Image *, const ChannelType)
@ SigmaValue
Definition: geometry.h:40
MagickExport unsigned char * GetStringInfoDatum(const StringInfo *string_info)
Definition: string.c:1275
AutoThresholdMethod
Definition: threshold.h:26
MagickExport MagickBooleanType ThrowMagickException(ExceptionInfo *exception, const char *module, const char *function, const size_t line, const ExceptionType severity, const char *tag, const char *format,...)
Definition: exception.c:1068
#define ThrowFatalException(severity, tag)
Definition: exception-private.h:42
MagickExport MagickBooleanType WhiteThresholdImage(Image *, const char *)
MagickExport MagickRealType GetPixelIntensity(const Image *image, const PixelPacket *magick_restrict pixel)
Definition: pixel.c:2301
MagickExport MagickBooleanType OrderedPosterizeImageChannel(Image *, const ChannelType, const char *, ExceptionInfo *)
MagickExport MagickBooleanType OrderedDitherImage(Image *)
MagickExport MagickBooleanType ClampImageChannel(Image *image, const ChannelType channel)
Definition: threshold.c:1151
MagickExport MagickBooleanType SetImageStorageClass(Image *image, const ClassType storage_class)
Definition: image.c:2610
#define GetPixelGreen(pixel)
Definition: pixel-accessor.h:43
MagickExport ThresholdMap * DestroyThresholdMap(ThresholdMap *map)
Definition: threshold.c:1283
MagickExport MagickBooleanType LogMagickEvent(const LogEventType type, const char *module, const char *function, const size_t line, const char *format,...)
Definition: log.c:1399
MagickExport MagickBooleanType BilevelImageChannel(Image *image, const ChannelType channel, const double threshold)
Definition: threshold.c:822
#define MaxTextExtent
Definition: method-attribute.h:89
unsigned int green
Definition: pixel.h:98
MagickExport const PixelPacket * GetCacheViewVirtualPixels(const CacheView *cache_view, const ssize_t x, const ssize_t y, const size_t columns, const size_t rows, ExceptionInfo *exception)
Definition: cache-view.c:723
unsigned int opacity
Definition: pixel.h:100
MagickExport XMLTreeInfo * GetXMLTreeChild(XMLTreeInfo *xml_info, const char *tag)
Definition: xml-tree.c:895
MagickExport void InheritException(ExceptionInfo *exception, const ExceptionInfo *relative)
Definition: exception.c:633
char * description
Definition: threshold.c:100
@ ResourceLimitFatalError
Definition: exception.h:78
MagickExport MagickBooleanType OrderedPosterizeImage(Image *, const char *, ExceptionInfo *)
MagickExport MagickBooleanType WhiteThresholdImage(Image *image, const char *threshold)
Definition: threshold.c:2604
MagickRealType opacity
Definition: pixel.h:125
MagickRealType green
Definition: pixel.h:123
Definition: threshold.c:97
@ GreenChannel
Definition: magick-type.h:163
size_t width
Definition: threshold.c:103
#define ThrowBinaryException(severity, tag, context)
Definition: exception-private.h:29
#define PerceptibleImageTag
static MagickBooleanType IsGrayColorspace(const ColorspaceType colorspace)
Definition: colorspace-private.h:96
MagickExport void * AcquireQuantumMemory(const size_t count, const size_t quantum)
Definition: memory.c:544
unsigned short Quantum
Definition: magick-type.h:85
ssize_t MagickOffsetType
Definition: magick-type.h:135
static unsigned long StringToUnsignedLong(const char *magick_restrict value)
Definition: string-private.h:73
static int GetOpenMPThreadId(void)
Definition: thread-private.h:120
#define MagickPathExtent
Definition: magick-type.h:31
MagickExport MagickBooleanType SetImageColorspace(Image *image, const ColorspaceType colorspace)
Definition: colorspace.c:1189