]> granicus.if.org Git - imagemagick/commitdiff
(no commit message)
authorcristy <urban-warrior@git.imagemagick.org>
Sat, 6 Mar 2010 02:54:01 +0000 (02:54 +0000)
committercristy <urban-warrior@git.imagemagick.org>
Sat, 6 Mar 2010 02:54:01 +0000 (02:54 +0000)
magick/blob-private.h
magick/blob.c

index 7dfc4d626f412da8ec51b4b5bfafcb203d1bbf5c..b6459786f14741fb0afb018545158a09496addc1 100644 (file)
@@ -97,6 +97,7 @@ extern MagickExport ssize_t
   WriteBlobLSBLong(Image *,const unsigned int),
   WriteBlobLSBShort(Image *,const unsigned short),
   WriteBlobMSBLong(Image *,const unsigned int),
+  WriteBlobMSBLongLong(Image *,const MagickSizeType),
   WriteBlobMSBShort(Image *,const unsigned short),
   WriteBlobString(Image *,const char *);
 
index 59688433c49307a7f9ec2f720710d68b7e36dbfd..48fded4ffbc96b6bb8295039030f6d96a128939d 100644 (file)
@@ -4265,6 +4265,50 @@ MagickExport ssize_t WriteBlobMSBLong(Image *image,const unsigned int value)
 %                                                                             %
 %                                                                             %
 %                                                                             %
++  W r i t e B l o b M S B L o n g L o n g                                    %
+%                                                                             %
+%                                                                             %
+%                                                                             %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+%  WriteBlobMSBLongLong() writes a long long value as a 64-bit quantity in
+%  most-significant byte first order.
+%
+%  The format of the WriteBlobMSBLongLong method is:
+%
+%      ssize_t WriteBlobMSBLongLong(Image *image,const MagickSizeType value)
+%
+%  A description of each parameter follows.
+%
+%    o value:  Specifies the value to write.
+%
+%    o image: the image.
+%
+*/
+MagickExport ssize_t WriteBlobMSBLongLong(Image *image,
+  const MagickSizeType value)
+{
+  unsigned char
+    buffer[8];
+
+  assert(image != (Image *) NULL);
+  assert(image->signature == MagickSignature);
+  buffer[0]=(unsigned char) (value >> 56);
+  buffer[1]=(unsigned char) (value >> 48);
+  buffer[2]=(unsigned char) (value >> 40);
+  buffer[3]=(unsigned char) (value >> 32);
+  buffer[4]=(unsigned char) (value >> 24);
+  buffer[5]=(unsigned char) (value >> 16);
+  buffer[6]=(unsigned char) (value >> 8);
+  buffer[7]=(unsigned char) value;
+  return(WriteBlobStream(image,8,buffer));
+}
+\f
+/*
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%                                                                             %
+%                                                                             %
+%                                                                             %
 +  W r i t e B l o b M S B S h o r t                                          %
 %                                                                             %
 %                                                                             %