Thank you for all the details! I've been using:
RawProcessor.raw2image()
CFA data then from RawProcessor.imgdata.image[r*RAW_S.iwidth+c][RawProcessor.FC(r,c)]
in my code since ... well, a long time ago... to extract the unprocessed data for Bayer-matrix data. (The idea being, I do my own hot pixel / bad pixel mapping -- this is astrophotography work). When non-Bayer, I run:
RawProcessor.dcraw_process();
red data then from RawProcessor.imgdata.image[r*RAW_S.iwidth+c][0]
green from[1], blue from [2]
I poked around in the debugger and docs last night but still couldn't see the effect of use_camera_wb. The docs (http://www.libraw.org/docs/API-notes.html#imgdata_params) say that unpack() is affected by this but no matter what the setting, the output of raw2image() seems the same.
For Bayer matrices, is there a spot where I can pull off the still-CFA encoded data but having run say black level and color scaling? Or, should I just:
unpack()
subtract_black()
scale_colors()
raw2image()
and find CFA data then from RawProcessor.imgdata.image[r*RAW_S.iwidth+c][RawProcessor.FC(r,c)]
Alex,
Thank you for all the details! I've been using:
RawProcessor.raw2image()
CFA data then from RawProcessor.imgdata.image[r*RAW_S.iwidth+c][RawProcessor.FC(r,c)]
in my code since ... well, a long time ago... to extract the unprocessed data for Bayer-matrix data. (The idea being, I do my own hot pixel / bad pixel mapping -- this is astrophotography work). When non-Bayer, I run:
RawProcessor.dcraw_process();
red data then from RawProcessor.imgdata.image[r*RAW_S.iwidth+c][0]
green from[1], blue from [2]
I poked around in the debugger and docs last night but still couldn't see the effect of use_camera_wb. The docs (http://www.libraw.org/docs/API-notes.html#imgdata_params) say that unpack() is affected by this but no matter what the setting, the output of raw2image() seems the same.
For Bayer matrices, is there a spot where I can pull off the still-CFA encoded data but having run say black level and color scaling? Or, should I just:
unpack()
subtract_black()
scale_colors()
raw2image()
and find CFA data then from RawProcessor.imgdata.image[r*RAW_S.iwidth+c][RawProcessor.FC(r,c)]
Craig