I've been trying to debug some issues that I've been experiencing on Canon 6D files, and started comparing the matrices shown by raw-identify on the original .cr2 and that same file converted to .dng. Based on this post, my understanding was that cam_xyz should exactly match ColorMatrix2. However, here is what I see for one such raw file (the numbers are the same for all the files I've tested):
When I use DCRAW to extract the RAW pixel values from a NEF file made by my D5300 I notice that there seems to be a minimum value clamp = 588 applied to the pixel values. I am an astrophotographer so generating master BIAS and DARK frames is part of my image calibration method. Both BIAS and DARK frames are images with the lens cap in place so that no light enters the camera. I believe that Nikon uses a Darkness value of 600 in their NEF files. The 588 minimum value clamp causes a huge number of pixel values in my individual DARK frames to be clamped at 588.
I can't seem to get the libraw_data_t->params.use_camera_wb flag to work. I suspect I'm doing something wrong.
I have a Sony .ARW file which unpacks with the wrong colors if use_camera_wb isn't set to 1. It unpacks correctly under dcraw with use_camera_wb set to 1.
Setting this item to 1 in libraw causes it to unpack with the wrong colors.
Here's a simplified version of what I'm doing - I'm using the libraw C interface.
use of auto_ptr is deprecated and generates warnings in the mingw build. Enclosed is a patch to replace auto_ptr with unique_ptr, which eliminates these warnings with mingw (and hopefully future-proof).
I'm using LibRaw 0.18.8 in an Android application amongst other things to read thumbnails. I'm seeing a lot of crashes that I cannot reproduce. All I have to go on are slightly unhelpful backtraces:
backtrace:
#00 pc 0000000000032e50 <...>.so (_ZN6LibRaw12unpack_thumbEv+1076)
If I compile under mingw with the supplied configure, I get warnings from the mingw C++ compiler stating that winsock2.h should be included before windows.h. The following patch moves up the definition of winsock2.h in libraw_datastream.h, and then the warnings go away.
1) use client_data structure, rather than assume the cinfo->err structure has extra space after it which holds the longjmp/setjmp buffer. (This is not a fix but a cleanup.)
2) make sure to return an error code in the event the thumbnail decoding fails.
By the way, is this the right place to submit bug reports?
I'm trying to get some clarity around exactly which color-spaces are used in libraw's output, as I haven't yet been able to get my colors to look "right". I see in internal/dcraw_common.cpp, there is an xyzd50_srgb matrix. Given the name, and the numbers that are listed, this looks to be using a D50 whitepoint. However, the Wikipedia article on sRGB lists a different matrix which seems to assume a D65 whitepoint.
Recent comments