MagickCore  7.0.1
blob.c File Reference
Include dependency graph for blob.c:

Go to the source code of this file.

Data Structures

union  FileInfo
 
struct  _BlobInfo
 

Macros

#define MagickMaxBlobExtent   (8*8192)
 
#define MAP_FAILED   ((void *) -1)
 

Typedefs

typedef union FileInfo FileInfo
 

Functions

static int SyncBlob (Image *)
 
MagickExport void AttachBlob (BlobInfo *blob_info, const void *blob, const size_t length)
 
MagickExport MagickBooleanType BlobToFile (char *filename, const void *blob, const size_t length, ExceptionInfo *exception)
 
MagickExport ImageBlobToImage (const ImageInfo *image_info, const void *blob, const size_t length, ExceptionInfo *exception)
 
MagickExport BlobInfoCloneBlobInfo (const BlobInfo *blob_info)
 
MagickExport MagickBooleanType CloseBlob (Image *image)
 
MagickExport void DestroyBlob (Image *image)
 
MagickExport void * DetachBlob (BlobInfo *blob_info)
 
MagickExport void DisassociateBlob (Image *image)
 
MagickExport MagickBooleanType DiscardBlobBytes (Image *image, const MagickSizeType length)
 
MagickExport void DuplicateBlob (Image *image, const Image *duplicate)
 
MagickExport int EOFBlob (const Image *image)
 
MagickExport void * FileToBlob (const char *filename, const size_t extent, size_t *length, ExceptionInfo *exception)
 
static ssize_t WriteBlobStream (Image *image, const size_t length, const void *data)
 
MagickExport MagickBooleanType FileToImage (Image *image, const char *filename, ExceptionInfo *exception)
 
MagickExport MagickBooleanType GetBlobError (const Image *image)
 
MagickExport FILE * GetBlobFileHandle (const Image *image)
 
MagickExport void GetBlobInfo (BlobInfo *blob_info)
 
MagickExport const struct stat * GetBlobProperties (const Image *image)
 
MagickExport MagickSizeType GetBlobSize (const Image *image)
 
MagickExport void * GetBlobStreamData (const Image *image)
 
MagickExport StreamHandler GetBlobStreamHandler (const Image *image)
 
MagickExport void * ImageToBlob (const ImageInfo *image_info, Image *image, size_t *length, ExceptionInfo *exception)
 
MagickExport MagickBooleanType ImageToFile (Image *image, char *filename, ExceptionInfo *exception)
 
MagickExport void * ImagesToBlob (const ImageInfo *image_info, Image *images, size_t *length, ExceptionInfo *exception)
 
MagickExport MagickBooleanType InjectImageBlob (const ImageInfo *image_info, Image *image, Image *inject_image, const char *format, ExceptionInfo *exception)
 
MagickExport MagickBooleanType IsBlobExempt (const Image *image)
 
MagickExport MagickBooleanType IsBlobSeekable (const Image *image)
 
MagickExport MagickBooleanType IsBlobTemporary (const Image *image)
 
MagickExport void * MapBlob (int file, const MapMode mode, const MagickOffsetType offset, const size_t length)
 
MagickExport void MSBOrderLong (unsigned char *buffer, const size_t length)
 
MagickExport void MSBOrderShort (unsigned char *p, const size_t length)
 
static MagickBooleanType SetStreamBuffering (const ImageInfo *image_info, Image *image)
 
MagickExport MagickBooleanType OpenBlob (const ImageInfo *image_info, Image *image, const BlobMode mode, ExceptionInfo *exception)
 
static size_t PingStream (const Image *magick_unused(image), const void *magick_unused(pixels), const size_t columns)
 
MagickExport ImagePingBlob (const ImageInfo *image_info, const void *blob, const size_t length, ExceptionInfo *exception)
 
MagickExport ssize_t ReadBlob (Image *image, const size_t length, void *data)
 
MagickExport int ReadBlobByte (Image *image)
 
MagickExport double ReadBlobDouble (Image *image)
 
MagickExport float ReadBlobFloat (Image *image)
 
