dcraw_process() is 16 bit internally. Processing result is scaled to 8 bit (if asked) on output routines.
raw2image converts from bayer data (flat, 1 value per pixel) to 4-component image[][4]. Only one component of image is non-zero after raw2image. This is NOT demosaiced image, but data prepared for demosaic (this format is back-compatible to old LibRaw versions, that's why raw2image call is provided).
To get color index (index of non-zero element in 4-component pixel) use COLOR(row,col) call.
dcraw_process() is 16 bit internally. Processing result is scaled to 8 bit (if asked) on output routines.
raw2image converts from bayer data (flat, 1 value per pixel) to 4-component image[][4]. Only one component of image is non-zero after raw2image. This is NOT demosaiced image, but data prepared for demosaic (this format is back-compatible to old LibRaw versions, that's why raw2image call is provided).
To get color index (index of non-zero element in 4-component pixel) use COLOR(row,col) call.