How to determine if a DNG has the original CR2 RAW embedded?

Started by lingfish, October 09, 2010, 09:00:54 PM

Previous topic - Next topic

lingfish

Hi all,

I think I know the answer to this, but just need to be quite sure.

I want to know how to 100% confirm if DNG's that I have, have the original CR2 Canon RAW embedded in them?

I'm pretty sure I've always done this when converting to DNG, but want to be absolutely sure before I delete my CR2's forever.

I'll obviously need to do this in a scripted fashion.

Is the presence of the following good enough, or am I missing some better way to detect this?

Original Raw File Name          : IMG_0013.CR2
Original Raw Image              : (Binary data 30406314 bytes, use -b option to extract)


Thanks!

Phil Harvey

This definitely indicates that some data is stored for the RAW image.  To be sure that the exact image is stored, I would try something like this:

exiftool -originalrawimage -b FILE.dng > out.cr2
diff out.cr2 original.cr2


I would feel much better to know that the image was stored properly and that I could retrieve it if I wanted.  Just running a test like this on a few images would let me sleep better at night.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

lingfish

Thanks heaps for the Phil, and your awesome tool.

I may even just md5sum or similiar to what you've suggested.

I just needed to know for sure if that was the meta/header stuff I was to look for if the embed existed at all or not.