MagickCore 7.1.0
Convert, Edit, Or Compose Bitmap Images
annotate.c File Reference
Include dependency graph for annotate.c:

Go to the source code of this file.

Data Structures

struct  _GraphemeInfo
 

Typedefs

typedef struct _GraphemeInfo GraphemeInfo
 

Functions

static MagickBooleanType RenderType (Image *, const DrawInfo *, const PointInfo *, TypeMetric *, ExceptionInfo *)
 
static MagickBooleanType RenderPostscript (Image *, const DrawInfo *, const PointInfo *, TypeMetric *, ExceptionInfo *)
 
static MagickBooleanType RenderFreetype (Image *, const DrawInfo *, const char *, const PointInfo *, TypeMetric *, ExceptionInfo *)
 
static MagickBooleanType RenderX11 (Image *, const DrawInfo *, const PointInfo *, TypeMetric *, ExceptionInfo *)
 
MagickPrivate MagickBooleanType AnnotateComponentGenesis (void)
 
MagickPrivate void AnnotateComponentTerminus (void)
 
MagickExport MagickBooleanType AnnotateImage (Image *image, const DrawInfo *draw_info, ExceptionInfo *exception)
 
static char * ReplaceSpaceWithNewline (char **caption, char *space)
 
MagickExport ssize_t FormatMagickCaption (Image *image, DrawInfo *draw_info, const MagickBooleanType split, TypeMetric *metrics, char **caption, ExceptionInfo *exception)
 
MagickExport MagickBooleanType GetMultilineTypeMetrics (Image *image, const DrawInfo *draw_info, TypeMetric *metrics, ExceptionInfo *exception)
 
MagickExport MagickBooleanType GetTypeMetrics (Image *image, const DrawInfo *draw_info, TypeMetric *metrics, ExceptionInfo *exception)
 
static MagickBooleanType RenderFreetype (Image *image, const DrawInfo *draw_info, const char *magick_unused(encoding), const PointInfo *offset, TypeMetric *metrics, ExceptionInfo *exception)
 
static char * EscapeParenthesis (const char *source)
 

Variables

static SemaphoreInfoannotate_semaphore = (SemaphoreInfo *) NULL
 

Typedef Documentation

◆ GraphemeInfo

typedef struct _GraphemeInfo GraphemeInfo

Function Documentation

◆ AnnotateComponentGenesis()

MagickPrivate MagickBooleanType AnnotateComponentGenesis ( void  )

Definition at line 164 of file annotate.c.

References AcquireSemaphoreInfo(), annotate_semaphore, and MagickTrue.

Referenced by MagickCoreGenesis().

◆ AnnotateComponentTerminus()

MagickPrivate void AnnotateComponentTerminus ( void  )

Definition at line 189 of file annotate.c.

References ActivateSemaphoreInfo(), annotate_semaphore, and RelinquishSemaphoreInfo().

Referenced by MagickCoreTerminus().

◆ AnnotateImage()

MagickExport MagickBooleanType AnnotateImage ( Image image,
const DrawInfo draw_info,
ExceptionInfo exception 
)

Definition at line 223 of file annotate.c.

References AcquireQuantumMemory(), _DrawInfo::affine, _DrawInfo::align, AllCompliance, _PixelInfo::alpha, _TypeMetric::ascent, CenterAlign, CenterGravity, CloneDrawInfo(), CloneString(), _Image::colorspace, _DrawInfo::decorate, _TypeMetric::descent, DestroyDrawInfo(), DestroyString(), DirectClass, DrawImage(), EastGravity, _Image::filename, _DrawInfo::fill, FormatLocaleString(), _DrawInfo::geometry, GetMagickModule, GetTypeMetrics(), _DrawInfo::gravity, _RectangleInfo::height, _DrawInfo::interline_spacing, IsEventLogging(), IsGrayColorspace(), LeftAlign, LineThroughDecoration, LogMagickEvent(), MagickCoreSignature, MagickFalse, MagickPathExtent, MagickTrue, NorthEastGravity, NorthGravity, NorthWestGravity, _TypeMetric::origin, OverlineDecoration, _Image::page, ParseGeometry(), ParsePageGeometry(), _DrawInfo::pointsize, _DrawInfo::primitive, _GeometryInfo::psi, QueryColorname(), RelinquishMagickMemory(), RenderType(), RightAlign, _AffineMatrix::rx, _AffineMatrix::ry, SetGeometry(), SetGeometryInfo(), SetImageColorspace(), SetImageStorageClass(), _DrawInfo::signature, _Image::signature, SouthEastGravity, SouthGravity, SouthWestGravity, sRGBColorspace, _DrawInfo::stroke, _AffineMatrix::sx, _AffineMatrix::sy, _DrawInfo::text, TraceEvent, TransparentAlpha, _AffineMatrix::tx, _AffineMatrix::ty, UndefinedGravity, _DrawInfo::undercolor, _TypeMetric::underline_position, _TypeMetric::underline_thickness, UnderlineDecoration, WestGravity, _TypeMetric::width, _RectangleInfo::width, _PointInfo::x, _RectangleInfo::x, _GeometryInfo::xi, _PointInfo::y, and _RectangleInfo::y.

