From 7f599a74eb9265eb57328cde4826e0f5d5c8bbd9 Mon Sep 17 00:00:00 2001 From: kramm Date: Wed, 21 Nov 2001 14:31:54 +0000 Subject: [PATCH] fix: grayscale jpegs weren't handled correctly --- lib/modules/swfbits.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/modules/swfbits.c b/lib/modules/swfbits.c index 4349b96..d6e59fc 100644 --- a/lib/modules/swfbits.c +++ b/lib/modules/swfbits.c @@ -121,10 +121,10 @@ int swf_SetJPEGBits(TAG * t,char * fname,int quality) jpeg_create_decompress(&cinfo); if ((f=fopen(fname,"rb"))==NULL) return -1; - jpeg_stdio_src(&cinfo,f); jpeg_read_header(&cinfo, TRUE); + cinfo.out_color_space = JCS_RGB; //automatically convert grayscale images jpeg_start_decompress(&cinfo); out = swf_SetJPEGBitsStart(t,cinfo.output_width,cinfo.output_height,quality); -- 1.7.10.4