MagickCore 7.1.0
Convert, Edit, Or Compose Bitmap Images
|
#include "MagickCore/studio.h"
#include "MagickCore/blob.h"
#include "MagickCore/blob-private.h"
#include "MagickCore/cache.h"
#include "MagickCore/cache-private.h"
#include "MagickCore/color-private.h"
#include "MagickCore/colorspace-private.h"
#include "MagickCore/composite-private.h"
#include "MagickCore/distribute-cache-private.h"
#include "MagickCore/exception.h"
#include "MagickCore/exception-private.h"
#include "MagickCore/geometry.h"
#include "MagickCore/list.h"
#include "MagickCore/log.h"
#include "MagickCore/magick.h"
#include "MagickCore/memory_.h"
#include "MagickCore/memory-private.h"
#include "MagickCore/nt-base-private.h"
#include "MagickCore/option.h"
#include "MagickCore/pixel.h"
#include "MagickCore/pixel-accessor.h"
#include "MagickCore/policy.h"
#include "MagickCore/quantum.h"
#include "MagickCore/random_.h"
#include "MagickCore/registry.h"
#include "MagickCore/resource_.h"
#include "MagickCore/semaphore.h"
#include "MagickCore/splay-tree.h"
#include "MagickCore/string_.h"
#include "MagickCore/string-private.h"
#include "MagickCore/timer-private.h"
#include "MagickCore/thread-private.h"
#include "MagickCore/utility.h"
#include "MagickCore/utility-private.h"
Go to the source code of this file.
Data Structures | |
struct | _MagickModulo |
Macros | |
#define | CacheTick(offset, extent) QuantumTick((MagickOffsetType) offset,extent) |
#define | IsFileDescriptorLimitExceeded() |
#define | MaxCacheThreads ((size_t) GetMagickResourceLimit(ThreadResource)) |
#define | cache_number_threads(source, destination, chunk, multithreaded) |
Typedefs | |
typedef struct _MagickModulo | MagickModulo |
Variables | |
static SemaphoreInfo * | cache_semaphore = (SemaphoreInfo *) NULL |
static ssize_t | cache_anonymous_memory = (-1) |
static time_t | cache_epoch = 0 |
static ssize_t | DitherMatrix [64] |
#define cache_number_threads | ( | source, | |
destination, | |||
chunk, | |||
multithreaded | |||
) |
#define CacheTick | ( | offset, | |
extent | |||
) | QuantumTick((MagickOffsetType) offset,extent) |
#define IsFileDescriptorLimitExceeded | ( | ) |
#define MaxCacheThreads ((size_t) GetMagickResourceLimit(ThreadResource)) |
typedef struct _MagickModulo MagickModulo |
|
inlinestatic |
Definition at line 4968 of file cache.c.
References AcquireAlignedMemory(), cache_anonymous_memory, GetMagickModule, IOMode, MagickAssumeAligned, MagickFalse, MagickTrue, MapBlob(), ResourceLimitError, and ThrowMagickException().
Referenced by SetPixelCacheNexusPixels().
MagickPrivate Cache AcquirePixelCache | ( | const size_t | number_threads | ) |
Definition at line 187 of file cache.c.
References AcquireAlignedMemory(), AcquirePixelCacheNexus(), AcquireSemaphoreInfo(), CacheEvent, DestroyString(), GetEnvironmentValue(), GetLogEventMask(), GetMagickResourceLimit(), GetMagickThreadId(), GetOpenMPMaximumThreads(), GetPolicyValue(), HeightResource, IOMode, IsStringTrue(), magick_restrict, MAGICK_SSIZE_MAX, MagickCoreSignature, MagickFalse, MagickMin, MagickTrue, ResourceLimitFatalError, sRGBColorspace, ThreadResource, ThrowFatalException, UndefinedCache, and WidthResource.
Referenced by ClonePixelCache().
MagickPrivate NexusInfo ** AcquirePixelCacheNexus | ( | const size_t | number_threads | ) |
Definition at line 262 of file cache.c.
References AcquireAlignedMemory(), AcquireQuantumMemory(), magick_restrict, MagickAssumeAligned, MagickCoreSignature, ResourceLimitFatalError, and ThrowFatalException.
Referenced by AcquirePixelCache(), and ClonePixelCacheRepository().
MagickExport void * AcquirePixelCachePixels | ( | const Image * | image, |
size_t * | length, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 317 of file cache.c.
References _Image::cache, magick_restrict, MagickCoreSignature, MapCache, MemoryCache, _ExceptionInfo::signature, and _Image::signature.
Referenced by ResetImagePixels().
|
inlinestatic |
Definition at line 3394 of file cache.c.
References ClampToQuantum(), MagickEpsilon, MagickOver_(), PerceptibleReciprocal(), QuantumScale, and TransparentAlpha.
Referenced by MaskPixelCacheNexus().
MagickPrivate MagickBooleanType CacheComponentGenesis | ( | void | ) |
Definition at line 356 of file cache.c.
References AcquireSemaphoreInfo(), cache_semaphore, and MagickTrue.
MagickPrivate void CacheComponentTerminus | ( | void | ) |
Definition at line 381 of file cache.c.
References ActivateSemaphoreInfo(), cache_semaphore, and RelinquishSemaphoreInfo().
|
static |
Definition at line 418 of file cache.c.
References _Image::cache, _Image::channels, ClampToQuantum(), _Image::filename, GetAuthenticPixelCacheNexus(), GetMagickModule, GetPixelAlpha(), GetPixelChannelChannel(), GetPixelChannels(), GetPixelChannelTraits(), GetPixelWriteMask(), _RectangleInfo::height, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickEpsilon, MagickFalse, MagickOver_(), MagickTrue, _Image::number_channels, _NexusInfo::pixels, QuantumScale, _NexusInfo::region, SetPixelAlpha(), TraceEvent, UpdatePixelTrait, _NexusInfo::virtual_nexus, _RectangleInfo::width, WriteMaskChannel, _RectangleInfo::x, and _RectangleInfo::y.
Referenced by SyncAuthenticPixelCacheNexus().
MagickPrivate Cache ClonePixelCache | ( | const Cache | cache | ) |
Definition at line 506 of file cache.c.
References AcquirePixelCache(), GetMagickModule, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, and TraceEvent.
Referenced by GetImagePixelCache(), and PersistPixelCache().
MagickPrivate void ClonePixelCacheMethods | ( | Cache | clone, |
const Cache | cache | ||
) |
Definition at line 550 of file cache.c.
References GetMagickModule, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, and TraceEvent.
|
static |
Definition at line 597 of file cache.c.
References AcquireQuantumMemory(), IOMode, MagickFalse, MagickMaxBufferExtent, MagickMin, MagickTrue, OpenPixelCacheOnDisk(), ReadMode, RelinquishMagickMemory(), ResourceLimitFatalError, and ThrowFatalException.
Referenced by ClonePixelCacheRepository().
|
static |
Definition at line 661 of file cache.c.
References AcquirePixelCacheNexus(), CacheEvent, ClonePixelCacheOnDisk(), CommandOptionToMnemonic(), DestroyPixelCacheNexus(), DiskCache, FormatLocaleString(), GetMagickModule, GetOpenMPThreadId(), LogMagickEvent(), magick_restrict, MagickCacheOptions, MagickFalse, MagickMin, MagickPathExtent, MagickTrue, MapCache, MemoryCache, PingCache, ReadMode, ReadPixelCacheMetacontent(), ReadPixelCachePixels(), SetPixelCacheNexusPixels(), UndefinedPixelTrait, WriteMode, WritePixelCacheMetacontent(), and WritePixelCachePixels().
Referenced by GetImagePixelCache(), OpenPixelCache(), and PersistPixelCache().
|
static |
Definition at line 962 of file cache.c.
References _CacheInfo::file, FileResource, MagickFalse, MagickTrue, and RelinquishMagickResource().
Referenced by GetImagePixelCache(), OpenPixelCache(), OpenPixelCacheOnDisk(), ReadPixelCacheMetacontent(), ReadPixelCachePixels(), RelinquishPixelCachePixels(), WritePixelCacheMetacontent(), and WritePixelCachePixels().
|
inlinestatic |
Definition at line 1856 of file cache.c.
References _PixelInfo::alpha, AlphaPixelChannel, _Image::background_color, _PixelInfo::black, BlackPixelChannel, _PixelInfo::blue, BluePixelChannel, ClampToQuantum(), GetPixelChannelChannel(), GetPixelChannels(), _PixelInfo::green, GreenPixelChannel, MagickFalse, MagickTrue, _PixelInfo::red, and RedPixelChannel.
Referenced by GetOneAuthenticPixel(), GetOneAuthenticPixelFromCache(), GetOneVirtualPixel(), and GetOneVirtualPixelFromCache().
|
static |
Definition at line 887 of file cache.c.
References _Image::cache, DestroyPixelCache(), _Image::filename, GetMagickModule, IsEventLogging(), LogMagickEvent(), MagickCoreSignature, MagickFalse, _Image::signature, and TraceEvent.
Referenced by GetPixelCacheMethods().
MagickExport void DestroyImagePixels | ( | Image * | image | ) |
Definition at line 919 of file cache.c.
References _Image::cache, DestroyPixelCache(), _Image::filename, GetMagickModule, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, _Image::signature, and TraceEvent.
Referenced by DestroyImage().
MagickPrivate Cache DestroyPixelCache | ( | Cache | cache | ) |
Definition at line 1034 of file cache.c.
References CacheEvent, DestroyDistributeCacheInfo(), DestroyPixelCacheNexus(), DestroyRandomInfo(), FormatLocaleString(), GetMagickModule, IsEventLogging(), LockSemaphoreInfo(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, MagickPathExtent, RelinquishAlignedMemory(), RelinquishPixelCachePixels(), RelinquishSemaphoreInfo(), TraceEvent, and UnlockSemaphoreInfo().
Referenced by DestroyImagePixelCache(), DestroyImagePixels(), GetImagePixelCache(), and PersistPixelCache().
MagickPrivate NexusInfo ** DestroyPixelCacheNexus | ( | NexusInfo ** | nexus_info, |
const size_t | number_threads | ||
) |
Definition at line 1120 of file cache.c.
References RelinquishAlignedMemory(), RelinquishCacheNexusPixels(), RelinquishMagickMemory(), and _NexusInfo::signature.
Referenced by ClonePixelCacheRepository(), DestroyCacheView(), DestroyPixelCache(), and DestroyPixelStream().
|
inlinestatic |
Definition at line 2646 of file cache.c.
References DitherMatrix.
Referenced by GetVirtualPixelCacheNexus().
|
inlinestatic |
Definition at line 2659 of file cache.c.
References DitherMatrix.
Referenced by GetVirtualPixelCacheNexus().
|
inlinestatic |
Definition at line 2672 of file cache.c.
Referenced by GetVirtualPixelCacheNexus().
|
inlinestatic |
Definition at line 2681 of file cache.c.
Referenced by GetVirtualPixelCacheNexus().
MagickExport void * GetAuthenticMetacontent | ( | const Image * | image | ) |
Definition at line 1163 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, and _Image::signature.
|
static |
Definition at line 1214 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetPixelCacheMethods().
MagickPrivate Quantum * GetAuthenticPixelCacheNexus | ( | Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
const size_t | columns, | ||
const size_t | rows, | ||
NexusInfo * | nexus_info, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1331 of file cache.c.
References _NexusInfo::authentic_pixel_cache, _Image::cache, magick_restrict, MagickCoreSignature, MagickFalse, MagickTrue, QueueAuthenticPixelCacheNexus(), ReadPixelCacheMetacontent(), ReadPixelCachePixels(), and _Image::signature.
Referenced by ClipPixelCacheNexus(), GetAuthenticPixels(), GetAuthenticPixelsCache(), GetOneAuthenticPixelFromCache(), and MaskPixelCacheNexus().
MagickExport Quantum * GetAuthenticPixelQueue | ( | const Image * | image | ) |
Definition at line 1426 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by ExportQuantumPixels(), ImportQuantumPixels(), and StreamImagePixels().
MagickExport Quantum * GetAuthenticPixels | ( | Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
const size_t | columns, | ||
const size_t | rows, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1491 of file cache.c.
References _Image::cache, GetAuthenticPixelCacheNexus(), GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by ClearBounds(), ImportCharPixel(), ImportDoublePixel(), ImportFloatPixel(), ImportLongLongPixel(), ImportLongPixel(), ImportQuantumPixel(), and ImportShortPixel().
|
static |
Definition at line 1553 of file cache.c.
References _Image::cache, GetAuthenticPixelCacheNexus(), GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetOneAuthenticPixel(), and GetPixelCacheMethods().
Definition at line 1385 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetPixelCacheMethods().
MagickExport MagickSizeType GetImageExtent | ( | const Image * | image | ) |
Definition at line 1602 of file cache.c.
References _Image::cache, _Image::filename, GetMagickModule, GetOpenMPThreadId(), GetPixelCacheNexusExtent(), IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, _Image::signature, and TraceEvent.
Referenced by ExportQuantumPixels(), ImportQuantumPixels(), and StreamImagePixels().
|
static |
Definition at line 1681 of file cache.c.
References AcquireSemaphoreInfo(), _Image::cache, cache_epoch, ClonePixelCache(), ClonePixelCacheRepository(), ClosePixelCacheOnDisk(), DestroyPixelCache(), GetMagickResourceLimit(), GetMagickTime(), IOMode, LockSemaphoreInfo(), magick_restrict, MagickDelay(), MagickFalse, MagickResourceInfinity, MagickTrue, OpenPixelCache(), ReadMode, _Image::reference_count, RelinquishSemaphoreInfo(), ResourceLimitFatalError, _Image::semaphore, ThrottleResource, ThrowFatalException, TimeResource, _Image::type, UndefinedType, UnlockSemaphoreInfo(), and ValidatePixelCacheMorphology().
Referenced by QueueAuthenticPixelCacheNexus(), and SyncImagePixelCache().
MagickExport CacheType GetImagePixelCacheType | ( | const Image * | image | ) |
Definition at line 1812 of file cache.c.
References _Image::cache, magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetMagickNumberThreads(), GetPixelCacheTileSize(), and IdentifyImage().
MagickExport MagickBooleanType GetOneAuthenticPixel | ( | Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
Quantum * | pixel, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1883 of file cache.c.
References _Image::cache, CopyPixel(), GetAuthenticPixelsCache(), magick_restrict, MagickCoreSignature, MaxPixelChannels, and _Image::signature.
|
static |
Definition at line 1935 of file cache.c.
References _Image::cache, CopyPixel(), GetAuthenticPixelCacheNexus(), GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, MaxPixelChannels, and _Image::signature.
Referenced by GetPixelCacheMethods().
MagickExport MagickBooleanType GetOneVirtualPixel | ( | const Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
Quantum * | pixel, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1990 of file cache.c.
References _Image::cache, CopyPixel(), GetOpenMPThreadId(), GetPixelCacheVirtualMethod(), GetVirtualPixelCacheNexus(), magick_restrict, MagickCoreSignature, MaxPixelChannels, and _Image::signature.
Referenced by CompositeImage(), and CompositeOverImage().
static MagickBooleanType GetOneVirtualPixelFromCache | ( | const Image * | image, |
const VirtualPixelMethod | virtual_pixel_method, | ||
const ssize_t | x, | ||
const ssize_t | y, | ||
Quantum * | pixel, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 2052 of file cache.c.
References _Image::cache, CopyPixel(), GetOpenMPThreadId(), GetVirtualPixelCacheNexus(), magick_restrict, MagickCoreSignature, MaxPixelChannels, and _Image::signature.
Referenced by GetPixelCacheMethods().
MagickExport MagickBooleanType GetOneVirtualPixelInfo | ( | const Image * | image, |
const VirtualPixelMethod | virtual_pixel_method, | ||
const ssize_t | x, | ||
const ssize_t | y, | ||
PixelInfo * | pixel, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 2111 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), GetPixelInfo(), GetPixelInfoPixel(), GetVirtualPixelCacheNexus(), magick_restrict, MagickCoreSignature, MagickFalse, MagickTrue, and _Image::signature.
Referenced by DrawPrimitive(), GetFillColor(), and GetStrokeColor().
MagickPrivate ColorspaceType GetPixelCacheColorspace | ( | const Cache | cache | ) |
Definition at line 2161 of file cache.c.
References GetMagickModule, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, and TraceEvent.
Referenced by GetCacheViewColorspace().
MagickExport const char * GetPixelCacheFilename | ( | const Image * | image | ) |
Definition at line 2198 of file cache.c.
References _Image::cache, magick_restrict, MagickCoreSignature, and _Image::signature.
MagickPrivate void GetPixelCacheMethods | ( | CacheMethods * | cache_methods | ) |
Definition at line 2233 of file cache.c.
References _CacheMethods::destroy_pixel_handler, DestroyImagePixelCache(), _CacheMethods::get_authentic_metacontent_from_handler, _CacheMethods::get_authentic_pixels_from_handler, _CacheMethods::get_authentic_pixels_handler, _CacheMethods::get_one_authentic_pixel_from_handler, _CacheMethods::get_one_virtual_pixel_from_handler, _CacheMethods::get_virtual_metacontent_from_handler, _CacheMethods::get_virtual_pixel_handler, _CacheMethods::get_virtual_pixels_handler, GetAuthenticMetacontentFromCache(), GetAuthenticPixelsCache(), GetAuthenticPixelsFromCache(), GetOneAuthenticPixelFromCache(), GetOneVirtualPixelFromCache(), GetVirtualMetacontentFromCache(), GetVirtualPixelCache(), GetVirtualPixelsCache(), _CacheMethods::queue_authentic_pixels_handler, QueueAuthenticPixelsCache(), _CacheMethods::sync_authentic_pixels_handler, and SyncAuthenticPixelsCache().
MagickPrivate MagickSizeType GetPixelCacheNexusExtent | ( | const Cache | cache, |
NexusInfo *magick_restrict | nexus_info | ||
) |
Definition at line 2278 of file cache.c.
References magick_restrict, and MagickCoreSignature.
Referenced by GetImageExtent().
MagickExport void * GetPixelCachePixels | ( | Image * | image, |
MagickSizeType * | length, | ||
ExceptionInfo * | magick_unusedexception | ||
) |
Definition at line 2323 of file cache.c.
References _Image::cache, magick_restrict, magick_unreferenced, MagickCoreSignature, MapCache, MemoryCache, and _Image::signature.
MagickPrivate ClassType GetPixelCacheStorageClass | ( | const Cache | cache | ) |
Definition at line 2366 of file cache.c.
References GetMagickModule, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, and TraceEvent.
Referenced by GetCacheViewStorageClass().
MagickPrivate void GetPixelCacheTileSize | ( | const Image * | image, |
size_t * | width, | ||
size_t * | height | ||
) |
Definition at line 2407 of file cache.c.
References _Image::cache, DiskCache, _Image::filename, GetImagePixelCacheType(), GetMagickModule, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, MagickMax, _Image::signature, and TraceEvent.
MagickPrivate VirtualPixelMethod GetPixelCacheVirtualMethod | ( | const Image * | image | ) |
Definition at line 2449 of file cache.c.
References _Image::cache, magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetOneVirtualPixel(), and GetVirtualPixels().
MagickExport const void * GetVirtualMetacontent | ( | const Image * | image | ) |
Definition at line 2571 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), GetVirtualMetacontentFromNexus(), magick_restrict, MagickCoreSignature, and _Image::signature.
|
static |
Definition at line 2485 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), GetVirtualMetacontentFromNexus(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetPixelCacheMethods().
MagickPrivate const void * GetVirtualMetacontentFromNexus | ( | const Cache | cache, |
NexusInfo *magick_restrict | nexus_info | ||
) |
Definition at line 2533 of file cache.c.
References magick_restrict, MagickCoreSignature, and UndefinedClass.
Referenced by GetVirtualMetacontent(), GetVirtualMetacontentFromCache(), and GetVirtualPixelCacheNexus().
|
static |
Definition at line 3141 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), GetVirtualPixelCacheNexus(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetPixelCacheMethods().
MagickPrivate const Quantum * GetVirtualPixelCacheNexus | ( | const Image * | image, |
const VirtualPixelMethod | virtual_pixel_method, | ||
const ssize_t | x, | ||
const ssize_t | y, | ||
const size_t | columns, | ||
const size_t | rows, | ||
NexusInfo * | nexus_info, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 2721 of file cache.c.
References AcquireQuantumMemory(), AcquireRandomInfo(), _PixelInfo::alpha, _NexusInfo::authentic_pixel_cache, _Image::background_color, BackgroundVirtualPixelMethod, _PixelInfo::black, BlackVirtualPixelMethod, _PixelInfo::blue, _Image::cache, CacheError, _Image::channels, CheckerTileVirtualPixelMethod, ClampToQuantum(), CompositeMaskChannel, DitherVirtualPixelMethod, DitherX(), DitherY(), EdgeVirtualPixelMethod, EdgeX(), EdgeY(), _Image::filename, GetMagickModule, GetVirtualMetacontentFromNexus(), GetVirtualPixelCacheNexus(), GrayVirtualPixelMethod, _PixelInfo::green, _RectangleInfo::height, HorizontalTileEdgeVirtualPixelMethod, HorizontalTileVirtualPixelMethod, magick_restrict, MagickCoreSignature, MagickFalse, MagickMin, MagickTrue, MaskVirtualPixelMethod, MaxPixelChannels, _NexusInfo::metacontent, MirrorVirtualPixelMethod, OpaqueAlpha, QuantumRange, _MagickModulo::quotient, RandomVirtualPixelMethod, RandomX(), RandomY(), ReadMode, ReadPixelCacheMetacontent(), ReadPixelCachePixels(), _PixelInfo::red, _NexusInfo::region, RelinquishMagickMemory(), _MagickModulo::remainder, SetPixelAlpha(), SetPixelBlack(), SetPixelBlue(), SetPixelCacheNexusPixels(), SetPixelChannel(), SetPixelGreen(), SetPixelRed(), _Image::signature, ThrowMagickException(), TileVirtualPixelMethod, TransparentAlpha, TransparentVirtualPixelMethod, UndefinedCache, UndefinedVirtualPixelMethod, VerticalTileEdgeVirtualPixelMethod, VerticalTileVirtualPixelMethod, _NexusInfo::virtual_nexus, VirtualPixelModulo(), WhiteVirtualPixelMethod, _RectangleInfo::width, WriteMaskChannel, _RectangleInfo::x, and _RectangleInfo::y.
Referenced by GetOneVirtualPixel(), GetOneVirtualPixelFromCache(), GetOneVirtualPixelInfo(), GetVirtualPixelCache(), GetVirtualPixelCacheNexus(), and GetVirtualPixels().
MagickExport const Quantum * GetVirtualPixelQueue | ( | const Image * | image | ) |
Definition at line 3188 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), GetVirtualPixelsNexus(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by ExportQuantumPixels().
MagickExport const Quantum * GetVirtualPixels | ( | const Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
const size_t | columns, | ||
const size_t | rows, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 3256 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), GetPixelCacheVirtualMethod(), GetVirtualPixelCacheNexus(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by CompareImagesBounds(), ExportCharPixel(), ExportDoublePixel(), ExportFloatPixel(), ExportLongLongPixel(), ExportLongPixel(), ExportQuantumPixel(), ExportShortPixel(), GetImageDynamicThreshold(), GetImageStatistics(), GetLocationStatistics(), HuffmanEncodeImage(), IdentifyImage(), InitializeHistogram(), IsBoundsCleared(), PrintChannelLocations(), and StereoAnaglyphImage().
Definition at line 3307 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), GetVirtualPixelsNexus(), magick_restrict, MagickCoreSignature, and _Image::signature.
Referenced by GetPixelCacheMethods().
MagickPrivate const Quantum * GetVirtualPixelsNexus | ( | const Cache | cache, |
NexusInfo *magick_restrict | nexus_info | ||
) |
Definition at line 3350 of file cache.c.
References magick_restrict, MagickCoreSignature, and UndefinedClass.
Referenced by GetVirtualPixelQueue(), and GetVirtualPixelsCache().
|
static |
Definition at line 3407 of file cache.c.
References ApplyPixelCompositeMask(), _Image::cache, _Image::channels, CompositeMaskChannel, _Image::filename, GetAuthenticPixelCacheNexus(), GetMagickModule, GetPixelAlpha(), GetPixelChannelChannel(), GetPixelChannels(), GetPixelChannelTraits(), GetPixelCompositeMask(), _RectangleInfo::height, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickFalse, MagickTrue, _Image::number_channels, _NexusInfo::pixels, _NexusInfo::region, TraceEvent, UpdatePixelTrait, _NexusInfo::virtual_nexus, _RectangleInfo::width, _RectangleInfo::x, and _RectangleInfo::y.
Referenced by SyncAuthenticPixelCacheNexus().
static MagickBooleanType OpenPixelCache | ( | Image * | image, |
const MapMode | mode, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 3630 of file cache.c.
References AcquireAlignedMemory(), AcquireDistributeCacheInfo(), AcquireMagickResource(), _Image::alpha_trait, AreaResource, _Image::cache, cache_anonymous_memory, CacheError, CacheEvent, _Image::channel_map, _Image::channels, ClonePixelCacheRepository(), ClosePixelCacheOnDisk(), _Image::colorspace, _Image::columns, CommandOptionToMnemonic(), DestroyDistributeCacheInfo(), DestroyString(), DiskCache, DiskResource, DistributedCache, _Image::filename, FormatLocaleString(), FormatMagickSize(), GetDistributeCacheFile(), GetDistributeCacheHostname(), GetDistributeCachePort(), GetImageListLength(), GetImageRegistry(), GetMagickModule, GetMagickResourceLimit(), GetPixelChannels(), GetPolicyValue(), ImageError, InitializePixelChannelMap(), IOMode, IsEventLogging(), ListLengthResource, LocaleCompare(), LogMagickEvent(), magick_restrict, MagickAssumeAligned, MagickCacheOptions, MagickCoreSignature, MagickFalse, MagickMax, MagickPathExtent, MagickResourceInfinity, MagickTrue, MapBlob(), MapCache, MapResource, MaxPixelChannels, MemoryCache, MemoryResource, _Image::metacontent_extent, MissingDelegateError, _Image::offset, OpenDistributePixelCache(), OpenPixelCacheOnDisk(), PersistMode, _Image::ping, PingCache, ReadMode, RelinquishMagickResource(), RelinquishPixelCachePixels(), ResourceLimitError, _Image::rows, _Image::scene, SetPixelCacheExtent(), _Image::signature, _Image::storage_class, StringRegistryType, ThrowBinaryException, ThrowFileException, ThrowMagickException(), TraceEvent, UndefinedCache, and UndefinedClass.
Referenced by GetImagePixelCache(), and PersistPixelCache().
static MagickBooleanType OpenPixelCacheOnDisk | ( | CacheInfo * | cache_info, |
const MapMode | mode | ||
) |
Definition at line 3498 of file cache.c.
References AcquireMagickResource(), AcquireUniqueFileResource(), _CacheInfo::cache_filename, ClosePixelCacheOnDisk(), _CacheInfo::disk_mode, _CacheInfo::file, FileResource, IOMode, MagickFalse, MagickTrue, O_BINARY, open_utf8(), ReadMode, S_MODE, and WriteMode.
Referenced by ClonePixelCacheOnDisk(), OpenPixelCache(), PersistPixelCache(), ReadPixelCacheMetacontent(), ReadPixelCachePixels(), WritePixelCacheMetacontent(), and WritePixelCachePixels().
MagickExport MagickBooleanType PersistPixelCache | ( | Image * | image, |
const char * | filename, | ||
const MagickBooleanType | attach, | ||
MagickOffsetType * | offset, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 4031 of file cache.c.
References AcquireMagickResource(), _Image::cache, CacheError, CacheEvent, ClonePixelCache(), ClonePixelCacheRepository(), CopyMagickString(), DestroyPixelCache(), DiskCache, DiskResource, _Image::filename, GetMagickModule, GetMagickPageSize(), IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, MagickPathExtent, MagickTrue, MapCache, MaxPixelChannels, OpenPixelCache(), OpenPixelCacheOnDisk(), PersistMode, ReadMode, _Image::signature, ThrowMagickException(), TraceEvent, and WriteMode.
|
inlinestatic |
Definition at line 5005 of file cache.c.
References CACHE_LINE_SIZE, _NexusInfo::length, MagickCachePrefetch, _NexusInfo::pixels, and ReadMode.
Referenced by SetPixelCacheNexusPixels().
MagickPrivate Quantum * QueueAuthenticPixelCacheNexus | ( | Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
const size_t | columns, | ||
const size_t | rows, | ||
const MagickBooleanType | clone, | ||
NexusInfo * | nexus_info, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 4148 of file cache.c.
References _Image::cache, CacheError, _Image::channels, CompositeMaskChannel, _Image::filename, GetImagePixelCache(), GetMagickModule, magick_restrict, MagickCoreSignature, MagickFalse, MagickTrue, SetPixelCacheNexusPixels(), _Image::signature, ThrowMagickException(), WriteMaskChannel, and WriteMode.
Referenced by GetAuthenticPixelCacheNexus(), QueueAuthenticPixels(), QueueAuthenticPixelsCache(), and QueueCacheViewAuthenticPixels().
MagickExport Quantum * QueueAuthenticPixels | ( | Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
const size_t | columns, | ||
const size_t | rows, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 4312 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, MagickFalse, QueueAuthenticPixelCacheNexus(), and _Image::signature.
Referenced by StereoAnaglyphImage().
static Quantum * QueueAuthenticPixelsCache | ( | Image * | image, |
const ssize_t | x, | ||
const ssize_t | y, | ||
const size_t | columns, | ||
const size_t | rows, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 4232 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, MagickFalse, QueueAuthenticPixelCacheNexus(), and _Image::signature.
Referenced by GetPixelCacheMethods().
|
inlinestatic |
Definition at line 2690 of file cache.c.
References GetPseudoRandomValue(), and random_info.
Referenced by GetVirtualPixelCacheNexus().
|
inlinestatic |
Definition at line 2695 of file cache.c.
References GetPseudoRandomValue(), and random_info.
Referenced by GetVirtualPixelCacheNexus().
|
static |
Definition at line 4406 of file cache.c.
References CacheError, CacheEvent, CacheTick, ClosePixelCacheOnDisk(), DiskCache, DistributedCache, FileOpenError, GetMagickModule, _RectangleInfo::height, IOMode, IsFileDescriptorLimitExceeded, LockSemaphoreInfo(), LogMagickEvent(), magick_restrict, MagickFalse, MagickMaxBufferExtent, MagickTrue, MapCache, MemoryCache, OpenPixelCacheOnDisk(), ReadDistributePixelCacheMetacontent(), ReadPixelCacheRegion(), ThrowFileException, UnlockSemaphoreInfo(), and _RectangleInfo::y.
static MagickBooleanType ReadPixelCacheMetacontent | ( | CacheInfo * | magick_restrict, |
NexusInfo * | magick_restrict, | ||
ExceptionInfo * | |||
) |
Referenced by ClonePixelCacheRepository(), GetAuthenticPixelCacheNexus(), and GetVirtualPixelCacheNexus().
|
static |
Definition at line 4577 of file cache.c.
References CacheError, CacheEvent, CacheTick, ClosePixelCacheOnDisk(), DiskCache, DistributedCache, FileOpenError, GetMagickModule, _RectangleInfo::height, IOMode, IsFileDescriptorLimitExceeded, LockSemaphoreInfo(), LogMagickEvent(), magick_restrict, MagickFalse, MagickMaxBufferExtent, MagickTrue, MapCache, MemoryCache, OpenPixelCacheOnDisk(), ReadDistributePixelCachePixels(), ReadPixelCacheRegion(), ThrowFileException, UnlockSemaphoreInfo(), and _RectangleInfo::y.
static MagickBooleanType ReadPixelCachePixels | ( | CacheInfo * | magick_restrict, |
NexusInfo * | magick_restrict, | ||
ExceptionInfo * | |||
) |
Referenced by ClonePixelCacheRepository(), GetAuthenticPixelCacheNexus(), and GetVirtualPixelCacheNexus().
|
inlinestatic |
Definition at line 4372 of file cache.c.
References MAGICK_SSIZE_MAX, and MagickMin.
Referenced by ReadPixelCacheMetacontent(), and ReadPixelCachePixels().
MagickPrivate Cache ReferencePixelCache | ( | Cache | cache | ) |
Definition at line 4746 of file cache.c.
References LockSemaphoreInfo(), magick_restrict, MagickCoreSignature, and UnlockSemaphoreInfo().
Referenced by CloneImage(), and CloneImageInfo().
|
inlinestatic |
Definition at line 1107 of file cache.c.
References _NexusInfo::cache, _NexusInfo::length, MagickFalse, _NexusInfo::mapped, _NexusInfo::metacontent, _NexusInfo::pixels, RelinquishAlignedMemory(), and UnmapBlob().
Referenced by DestroyPixelCacheNexus(), and SetPixelCacheNexusPixels().
|
inlinestatic |
Definition at line 977 of file cache.c.
References _CacheInfo::cache_filename, ClosePixelCacheOnDisk(), DiskCache, DiskResource, DistributedCache, _CacheInfo::file, _CacheInfo::length, MagickFalse, MagickTrue, MapCache, _CacheInfo::mapped, MapResource, MemoryCache, MemoryResource, _CacheInfo::metacontent, _CacheInfo::mode, _CacheInfo::opencl, PersistMode, _CacheInfo::pixels, ReadMode, RelinquishAlignedMemory(), RelinquishDistributePixelCache(), RelinquishMagickResource(), RelinquishUniqueFileResource(), _CacheInfo::server_info, _CacheInfo::type, UndefinedCache, and UnmapBlob().
Referenced by DestroyPixelCache(), and OpenPixelCache().
MagickPrivate void ResetCacheAnonymousMemory | ( | void | ) |
Definition at line 4813 of file cache.c.
References cache_anonymous_memory.
MagickPrivate void ResetPixelCacheChannels | ( | Image * | image | ) |
Definition at line 4782 of file cache.c.
References _Image::cache, GetPixelChannels(), magick_restrict, MagickCoreSignature, and _Image::signature.
MagickPrivate void ResetPixelCacheEpoch | ( | void | ) |
Definition at line 4836 of file cache.c.
References cache_epoch.
|
static |
Definition at line 5157 of file cache.c.
References AcquireVirtualCacheView(), _Image::alpha_trait, BlendPixelTrait, _Image::cache, _Image::columns, DestroyCacheView(), _Image::filename, GetCacheViewAuthenticPixels(), GetMagickModule, GetPixelChannels(), IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, MagickTrue, _Image::rows, SetPixelAlpha(), _Image::signature, SyncCacheViewAuthenticPixels(), and TraceEvent.
Referenced by SetPixelCacheVirtualMethod().
|
static |
Definition at line 3581 of file cache.c.
References _Image::cache, CacheEvent, FormatLocaleString(), FormatMagickSize(), GetMagickModule, LogMagickEvent(), magick_restrict, MagickFalse, MagickPathExtent, MagickTrue, and WritePixelCacheRegion().
Referenced by OpenPixelCache().
MagickPrivate void SetPixelCacheMethods | ( | Cache | cache, |
CacheMethods * | cache_methods | ||
) |
Definition at line 4865 of file cache.c.
References _CacheMethods::destroy_pixel_handler, _CacheMethods::get_authentic_metacontent_from_handler, _CacheMethods::get_authentic_pixels_from_handler, _CacheMethods::get_authentic_pixels_handler, _CacheMethods::get_one_authentic_pixel_from_handler, _CacheMethods::get_one_virtual_pixel_from_handler, _CacheMethods::get_virtual_metacontent_from_handler, _CacheMethods::get_virtual_pixel_handler, GetMagickModule, IsEventLogging(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, _CacheMethods::queue_authentic_pixels_handler, _CacheMethods::sync_authentic_pixels_handler, and TraceEvent.
Referenced by ReadStream().
|
static |
Definition at line 5029 of file cache.c.
References AcquireCacheNexusPixels(), CacheError, GetMagickModule, ImageError, MagickCoreSignature, MagickFalse, MagickMax, MagickTrue, MapCache, MemoryCache, _CacheInfo::metacontent, PingCache, PrefetchPixelCacheNexusPixels(), RelinquishCacheNexusPixels(), ThrowMagickException(), UndefinedCache, and ValidatePixelOffset().
static Quantum * SetPixelCacheNexusPixels | ( | const CacheInfo * | magick_restrict, |
const | MapMode, | ||
const | ssize_t, | ||
const | ssize_t, | ||
const | size_t, | ||
const | size_t, | ||
const | MagickBooleanType, | ||
NexusInfo * | magick_restrict, | ||
ExceptionInfo * | |||
) |
Referenced by ClonePixelCacheRepository(), GetVirtualPixelCacheNexus(), and QueueAuthenticPixelCacheNexus().
MagickPrivate VirtualPixelMethod SetPixelCacheVirtualMethod | ( | Image * | image, |
const VirtualPixelMethod | virtual_pixel_method, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 5213 of file cache.c.
References _Image::alpha_trait, _PixelInfo::alpha_trait, _Image::background_color, BackgroundVirtualPixelMethod, _Image::cache, _Image::colorspace, _Image::columns, _Image::filename, GetMagickModule, IsEventLogging(), IsGrayColorspace(), IsPixelInfoGray(), LogMagickEvent(), magick_restrict, MagickCoreSignature, MagickFalse, OpaqueAlpha, _Image::rows, SetCacheAlphaChannel(), SetImageColorspace(), _Image::signature, sRGBColorspace, TraceEvent, TransparentVirtualPixelMethod, and UndefinedPixelTrait.
Referenced by SetImageVirtualPixelMethod().
MagickPrivate MagickBooleanType SyncAuthenticPixelCacheNexus | ( | Image * | image, |
NexusInfo *magick_restrict | nexus_info, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 5336 of file cache.c.
References _Image::cache, CacheError, _Image::channels, ClipPixelCacheNexus(), CompositeMaskChannel, _Image::filename, magick_restrict, MagickCoreSignature, MagickFalse, MagickTrue, _Image::mask_trait, MaskPixelCacheNexus(), _Image::signature, _Image::taint, ThrowBinaryException, UndefinedCache, UpdatePixelTrait, WriteMaskChannel, WritePixelCacheMetacontent(), and WritePixelCachePixels().
Referenced by SyncAuthenticPixels(), and SyncAuthenticPixelsCache().
MagickExport MagickBooleanType SyncAuthenticPixels | ( | Image * | image, |
ExceptionInfo * | exception | ||
) |
Definition at line 5458 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, _Image::signature, and SyncAuthenticPixelCacheNexus().
Referenced by ClearBounds(), ImportCharPixel(), ImportDoublePixel(), ImportFloatPixel(), ImportLongLongPixel(), ImportLongPixel(), ImportQuantumPixel(), ImportShortPixel(), and StereoAnaglyphImage().
static MagickBooleanType SyncAuthenticPixelsCache | ( | Image * | image, |
ExceptionInfo * | exception | ||
) |
Definition at line 5408 of file cache.c.
References _Image::cache, GetOpenMPThreadId(), magick_restrict, MagickCoreSignature, _Image::signature, and SyncAuthenticPixelCacheNexus().
Referenced by GetPixelCacheMethods().
MagickPrivate MagickBooleanType SyncImagePixelCache | ( | Image * | image, |
ExceptionInfo * | exception | ||
) |
Definition at line 5514 of file cache.c.
References GetImagePixelCache(), magick_restrict, MagickFalse, and MagickTrue.
Referenced by SetImageAlphaChannel(), SetImageColorspace(), SetImageExtent(), SetImageGray(), SetImageMask(), SetImageMonochrome(), SetImageRegionMask(), SetImageStorageClass(), and SetPixelMetaChannels().
|
inlinestatic |
Definition at line 1651 of file cache.c.
References magick_restrict, MagickFalse, and MagickTrue.
Referenced by GetImagePixelCache().
|
inlinestatic |
Definition at line 5019 of file cache.c.
References MAGICK_SSIZE_MAX, MAGICK_SSIZE_MIN, MagickFalse, and MagickTrue.
Referenced by SetPixelCacheNexusPixels().
|
inlinestatic |
Definition at line 2700 of file cache.c.
References _MagickModulo::quotient, and _MagickModulo::remainder.
Referenced by GetVirtualPixelCacheNexus().
static MagickBooleanType WritePixelCacheMetacontent | ( | CacheInfo * | , |
NexusInfo * | magick_restrict, | ||
ExceptionInfo * | |||
) |
Referenced by ClonePixelCacheRepository(), and SyncAuthenticPixelCacheNexus().
|
static |
Definition at line 5554 of file cache.c.
References _CacheInfo::cache_filename, CacheError, CacheEvent, CacheTick, ClosePixelCacheOnDisk(), _CacheInfo::columns, _CacheInfo::debug, DiskCache, DistributedCache, _CacheInfo::file_semaphore, _CacheInfo::filename, FileOpenError, GetMagickModule, _RectangleInfo::height, IOMode, IsFileDescriptorLimitExceeded, LockSemaphoreInfo(), LogMagickEvent(), magick_restrict, MagickFalse, MagickMaxBufferExtent, MagickTrue, MapCache, MemoryCache, _CacheInfo::metacontent, _CacheInfo::metacontent_extent, _CacheInfo::number_channels, _CacheInfo::offset, OpenPixelCacheOnDisk(), _CacheInfo::rows, _CacheInfo::server_info, ThrowFileException, _CacheInfo::type, UnlockSemaphoreInfo(), WriteDistributePixelCacheMetacontent(), WritePixelCacheRegion(), and _RectangleInfo::y.
|
static |
Definition at line 5724 of file cache.c.
References CacheError, CacheEvent, CacheTick, ClosePixelCacheOnDisk(), DiskCache, DistributedCache, FileOpenError, GetMagickModule, _RectangleInfo::height, IOMode, IsFileDescriptorLimitExceeded, LockSemaphoreInfo(), LogMagickEvent(), magick_restrict, MagickFalse, MagickMaxBufferExtent, MagickTrue, MapCache, MemoryCache, OpenPixelCacheOnDisk(), ThrowFileException, UnlockSemaphoreInfo(), WriteDistributePixelCachePixels(), WritePixelCacheRegion(), and _RectangleInfo::y.
static MagickBooleanType WritePixelCachePixels | ( | CacheInfo * | magick_restrict, |
NexusInfo * | magick_restrict, | ||
ExceptionInfo * | |||
) |
Referenced by ClonePixelCacheRepository(), and SyncAuthenticPixelCacheNexus().
|
inlinestatic |
Definition at line 3547 of file cache.c.
References MAGICK_SSIZE_MAX, and MagickMin.
Referenced by SetPixelCacheExtent(), WritePixelCacheMetacontent(), and WritePixelCachePixels().
|
static |
Definition at line 160 of file cache.c.
Referenced by AcquireCacheNexusPixels(), OpenPixelCache(), and ResetCacheAnonymousMemory().
|
static |
Definition at line 163 of file cache.c.
Referenced by GetImagePixelCache(), and ResetPixelCacheEpoch().
|
static |
Definition at line 157 of file cache.c.
Referenced by CacheComponentGenesis(), and CacheComponentTerminus().
|
static |