MagickCore  7.0.3
color.c File Reference
Include dependency graph for color.c:

Go to the source code of this file.

Data Structures

struct  _ColorMapInfo
 

Macros

#define ColorFilename   "colors.xml"
 
#define SVGCompliant(component)
 
#define SearchImageText   " Searching image... "
 

Typedefs

typedef struct _ColorMapInfo ColorMapInfo
 

Functions

static MagickBooleanType IsColorCacheInstantiated (ExceptionInfo *)
 
static MagickBooleanType LoadColorCache (LinkedListInfo *, const char *, const char *, const size_t, ExceptionInfo *)
 
static LinkedListInfoAcquireColorCache (const char *filename, ExceptionInfo *exception)
 
MagickPrivate MagickBooleanType ColorComponentGenesis (void)
 
static void * DestroyColorElement (void *color_info)
 
MagickPrivate void ColorComponentTerminus (void)
 
MagickExport const ColorInfoGetColorCompliance (const char *name, const ComplianceType compliance, ExceptionInfo *exception)
 
MagickExport const ColorInfoGetColorInfo (const char *name, ExceptionInfo *exception)
 
MagickExport void ConcatenateColorComponent (const PixelInfo *pixel, const PixelChannel channel, const ComplianceType compliance, char *tuple)
 
static int ColorInfoCompare (const void *x, const void *y)
 
MagickExport const ColorInfo ** GetColorInfoList (const char *pattern, size_t *number_colors, ExceptionInfo *exception)
 
static int ColorCompare (const void *x, const void *y)
 
MagickExport char ** GetColorList (const char *pattern, size_t *number_colors, ExceptionInfo *exception)
 
static MagickBooleanType IsSVGCompliant (const PixelInfo *pixel)
 
static void ConcatentateHexColorComponent (const PixelInfo *pixel, const PixelChannel channel, char *tuple)
 
MagickExport void GetColorTuple (const PixelInfo *pixel, const MagickBooleanType hex, char *tuple)
 
MagickPrivate MagickBooleanType IsEquivalentAlpha (const Image *image, const PixelInfo *p, const PixelInfo *q)
 
MagickExport MagickBooleanType IsEquivalentImage (const Image *image, const Image *target_image, ssize_t *x_offset, ssize_t *y_offset, ExceptionInfo *exception)
 
MagickPrivate MagickBooleanType IsEquivalentIntensity (const Image *image, const PixelInfo *p, const PixelInfo *q)
 
MagickExport MagickBooleanType ListColorInfo (FILE *file, ExceptionInfo *exception)
 
MagickExport MagickBooleanType QueryColorCompliance (const char *name, const ComplianceType compliance, PixelInfo *color, ExceptionInfo *exception)
 
MagickExport MagickBooleanType QueryColorname (const Image *magick_unused(image), const PixelInfo *color, const ComplianceType compliance, char *name, ExceptionInfo *exception)
 

Variables

static const ColorMapInfo ColorMap []
 
static LinkedListInfocolor_cache = (LinkedListInfo *) NULL
 
static SemaphoreInfocolor_semaphore = (SemaphoreInfo *) NULL
 

Macro Definition Documentation

§ ColorFilename

#define ColorFilename   "colors.xml"

Definition at line 77 of file color.c.

Referenced by IsColorCacheInstantiated().

§ SearchImageText

#define SearchImageText   " Searching image... "

Referenced by IsEquivalentImage().

§ SVGCompliant

#define SVGCompliant (   component)
Value:
((double) \
ScaleCharToQuantum(ScaleQuantumToChar(ClampToQuantum(component))))
static Quantum ClampToQuantum(const MagickRealType value)
Definition: quantum.h:84

Referenced by IsSVGCompliant().

Typedef Documentation

§ ColorMapInfo

typedef struct _ColorMapInfo ColorMapInfo

Function Documentation

§ AcquireColorCache()

§ ColorCompare()

static int ColorCompare ( const void *  x,
const void *  y 
)
static

Definition at line 1376 of file color.c.

References LocaleCompare().

Referenced by GetColorList().

§ ColorComponentGenesis()

MagickPrivate MagickBooleanType ColorComponentGenesis ( void  )

Definition at line 922 of file color.c.

References AcquireSemaphoreInfo(), color_semaphore, and MagickTrue.

