RAW conversion 16bit and 8bit mixed
Posted: 2008-02-19T09:42:20-07:00
When converting from RAW format, for example
convert CR2_MG_2959.CR2 x.tif
the image gets very distorted in its colors (using ImageMagick 6.3.8 02/16/08 Q8).
I suppose its becaurse color depth is interpreted wrongly.
I noticed that IM is using this comand behind the scenes to create e PNM image:
ufraw-batch --silent --wb=camera --black-point=auto --exposure=auto --create-id=also --out-type=ppm16 --output=/tmp/magick-XX3yR6J7.pnm /tmp/magick-XXOZ46SS
If I invoke ufraw-batch manually
ufraw-batch --silent --wb=camera --black-point=auto --exposure=auto --create-id=also --out-type=ppm16 CR2_MG_2959.CR2 --output=x.pnm
and looks this PNM image looks fine.
However,
convert x.pnm x.tif
gives the color distorted image.
If I instead use
ufraw-batch --silent --wb=camera --black-point=auto --exposure=auto --create-id=also --out-type=ppm8 CR2_MG_2959.CR2 --output=x.pnm
(changing --out-type=ppm16 to --out-type=ppm8) then I get an image that convert subsequently converts correct.
My suggestions is therefore that you either
1) change from --out-type=ppm16 to --out-type=ppm8 in case of Q8
2) makes IM Q8 read 16-bit pnm images correct
Thank you
Jacob
convert CR2_MG_2959.CR2 x.tif
the image gets very distorted in its colors (using ImageMagick 6.3.8 02/16/08 Q8).
I suppose its becaurse color depth is interpreted wrongly.
I noticed that IM is using this comand behind the scenes to create e PNM image:
ufraw-batch --silent --wb=camera --black-point=auto --exposure=auto --create-id=also --out-type=ppm16 --output=/tmp/magick-XX3yR6J7.pnm /tmp/magick-XXOZ46SS
If I invoke ufraw-batch manually
ufraw-batch --silent --wb=camera --black-point=auto --exposure=auto --create-id=also --out-type=ppm16 CR2_MG_2959.CR2 --output=x.pnm
and looks this PNM image looks fine.
However,
convert x.pnm x.tif
gives the color distorted image.
If I instead use
ufraw-batch --silent --wb=camera --black-point=auto --exposure=auto --create-id=also --out-type=ppm8 CR2_MG_2959.CR2 --output=x.pnm
(changing --out-type=ppm16 to --out-type=ppm8) then I get an image that convert subsequently converts correct.
My suggestions is therefore that you either
1) change from --out-type=ppm16 to --out-type=ppm8 in case of Q8
2) makes IM Q8 read 16-bit pnm images correct
Thank you
Jacob