From fa57bb53c3ebaee41e25d2e34dea0c4a12947713 Mon Sep 17 00:00:00 2001 From: Nathan Stenzel Date: Sat, 22 Sep 2001 16:48:49 +0000 Subject: [PATCH] chunk_new now returns a pointer to a newly allocated chunk. quantization table handling added (including printing) git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@2305 67ed7778-7388-44ab-90cf-0a291f65f57c --- libgphoto2/jpeg.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/libgphoto2/jpeg.h b/libgphoto2/jpeg.h index d09f8524c..77f003500 100644 --- a/libgphoto2/jpeg.h +++ b/libgphoto2/jpeg.h @@ -38,7 +38,9 @@ typedef struct chunk{ unsigned char *data; } chunk; -void chunk_new(chunk *mychunk, int length); +typedef char jpeg_quantization_table[64]; + +chunk *chunk_new(int length); void chunk_print(chunk *mychunk); @@ -46,7 +48,7 @@ void chunk_destroy(chunk *mychunk); typedef struct jpeg { int count; - struct chunk marker[20]; /* I think this should be big enough */ + struct chunk *marker[20]; /* I think this should be big enough */ }jpeg; void jpeg_init(jpeg *myjpeg); @@ -65,4 +67,6 @@ void jpeg_print(jpeg *myjpeg); char *jpeg_markername(int c); +chunk *jpeg_make_SOFC (int width, int height, char vh1, char vh2, char vh3); + #endif