File indexing completed on 2025-01-30 10:11:40
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018 #ifndef MAGICKCORE_BLOB_H
0019 #define MAGICKCORE_BLOB_H
0020
0021 #if defined(__cplusplus) || defined(c_plusplus)
0022 extern "C" {
0023 #endif
0024
0025 #define MagickMaxBufferExtent 81920
0026 #define MagickMinBufferExtent 16384
0027
0028 typedef enum
0029 {
0030 ReadMode,
0031 WriteMode,
0032 IOMode,
0033 PersistMode
0034 } MapMode;
0035
0036 typedef ssize_t
0037 (*CustomStreamHandler)(unsigned char *,const size_t,void *);
0038
0039 typedef MagickOffsetType
0040 (*CustomStreamSeeker)(const MagickOffsetType,const int,void *);
0041
0042 typedef MagickOffsetType
0043 (*CustomStreamTeller)(void *);
0044
0045 typedef struct _CustomStreamInfo
0046 CustomStreamInfo;
0047
0048 #include "MagickCore/image.h"
0049 #include "MagickCore/stream.h"
0050
0051 extern MagickExport CustomStreamInfo
0052 *AcquireCustomStreamInfo(ExceptionInfo *),
0053 *DestroyCustomStreamInfo(CustomStreamInfo *);
0054
0055 extern MagickExport FILE
0056 *GetBlobFileHandle(const Image *) magick_attribute((__pure__));
0057
0058 extern MagickExport Image
0059 *BlobToImage(const ImageInfo *,const void *,const size_t,ExceptionInfo *),
0060 *PingBlob(const ImageInfo *,const void *,const size_t,ExceptionInfo *),
0061 *CustomStreamToImage(const ImageInfo *,ExceptionInfo *);
0062
0063 extern MagickExport MagickBooleanType
0064 BlobToFile(char *,const void *,const size_t,ExceptionInfo *),
0065 FileToImage(Image *,const char *,ExceptionInfo *),
0066 GetBlobError(const Image *) magick_attribute((__pure__)),
0067 ImageToFile(Image *,char *,ExceptionInfo *),
0068 InjectImageBlob(const ImageInfo *,Image *,Image *,const char *,
0069 ExceptionInfo *),
0070 IsBlobExempt(const Image *) magick_attribute((__pure__)),
0071 IsBlobSeekable(const Image *) magick_attribute((__pure__)),
0072 IsBlobTemporary(const Image *) magick_attribute((__pure__));
0073
0074 extern MagickExport MagickSizeType
0075 GetBlobSize(const Image *);
0076
0077 extern MagickExport StreamHandler
0078 GetBlobStreamHandler(const Image *) magick_attribute((__pure__));
0079
0080 extern MagickExport void
0081 *GetBlobStreamData(const Image *) magick_attribute((__pure__)),
0082 DestroyBlob(Image *),
0083 DuplicateBlob(Image *,const Image *),
0084 *FileToBlob(const char *,const size_t,size_t *,ExceptionInfo *),
0085 *ImageToBlob(const ImageInfo *,Image *,size_t *,ExceptionInfo *),
0086 ImageToCustomStream(const ImageInfo *,Image *,ExceptionInfo *),
0087 *ImagesToBlob(const ImageInfo *,Image *,size_t *,ExceptionInfo *),
0088 ImagesToCustomStream(const ImageInfo *,Image *,ExceptionInfo *),
0089 SetBlobExempt(Image *,const MagickBooleanType),
0090 SetCustomStreamData(CustomStreamInfo *,void *),
0091 SetCustomStreamReader(CustomStreamInfo *,CustomStreamHandler),
0092 SetCustomStreamSeeker(CustomStreamInfo *,CustomStreamSeeker),
0093 SetCustomStreamTeller(CustomStreamInfo *,CustomStreamTeller),
0094 SetCustomStreamWriter(CustomStreamInfo *,CustomStreamHandler);
0095
0096 #if defined(__cplusplus) || defined(c_plusplus)
0097 }
0098 #endif
0099
0100 #endif