Referenced by DrawPrimitive(), MontageImageList(), and PolaroidImage().

◆ EscapeParenthesis()

static char * EscapeParenthesis ( const char *  source)
static

◆ FormatMagickCaption()

◆ GetMultilineTypeMetrics()

◆ GetTypeMetrics()

◆ RenderFreetype() [1/2]

static MagickBooleanType RenderFreetype ( Image ,
const DrawInfo ,
const char *  ,
const PointInfo ,
TypeMetric ,
ExceptionInfo  
)

Referenced by RenderType().

◆ RenderFreetype() [2/2]

static MagickBooleanType RenderFreetype ( Image image,
const DrawInfo draw_info,
const char *  magick_unusedencoding,
const PointInfo offset,
TypeMetric metrics,
ExceptionInfo exception 
)
static

◆ RenderPostscript()

static MagickBooleanType RenderPostscript ( Image image,
const DrawInfo draw_info,
const PointInfo offset,
TypeMetric metrics,
ExceptionInfo exception 
)

Definition at line 2070 of file annotate.c.

References AcquireAuthenticCacheView(), AcquireImageInfo(), AcquireUniqueFileResource(), _DrawInfo::affine, _PixelInfo::alpha, _Image::alpha_trait, AnnotateEvent, _ImageInfo::antialias, _TypeMetric::ascent, _PixelInfo::blue, _TypeMetric::bounds, CastDoubleToLong(), CatchException(), ClampToQuantum(), CloneString(), _Image::columns, CompositeImage(), _DrawInfo::debug, DefaultResolution, _DrawInfo::density, _ImageInfo::density, _TypeMetric::descent, DestroyCacheView(), DestroyImage(), DestroyImageInfo(), DestroyString(), EscapeParenthesis(), ExpandAffine(), _ImageInfo::filename, FileOpenError, _DrawInfo::fill, _DrawInfo::font, FormatLocaleFile(), FormatLocaleString(), GetCacheViewAuthenticPixels(), GetFillColor(), GetImageBoundingBox(), GetMagickModule, GetPixelChannels(), GetPixelIntensity(), _PixelInfo::green, _TypeMetric::height, _RectangleInfo::height, LogMagickEvent(), magick_restrict, MagickEpsilon, MagickFalse, MagickPathExtent, MagickTrue, _TypeMetric::max_advance, NegateImage(), OpaqueAlphaChannel, OverCompositeOp, _ImageInfo::page, ParseGeometry(), _TypeMetric::pixels_per_em, _DrawInfo::pointsize, QuantumScale, ReadImage(), _PixelInfo::red, RelinquishUniqueFileResource(), _DrawInfo::render, _GeometryInfo::rho, RhoValue, _Image::rows, _AffineMatrix::rx, _AffineMatrix::ry, SetImageAlphaChannel(), SetPixelAlpha(), SetPixelBlue(), SetPixelGreen(), SetPixelRed(), _GeometryInfo::sigma, SigmaValue, _AffineMatrix::sx, _AffineMatrix::sy, SyncCacheViewAuthenticPixels(), _DrawInfo::text, _DrawInfo::text_antialias, ThrowFileException, TransformImage(), TransparentAlpha, UndefinedPixelTrait, _TypeMetric::underline_position, _TypeMetric::underline_thickness, _TypeMetric::width, _RectangleInfo::width, _PointInfo::x, _RectangleInfo::x, _SegmentInfo::x1, _SegmentInfo::x2, _PointInfo::y, _RectangleInfo::y, _SegmentInfo::y1, and _SegmentInfo::y2.

Referenced by RenderFreetype(), and RenderType().

◆ RenderType()

◆ RenderX11()

static MagickBooleanType RenderX11 ( Image image,
const DrawInfo draw_info,
const PointInfo offset,
TypeMetric metrics,
ExceptionInfo exception 
)

◆ ReplaceSpaceWithNewline()

static char * ReplaceSpaceWithNewline ( char **  caption,
char *  space 
)
inlinestatic

Variable Documentation

◆ annotate_semaphore

SemaphoreInfo* annotate_semaphore = (SemaphoreInfo *) NULL
static

Definition at line 131 of file annotate.c.

Referenced by AnnotateComponentGenesis(), AnnotateComponentTerminus(), and RenderX11().