MagickCore
7.0.0
|
#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/composite-private.h"
#include "MagickCore/constitute.h"
#include "MagickCore/exception.h"
#include "MagickCore/exception-private.h"
#include "MagickCore/geometry.h"
#include "MagickCore/memory_.h"
#include "MagickCore/memory-private.h"
#include "MagickCore/pixel.h"
#include "MagickCore/pixel-accessor.h"
#include "MagickCore/quantum.h"
#include "MagickCore/quantum-private.h"
#include "MagickCore/semaphore.h"
#include "MagickCore/stream.h"
#include "MagickCore/stream-private.h"
#include "MagickCore/string_.h"
Go to the source code of this file.
Data Structures | |
struct | _StreamInfo |
Functions | |
static const Quantum * | GetVirtualPixelStream (const Image *, const VirtualPixelMethod, const ssize_t, const ssize_t, const size_t, const size_t, ExceptionInfo *) |
static MagickBooleanType | StreamImagePixels (const StreamInfo *, const Image *, ExceptionInfo *) |
static MagickBooleanType | SyncAuthenticPixelsStream (Image *, ExceptionInfo *) |
static Quantum * | QueueAuthenticPixelsStream (Image *, const ssize_t, const ssize_t, const size_t, const size_t, ExceptionInfo *) |
MagickExport StreamInfo * | AcquireStreamInfo (const ImageInfo *image_info, ExceptionInfo *exception) |
static void | RelinquishStreamPixels (CacheInfo *cache_info) |
static void | DestroyPixelStream (Image *image) |
MagickExport StreamInfo * | DestroyStreamInfo (StreamInfo *stream_info) |
static void * | GetAuthenticMetacontentFromStream (const Image *image) |
static Quantum * | GetAuthenticPixelsStream (Image *image, const ssize_t x, const ssize_t y, const size_t columns, const size_t rows, ExceptionInfo *exception) |
static Quantum * | GetAuthenticPixelsFromStream (const Image *image) |
static MagickBooleanType | GetOneAuthenticPixelFromStream (Image *image, const ssize_t x, const ssize_t y, Quantum *pixel, ExceptionInfo *exception) |
static MagickBooleanType | GetOneVirtualPixelFromStream (const Image *image, const VirtualPixelMethod virtual_pixel_method, const ssize_t x, const ssize_t y, Quantum *pixel, ExceptionInfo *exception) |
MagickPrivate const void * | GetStreamInfoClientData (StreamInfo *stream_info) |
static const Quantum * | GetVirtualPixelsStream (const Image *image) |
static const void * | GetVirtualMetacontentFromStream (const Image *image) |
static MagickBooleanType | AcquireStreamPixels (CacheInfo *cache_info, ExceptionInfo *exception) |
static const Quantum * | GetVirtualPixelStream (const Image *image, const VirtualPixelMethod magick_unused(virtual_pixel_method), const ssize_t x, const ssize_t y, const size_t columns, const size_t rows, ExceptionInfo *exception) |
MagickExport MagickBooleanType | OpenStream (const ImageInfo *image_info, StreamInfo *stream_info, const char *filename, ExceptionInfo *exception) |
MagickExport Image * | ReadStream (const ImageInfo *image_info, StreamHandler stream, ExceptionInfo *exception) |
MagickPrivate void | SetStreamInfoClientData (StreamInfo *stream_info, const void *client_data) |
MagickExport void | SetStreamInfoMap (StreamInfo *stream_info, const char *map) |
MagickExport void | SetStreamInfoStorageType (StreamInfo *stream_info, const StorageType storage_type) |
static size_t | WriteStreamImage (const Image *image, const void *pixels, const size_t columns) |
MagickExport Image * | StreamImage (const ImageInfo *image_info, StreamInfo *stream_info, ExceptionInfo *exception) |
MagickExport MagickBooleanType | WriteStream (const ImageInfo *image_info, Image *image, StreamHandler stream, ExceptionInfo *exception) |
MagickExport StreamInfo* AcquireStreamInfo | ( | const ImageInfo * | image_info, |
ExceptionInfo * | exception | ||
) |
Definition at line 155 of file stream.c.
References AcquireAlignedMemory(), AcquireImage(), AcquireMagickMemory(), CharPixel, ConstantString(), MagickAssumeAligned, MagickSignature, _StreamInfo::map, _StreamInfo::pixels, ResetMagickMemory(), ResourceLimitFatalError, _StreamInfo::signature, _StreamInfo::storage_type, _StreamInfo::stream, and ThrowFatalException.
|
inlinestatic |
Definition at line 680 of file stream.c.
References AcquireAlignedMemory(), _CacheInfo::filename, GetMagickModule, IOMode, _CacheInfo::length, MagickFalse, MagickTrue, MapBlob(), _CacheInfo::mapped, _CacheInfo::pixels, ResourceLimitError, and ThrowMagickException().
Referenced by GetVirtualPixelStream(), and QueueAuthenticPixelsStream().
|
static |
Definition at line 212 of file stream.c.
References _Image::cache, _Image::debug, DestroyPixelCacheNexus(), DestroySemaphoreInfo(), _CacheInfo::file_semaphore, _Image::filename, GetMagickModule, LockSemaphoreInfo(), LogMagickEvent(), MagickFalse, MagickSignature, MagickTrue, _CacheInfo::nexus_info, _CacheInfo::number_threads, _CacheInfo::reference_count, RelinquishMagickMemory(), RelinquishStreamPixels(), _CacheInfo::semaphore, _CacheInfo::signature, _Image::signature, TraceEvent, and UnlockSemaphoreInfo().
Referenced by ReadStream().
MagickExport StreamInfo* DestroyStreamInfo | ( | StreamInfo * | stream_info | ) |
Definition at line 268 of file stream.c.
References CloseBlob(), DestroyImage(), DestroyQuantumInfo(), DestroyString(), GetMagickModule, LogMagickEvent(), MagickSignature, _StreamInfo::map, _StreamInfo::pixels, _StreamInfo::quantum_info, RelinquishAlignedMemory(), RelinquishMagickMemory(), _StreamInfo::signature, _StreamInfo::stream, and TraceEvent.
|
static |
Definition at line 314 of file stream.c.
References _Image::cache, _Image::debug, _Image::filename, GetMagickModule, LogMagickEvent(), MagickFalse, MagickSignature, _CacheInfo::metacontent, _CacheInfo::signature, _Image::signature, and TraceEvent.
Referenced by ReadStream().
Definition at line 398 of file stream.c.
References _Image::cache, _Image::debug, _Image::filename, GetMagickModule, LogMagickEvent(), MagickFalse, MagickSignature, _CacheInfo::pixels, _CacheInfo::signature, _Image::signature, and TraceEvent.
Referenced by ReadStream().
|
static |
Definition at line 360 of file stream.c.
References _Image::debug, _Image::filename, GetMagickModule, LogMagickEvent(), MagickFalse, MagickSignature, QueueAuthenticPixelsStream(), _Image::signature, and TraceEvent.
Referenced by GetOneAuthenticPixelFromStream(), and ReadStream().
|
static |
Definition at line 443 of file stream.c.
References _PixelInfo::alpha, AlphaPixelChannel, _Image::background_color, _PixelInfo::black, BlackPixelChannel, _PixelInfo::blue, BluePixelChannel, ClampToQuantum(), GetAuthenticPixelsStream(), GetPixelChannelChannel(), GetPixelChannels(), _PixelInfo::green, GreenPixelChannel, MagickFalse, MagickSignature, MagickTrue, MaxPixelChannels, _PixelInfo::red, RedPixelChannel, and _Image::signature.
Referenced by ReadStream().
|
static |
Definition at line 506 of file stream.c.
References _PixelInfo::alpha, AlphaPixelChannel, _Image::background_color, _PixelInfo::black, BlackPixelChannel, _PixelInfo::blue, BluePixelChannel, ClampToQuantum(), GetPixelChannelChannel(), GetPixelChannels(), GetVirtualPixelStream(), _PixelInfo::green, GreenPixelChannel, MagickFalse, MagickSignature, MagickTrue, MaxPixelChannels, _PixelInfo::red, RedPixelChannel, and _Image::signature.
Referenced by ReadStream().
MagickPrivate const void* GetStreamInfoClientData | ( | StreamInfo * | stream_info | ) |
Definition at line 559 of file stream.c.
References _StreamInfo::client_data, MagickSignature, and _StreamInfo::signature.
|
static |
Definition at line 630 of file stream.c.
References _Image::cache, _Image::debug, _Image::filename, GetMagickModule, LogMagickEvent(), MagickFalse, MagickSignature, _CacheInfo::metacontent, _CacheInfo::signature, _Image::signature, and TraceEvent.
Referenced by ReadStream().
Definition at line 592 of file stream.c.
References _Image::cache, _Image::debug, _Image::filename, GetMagickModule, LogMagickEvent(), MagickFalse, MagickSignature, _CacheInfo::pixels, _CacheInfo::signature, _Image::signature, and TraceEvent.
Referenced by ReadStream().
|
static |
Referenced by GetOneVirtualPixelFromStream(), and ReadStream().
|
static |
Definition at line 704 of file stream.c.
References AcquireStreamPixels(), _Image::cache, _Image::columns, _Image::debug, _Image::filename, GetMagickModule, _CacheInfo::length, LogMagickEvent(), MagickFalse, MagickSignature, _CacheInfo::metacontent, _CacheInfo::metacontent_extent, _CacheInfo::number_channels, _CacheInfo::pixels, RelinquishStreamPixels(), _Image::rows, _CacheInfo::signature, _Image::signature, StreamError, ThrowMagickException(), and TraceEvent.
MagickExport MagickBooleanType OpenStream | ( | const ImageInfo * | image_info, |
StreamInfo * | stream_info, | ||
const char * | filename, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 806 of file stream.c.
References CopyMagickString(), _Image::filename, MaxTextExtent, OpenBlob(), _StreamInfo::stream, and WriteBinaryBlobMode.
|
static |
Definition at line 848 of file stream.c.
References AcquireStreamPixels(), _Image::cache, _CacheInfo::colorspace, _Image::colorspace, _CacheInfo::columns, _Image::columns, _Image::filename, GetBlobStreamHandler(), GetMagickModule, GetPixelCacheColorspace(), GetPixelCacheStorageClass(), _CacheInfo::length, MagickFalse, MagickSignature, _CacheInfo::metacontent, _CacheInfo::metacontent_extent, _CacheInfo::number_channels, _CacheInfo::pixels, RelinquishStreamPixels(), _CacheInfo::rows, _Image::rows, _CacheInfo::signature, _CacheInfo::storage_class, _Image::storage_class, StreamError, ThrowMagickException(), and UndefinedClass.
Referenced by GetAuthenticPixelsStream(), and ReadStream().
MagickExport Image* ReadStream | ( | const ImageInfo * | image_info, |
StreamHandler | stream, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 969 of file stream.c.
References AcquirePixelCache(), _ImageInfo::cache, CloneImageInfo(), _ImageInfo::debug, _CacheMethods::destroy_pixel_handler, DestroyImageInfo(), DestroyPixelStream(), _ImageInfo::filename, _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, GetAuthenticMetacontentFromStream(), GetAuthenticPixelsFromStream(), GetAuthenticPixelsStream(), GetMagickModule, GetOneAuthenticPixelFromStream(), GetOneVirtualPixelFromStream(), GetPixelCacheMethods(), GetVirtualMetacontentFromStream(), GetVirtualPixelsStream(), GetVirtualPixelStream(), LogMagickEvent(), MagickFalse, MagickSignature, _CacheMethods::queue_authentic_pixels_handler, QueueAuthenticPixelsStream(), ReadImage(), SetPixelCacheMethods(), _ExceptionInfo::signature, _ImageInfo::signature, _ImageInfo::stream, _CacheMethods::sync_authentic_pixels_handler, SyncAuthenticPixelsStream(), and TraceEvent.
Referenced by PingBlob(), PingImage(), and StreamImage().
|
inlinestatic |
Definition at line 199 of file stream.c.
References _CacheInfo::length, MagickFalse, _CacheInfo::mapped, _CacheInfo::metacontent, _CacheInfo::pixels, RelinquishAlignedMemory(), and UnmapBlob().
Referenced by DestroyPixelStream(), GetVirtualPixelStream(), and QueueAuthenticPixelsStream().
MagickPrivate void SetStreamInfoClientData | ( | StreamInfo * | stream_info, |
const void * | client_data | ||
) |
Definition at line 1040 of file stream.c.
References _StreamInfo::client_data, MagickSignature, and _StreamInfo::signature.
MagickExport void SetStreamInfoMap | ( | StreamInfo * | stream_info, |
const char * | map | ||
) |
Definition at line 1072 of file stream.c.
References CloneString(), MagickSignature, _StreamInfo::map, and _StreamInfo::signature.
MagickExport void SetStreamInfoStorageType | ( | StreamInfo * | stream_info, |
const StorageType | storage_type | ||
) |
Definition at line 1104 of file stream.c.
References MagickSignature, _StreamInfo::signature, and _StreamInfo::storage_type.
MagickExport Image* StreamImage | ( | const ImageInfo * | image_info, |
StreamInfo * | stream_info, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 1235 of file stream.c.
References AcquireQuantumInfo(), _ImageInfo::client_data, CloneImageInfo(), _ImageInfo::debug, DestroyImage(), DestroyImageInfo(), DestroyQuantumInfo(), _StreamInfo::exception, _ImageInfo::filename, GetMagickModule, _StreamInfo::image_info, LogMagickEvent(), MagickFalse, MagickSignature, _StreamInfo::quantum_info, ReadStream(), _StreamInfo::signature, _ImageInfo::signature, TraceEvent, and WriteStreamImage().
|
static |
Definition at line 1295 of file stream.c.
References AcquireQuantumMemory(), AlphaQuantum, BlackQuantum, BlueQuantum, CharPixel, ClampToQuantum(), CMYKColorspace, _Image::colorspace, CyanQuantum, _Image::debug, DoublePixel, _Image::filename, FloatPixel, GetAuthenticPixelQueue(), GetImageExtent(), GetMagickModule, GetPixelAlpha(), GetPixelBlack(), GetPixelBlue(), GetPixelGreen(), GetPixelIntensity(), GetPixelRed(), GreenQuantum, ImageError, IndexQuantum, LocaleCompare(), LogMagickEvent(), LongLongPixel, LongPixel, MagentaQuantum, MagickFalse, MagickSignature, MagickTrue, _StreamInfo::map, _QuantumInfo::minimum, OpacityQuantum, OptionError, _StreamInfo::pixels, _StreamInfo::quantum_info, QuantumPixel, QuantumScale, RedQuantum, RelinquishMagickMemory(), ResourceLimitError, _QuantumInfo::scale, ShortPixel, _StreamInfo::signature, _Image::signature, _StreamInfo::storage_type, ThrowMagickException(), TraceEvent, UndefinedQuantum, and YellowQuantum.
Referenced by WriteStreamImage().
static MagickBooleanType SyncAuthenticPixelsStream | ( | Image * | image, |
ExceptionInfo * | exception | ||
) |
Definition at line 2676 of file stream.c.
References _Image::cache, _CacheInfo::columns, _Image::debug, _Image::filename, GetBlobStreamHandler(), GetMagickModule, LogMagickEvent(), MagickFalse, MagickSignature, MagickTrue, _CacheInfo::pixels, _CacheInfo::signature, _Image::signature, StreamError, ThrowMagickException(), and TraceEvent.
Referenced by ReadStream().
MagickExport MagickBooleanType WriteStream | ( | const ImageInfo * | image_info, |
Image * | image, | ||
StreamHandler | stream, | ||
ExceptionInfo * | exception | ||
) |
Definition at line 2733 of file stream.c.
References CloneImageInfo(), _ImageInfo::debug, DestroyImageInfo(), _ImageInfo::filename, GetMagickModule, LogMagickEvent(), MagickFalse, MagickSignature, _Image::signature, _ImageInfo::signature, _ImageInfo::stream, TraceEvent, and WriteImage().
|
static |
Definition at line 1145 of file stream.c.
References AcquireAlignedMemory(), _Image::cache, CharPixel, _Image::client_data, CloneImageInfo(), _CacheInfo::columns, DestroyImageInfo(), DoublePixel, _StreamInfo::exception, _ImageInfo::extract, _StreamInfo::extract_info, FloatPixel, _RectangleInfo::height, _StreamInfo::image, _StreamInfo::image_info, LongLongPixel, LongPixel, MagickSignature, _StreamInfo::map, ParseAbsoluteGeometry(), _StreamInfo::pixels, QuantumPixel, RelinquishAlignedMemory(), ResetMagickMemory(), _CacheInfo::rows, SetImageInfo(), ShortPixel, _CacheInfo::signature, _StreamInfo::storage_type, _StreamInfo::stream, StreamImagePixels(), _RectangleInfo::width, WriteBlob(), _RectangleInfo::x, _StreamInfo::y, and _RectangleInfo::y.
Referenced by StreamImage().