MagickExport unsigned int ReadBlobLong (Image *image)
 
MagickExport MagickSizeType ReadBlobLongLong (Image *image)
 
MagickExport unsigned short ReadBlobShort (Image *image)
 
MagickExport unsigned int ReadBlobLSBLong (Image *image)
 
MagickExport signed int ReadBlobLSBSignedLong (Image *image)
 
MagickExport unsigned short ReadBlobLSBShort (Image *image)
 
MagickExport signed short ReadBlobLSBSignedShort (Image *image)
 
MagickExport unsigned int ReadBlobMSBLong (Image *image)
 
MagickExport MagickSizeType ReadBlobMSBLongLong (Image *image)
 
MagickExport unsigned short ReadBlobMSBShort (Image *image)
 
MagickExport signed int ReadBlobMSBSignedLong (Image *image)
 
MagickExport signed short ReadBlobMSBSignedShort (Image *image)
 
MagickExport signed int ReadBlobSignedLong (Image *image)
 
MagickExport signed short ReadBlobSignedShort (Image *image)
 
MagickExport const void * ReadBlobStream (Image *image, const size_t length, void *data, ssize_t *count)
 
MagickExport char * ReadBlobString (Image *image, char *string)
 
MagickExport BlobInfoReferenceBlob (BlobInfo *blob)
 
MagickExport MagickOffsetType SeekBlob (Image *image, const MagickOffsetType offset, const int whence)
 
MagickExport void SetBlobExempt (Image *image, const MagickBooleanType exempt)
 
MagickExport MagickBooleanType SetBlobExtent (Image *image, const MagickSizeType extent)
 
MagickExport MagickOffsetType TellBlob (const Image *image)
 
MagickExport MagickBooleanType UnmapBlob (void *map, const size_t length)
 
MagickExport ssize_t WriteBlob (Image *image, const size_t length, const void *data)
 
MagickExport ssize_t WriteBlobByte (Image *image, const unsigned char value)
 
MagickExport ssize_t WriteBlobFloat (Image *image, const float value)
 
MagickExport ssize_t WriteBlobLong (Image *image, const unsigned int value)
 
MagickExport ssize_t WriteBlobShort (Image *image, const unsigned short value)
 
MagickExport ssize_t WriteBlobLSBLong (Image *image, const unsigned int value)
 
MagickExport ssize_t WriteBlobLSBShort (Image *image, const unsigned short value)
 
MagickExport ssize_t WriteBlobLSBSignedLong (Image *image, const signed int value)
 
MagickExport ssize_t WriteBlobLSBSignedShort (Image *image, const signed short value)
 
MagickExport ssize_t WriteBlobMSBLong (Image *image, const unsigned int value)
 
MagickExport ssize_t WriteBlobMSBLongLong (Image *image, const MagickSizeType value)
 
MagickExport ssize_t WriteBlobMSBSignedLong (Image *image, const signed int value)
 
MagickExport ssize_t WriteBlobMSBSignedShort (Image *image, const signed short value)
 
MagickExport ssize_t WriteBlobMSBShort (Image *image, const unsigned short value)
 
MagickExport ssize_t WriteBlobString (Image *image, const char *string)
 

Macro Definition Documentation

#define MagickMaxBlobExtent   (8*8192)

Definition at line 82 of file blob.c.

Referenced by AttachBlob(), GetBlobInfo(), ImagesToBlob(), and ImageToBlob().

#define MAP_FAILED   ((void *) -1)

Definition at line 87 of file blob.c.

Referenced by MapBlob().

Typedef Documentation

typedef union FileInfo FileInfo

Function Documentation

MagickExport MagickBooleanType BlobToFile ( char *  filename,
const void *  blob,
const size_t  length,
ExceptionInfo exception 
)
MagickExport MagickBooleanType DiscardBlobBytes ( Image image,
const MagickSizeType  length 
)
MagickExport void DuplicateBlob ( Image image,
const Image duplicate 
)
MagickExport FILE* GetBlobFileHandle ( const Image image)
MagickExport const struct stat* GetBlobProperties ( const Image image)
MagickExport void* GetBlobStreamData ( const Image image)

