jcelaya / hdrmerge

HDR exposure merging
http://jcelaya.github.io/hdrmerge/
Other
355 stars 78 forks source link

SONY ILCE-7M2 DNGs converted from ARW using Adobe DNG coverter have wrong mask and magenta colors #144

Closed Beep6581 closed 6 years ago

Beep6581 commented 6 years ago

81a6af5 using libraw-0.18.8 I converted my SONY ILCE-7M2 ARW files to DNG using Adobe DNG Converter 10.3. Upon merging, the preview's mask looks incorrect, the saved mask looks incorrect, and both the embedded JPEG and the raw file have a strong magenta cast.

Source files + HDR DNG + mask: https://filebin.net/337wfzcmq6vf3g16

I will measure the source DNG file's white levels in a moment.

Beep6581 commented 6 years ago

I measured that the ARWs converted to DNG have WL=15864 BL=512

Metadata from one of the source DNGs:

-TIFF-IFD0-SubIFD:BlackLevel=512 512 512 512
-TIFF-IFD0-SubIFD:WhiteLevel=16300          

IIRC I used a custom white level of 15780 for ARW files. Using @floessie's patch in #134 I could disable the custom white level and still get correct colors with ARWs, however if I first convert the ARWs to DNG, the result is all magenta and with a wrong mask. I tested with and without @floessie's patch.

I tried setting the white levels in HDRMerge to WL=auto, WL=16300, WL=15864 and WL=3000, but all turned out magenta.

heckflosse commented 6 years ago

Issue confirmed

Beep6581 commented 6 years ago

Another sample set, both ARW and DNG: https://filebin.net/vcb7ugr39n3jngoy

ARW=DNG BL=512 WL=15864 (after BL subtraction, WL=16376 before subtraction)

Beep6581 commented 6 years ago

Thank you for taking this issue @heckflosse