Hi Erico,

currently the pnoJpegLib doesn't offer this. Grayscale-Jpegs are returnd with a depth of 4bit and color with 16bit.

Modifying the lib isn't a good Idea because your app loose the compartibilty with the official one. (Of course you can create your own version based on the pnoJpegLib und use this one but you should change the Name and the Creator).

I think the best solution for you would be to take the 16bit bmp und convert it by hand in your programm to 8bit.

Stefan

P.S. By the way. It's dangerous to set the 'jpegData.grayScale' variable to trub by hand. Please use the pnoJpeg2SetGrayscale-Funktion (or pnoJpegSetGrayscale if you use Version 1). It's the same Problem like in the PalmOS-API. It's not sure that the struct ist backward-compartible in new releases.

Erico Franco wrote:
Hi,

is there a way to use the pnoJpeglib to convert a Jpeg->bmp 8bpp?

The pnoJpegLib when used to convert jpeg->bmp normally creates a 16bpp bmp resource.

Also you have the option to create a grayscale resource (4bpp maybe?) if you set the 'jpegData.grayScale' to 'true'

But I need to create a 8bpp resource from it, is possible to make it directly without needing to convert it after the Jpeg->bmp conversion?

The only option is to modify the pnoJpegLib source?

Thanks

Erico Franco



--
For information on using the PalmSource Developer Forums, or to unsubscribe, 
please see http://www.palmos.com/dev/support/forums/

Reply via email to