Definition at line 1452 of file blob.c.

References _Image::blob, _BlobInfo::data, MagickCoreSignature, and _Image::signature.

Referenced by RenderHoughLines().

MagickExport void* MapBlob ( int  file,
const MapMode  mode,
const MagickOffsetType  offset,
const size_t  length 
)

Definition at line 2178 of file blob.c.

References IOMode, MAP_FAILED, ReadMode, and WriteMode.

Referenced by FileToBlob(), OpenBlob(), and SetBlobExtent().

MagickExport void MSBOrderLong ( unsigned char *  buffer,
const size_t  length 
)

Definition at line 2266 of file blob.c.

MagickExport void MSBOrderShort ( unsigned char *  p,
const size_t  length 
)

Definition at line 2316 of file blob.c.

MagickExport MagickBooleanType OpenBlob ( const ImageInfo image_info,
Image image,
const BlobMode  mode,
ExceptionInfo exception 
)

Definition at line 2388 of file blob.c.

References AcquireExceptionInfo(), AcquireMagickResource(), _ImageInfo::adjoin, AppendBinaryBlobMode, AppendBlobMode, AttachBlob(), _Image::blob, _ImageInfo::blob, BlobError, BlobEvent, BZipStream, CopyMagickString(), _ImageInfo::debug, DestroyExceptionInfo(), DetachBlob(), _BlobInfo::exempt, ExtensionPath, FifoStream, FileInfo::file, _ImageInfo::file, _BlobInfo::file_info, _Image::filename, _ImageInfo::filename, FileStream, fopen_utf8(), FormatLocaleString(), GetBlobSize(), GetMagickBlobSupport(), GetMagickInfo(), GetMagickModule, GetNextImageInList(), GetPathAttributes(), GetPathComponent(), GetPreviousImageInList(), InterpretImageFilename(), IsRightsAuthorized(), _ImageInfo::length, LocaleCompare(), LocaleNCompare(), LogMagickEvent(), _ImageInfo::magick, MagickCoreSignature, MagickFalse, MagickMaxBufferExtent, MagickPathExtent, MagickTrue, MapBlob(), _BlobInfo::mapped, MapResource, PathPolicyDomain, PipeStream, PolicyError, popen_utf8(), _BlobInfo::properties, ReadBinaryBlobMode, ReadBlobMode, ReadMode, ReadPolicyRights, RelinquishMagickResource(), ResetMagickMemory(), RootPath, _Image::scene, SetStreamBuffering(), _Image::signature, _ImageInfo::signature, _BlobInfo::size, StandardStream, _BlobInfo::status, _BlobInfo::stream, _ImageInfo::stream, StringToLong(), _BlobInfo::synchronize, _ImageInfo::synchronize, ThrowFileException, ThrowMagickException(), TraceEvent, _BlobInfo::type, UndefinedStream, WriteBinaryBlobMode, WriteBlobMode, WritePolicyRights, and ZipStream.

static size_t PingStream ( const Image magick_unusedimage,
const void *  magick_unusedpixels,
const size_t  columns 
)
static

Definition at line 2735 of file blob.c.

References magick_unreferenced.

Referenced by PingBlob().

MagickExport int ReadBlobByte ( Image image)

Definition at line 2990 of file blob.c.

References MagickCoreSignature, ReadBlobStream(), and _Image::signature.

MagickExport double ReadBlobDouble ( Image image)

Definition at line 3032 of file blob.c.

References ReadBlobLongLong().

MagickExport float ReadBlobFloat ( Image image)

Definition at line 3071 of file blob.c.

References ReadBlobLong().

MagickExport unsigned int ReadBlobLong ( Image image)
MagickExport MagickSizeType ReadBlobLongLong ( Image image)
MagickExport unsigned int ReadBlobLSBLong ( Image image)

Definition at line 3288 of file blob.c.

References MagickCoreSignature, ReadBlobStream(), and _Image::signature.

Referenced by ReadBlobLSBSignedLong().

MagickExport unsigned short ReadBlobLSBShort ( Image image)

Definition at line 3376 of file blob.c.

