00001
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029 #ifndef _GAN_IMAGE_CINEON_IO_H
00030 #define _GAN_IMAGE_CINEON_IO_H
00031
00032 #include <stdio.h>
00033 #include <gandalf/common/misc_defs.h>
00034 #include <gandalf/image/image_defs.h>
00035
00036 #ifdef __cplusplus
00037 extern "C" {
00038 #endif
00039
00053 typedef struct Gan_CineonHeaderStruct
00054 {
00056 unsigned int bit_size;
00057
00059 Gan_Bool packed;
00060 } Gan_CineonHeaderStruct;
00061
00062
00063 struct Gan_ImageReadControlStruct;
00064 struct Gan_ImageHeaderStruct;
00065 struct Gan_ImageWriteControlStruct;
00066
00067
00068 Gan_Bool gan_image_is_cineon(const unsigned char *magic_string, size_t length);
00069 Gan_Image *gan_read_cineon_image_stream ( FILE *infile, Gan_Image *image,
00070 const struct Gan_ImageReadControlStruct *ictrlstr, struct Gan_ImageHeaderStruct *header );
00071 Gan_Image *gan_read_cineon_image ( const char *filename, Gan_Image *image,
00072 const struct Gan_ImageReadControlStruct *ictrlstr, struct Gan_ImageHeaderStruct *header );
00073 void gan_initialise_cineon_header_struct(Gan_CineonHeaderStruct *octrlstr, Gan_ImageFormat image_format, Gan_Type type);
00074 Gan_Bool gan_write_cineon_image_stream ( FILE *outfile, const Gan_Image *image, Gan_Bool new_file, const struct Gan_ImageWriteControlStruct *octrlstr );
00075 Gan_Bool gan_write_cineon_image ( const char *filename, const Gan_Image *image, const struct Gan_ImageWriteControlStruct *octrlstr );
00076
00085 #ifdef __cplusplus
00086 }
00087 #endif
00088
00089 #endif