§ ColorComponentTerminus()

§ ColorInfoCompare()

static int ColorInfoCompare ( const void *  x,
const void *  y 
)
static

Definition at line 1277 of file color.c.

References LocaleCompare().

Referenced by GetColorInfoList().

§ ConcatenateColorComponent()

§ ConcatentateHexColorComponent()

§ DestroyColorElement()

static void* DestroyColorElement ( void *  color_info)
static

§ GetColorCompliance()

§ GetColorInfo()

MagickExport const ColorInfo* GetColorInfo ( const char *  name,
ExceptionInfo exception 
)

Definition at line 1089 of file color.c.

References AllCompliance, and GetColorCompliance().

Referenced by GetColorInfoList(), GetColorList(), and QueryColorname().

§ GetColorInfoList()

§ GetColorList()

§ GetColorTuple()

§ IsColorCacheInstantiated()

static MagickBooleanType IsColorCacheInstantiated ( ExceptionInfo exception)
static

§ IsEquivalentAlpha()

MagickPrivate MagickBooleanType IsEquivalentAlpha ( const Image image,
const PixelInfo p,
const PixelInfo q 
)

§ IsEquivalentImage()

§ IsEquivalentIntensity()

MagickPrivate MagickBooleanType IsEquivalentIntensity ( const Image image,
const PixelInfo p,
const PixelInfo q 
)

Definition at line 1861 of file color.c.

References _Image::fuzz, GetPixelInfoIntensity(), MagickFalse, MagickMax, MagickSQ1_2, and MagickTrue.

§ IsSVGCompliant()

§ ListColorInfo()

§ LoadColorCache()

§ QueryColorCompliance()

MagickExport MagickBooleanType QueryColorCompliance ( const char *  name,
const ComplianceType  compliance,
PixelInfo color,
ExceptionInfo exception 
)

Definition at line 2217 of file color.c.

References AcquireString(), AllCompliance, _PixelInfo::alpha, _PixelPacket::alpha, _PixelInfo::alpha_trait, BackgroundColor, _PixelInfo::black, BlendPixelTrait, _ColorMapInfo::blue, _PixelInfo::blue, _PixelPacket::blue, _GeometryInfo::chi, ChiValue, ClampToQuantum(), CMYKColorspace, _ColorInfo::color, _PixelInfo::colorspace, ConvertHCLToRGB(), ConvertHSBToRGB(), ConvertHSLToRGB(), ConvertHWBToRGB(), CopyMagickString(), _PixelInfo::depth, DestroyString(), GetColorCompliance(), GetMagickModule, GetPixelInfo(), GetQuantumRange(), GRAYColorspace, _ColorMapInfo::green, _PixelInfo::green, _PixelPacket::green, HCLColorspace, HSBColorspace, HSLColorspace, HWBColorspace, LabColorspace, LocaleCompare(), LocaleLower(), LocaleNCompare(), LogMagickEvent(), MagickColorspaceOptions, MagickFalse, MagickPathExtent, MagickTrue, _ColorMapInfo::name, OpaqueAlpha, OptionWarning, ParseCommandOption(), ParseGeometry(), PercentValue, _GeometryInfo::psi, PsiValue, QuantumRange, _ColorMapInfo::red, _PixelInfo::red, _PixelPacket::red, ResetMagickMemory(), RGBColorspace, _GeometryInfo::rho, RhoValue, ScaleAnyToQuantum(), SetGeometryInfo(), _GeometryInfo::sigma, SigmaValue, sRGBColorspace, SubstituteString(), ThrowMagickException(), TraceEvent, UndefinedPixelTrait, _GeometryInfo::xi, and XiValue.

Referenced by AcquireImage(), CompareImages(), DrawBoundingRectangles(), DrawClipPath(), DrawImage(), DrawPatternPath(), FloodfillPaintImage(), FxGetSymbol(), GetDrawInfo(), GetImageInfo(), LoadColorCache(), MontageImageList(), PolaroidImage(), PreviewImage(), SetImageProperty(), ShadowImage(), SyncImageSettings(), and VignetteImage().

§ QueryColorname()

Variable Documentation

§ color_cache

§ color_semaphore

§ ColorMap

const ColorMapInfo ColorMap[]
static

Definition at line 103 of file color.c.

Referenced by AcquireColorCache().