References MagickCoreSignature, ReadBlobStream(), and _Image::signature.

Referenced by ReadBlobLSBSignedShort().

MagickExport signed int ReadBlobLSBSignedLong ( Image image)

Definition at line 3338 of file blob.c.

References ReadBlobLSBLong().

MagickExport signed short ReadBlobLSBSignedShort ( Image image)

Definition at line 3424 of file blob.c.

References ReadBlobLSBShort().

MagickExport unsigned int ReadBlobMSBLong ( Image image)

Definition at line 3462 of file blob.c.

References MagickCoreSignature, ReadBlobStream(), and _Image::signature.

Referenced by ReadBlobMSBSignedLong().

MagickExport MagickSizeType ReadBlobMSBLongLong ( Image image)

Definition at line 3512 of file blob.c.

References MagickCoreSignature, MagickULLConstant, ReadBlobStream(), and _Image::signature.

MagickExport unsigned short ReadBlobMSBShort ( Image image)

Definition at line 3566 of file blob.c.

References MagickCoreSignature, ReadBlobStream(), and _Image::signature.

Referenced by ReadBlobMSBSignedShort().

MagickExport signed int ReadBlobMSBSignedLong ( Image image)

Definition at line 3614 of file blob.c.

References ReadBlobMSBLong().

MagickExport signed short ReadBlobMSBSignedShort ( Image image)

Definition at line 3652 of file blob.c.

References ReadBlobMSBShort().

MagickExport unsigned short ReadBlobShort ( Image image)

Definition at line 3234 of file blob.c.

References _Image::endian, LSBEndian, MagickCoreSignature, ReadBlobStream(), and _Image::signature.

Referenced by ReadBlobSignedShort().

MagickExport signed int ReadBlobSignedLong ( Image image)

Definition at line 3690 of file blob.c.

References ReadBlobLong().

MagickExport signed short ReadBlobSignedShort ( Image image)

Definition at line 3728 of file blob.c.

References ReadBlobShort().

MagickExport char* ReadBlobString ( Image image,
char *  string 
)

Definition at line 3831 of file blob.c.

References MagickCoreSignature, MagickPathExtent, ReadBlobStream(), and _Image::signature.

MagickExport void SetBlobExempt ( Image image,
const MagickBooleanType  exempt 
)
static MagickBooleanType SetStreamBuffering ( const ImageInfo image_info,
Image image 
)
inlinestatic
MagickExport ssize_t WriteBlobByte ( Image image,
const unsigned char  value 
)

Definition at line 4597 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobFloat ( Image image,
const float  value 
)

Definition at line 4629 of file blob.c.

References WriteBlobLong().

MagickExport ssize_t WriteBlobLong ( Image image,
const unsigned int  value 
)

Definition at line 4670 of file blob.c.

References _Image::endian, LSBEndian, MagickCoreSignature, _Image::signature, and WriteBlobStream().

Referenced by WriteBlobFloat().

MagickExport ssize_t WriteBlobLSBLong ( Image image,
const unsigned int  value 
)

Definition at line 4760 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobLSBShort ( Image image,
const unsigned short  value 
)

Definition at line 4799 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobLSBSignedLong ( Image image,
const signed int  value 
)

Definition at line 4836 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobLSBSignedShort ( Image image,
const signed short  value 
)

Definition at line 4885 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobMSBLong ( Image image,
const unsigned int  value 
)

Definition at line 4933 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobMSBLongLong ( Image image,
const MagickSizeType  value 
)

Definition at line 4972 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobMSBShort ( Image image,
const unsigned short  value 
)

Definition at line 5113 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobMSBSignedLong ( Image image,
const signed int  value 
)

Definition at line 5016 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobMSBSignedShort ( Image image,
const signed short  value 
)

Definition at line 5065 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().

MagickExport ssize_t WriteBlobShort ( Image image,
const unsigned short  value 
)
MagickExport ssize_t WriteBlobString ( Image image,
const char *  string 
)

Definition at line 5150 of file blob.c.

References MagickCoreSignature, _Image::signature, and WriteBlobStream().