Project

General

Profile

Bug #11912

Better monochrome raw support

Added by Kelvie Wong 3 months ago. Updated 3 months ago.

Status:
Fixed
Priority:
Low
Assignee:
Category:
General
Target version:
Start date:
01/08/2018
Due date:
% Done:

100%

Affected Version:
git master branch
System:
all
bitness:
64-bit
hardware architecture:
amd64/x86

Description

Having used raw DNGs out of the Leica Monochrom camera, there are a few quality-of-life things that could be improved.

1. Right now, monochrom DNGs aren't read as real raws apparently, so modifying the code to read it is a real raw will allow some functions to work again (like auto exposure)
2. Demosaicing is on by default
3. Lens correction auto-applies CA correction when selected, which can add colour to a monochrome image!

From LebedevRI on IRC:

       LebedevRI | kelvie: tldr: 1. move is_leica_monochrom() into some common source/header
       LebedevRI | 2. change https://github.com/darktable-org/darktable/blob/master/src/common/imageio_rawspeed.cc#L228 to
                 | "if(!r->isCFA && !is_leica_monochrom())" 
       LebedevRI | 3. enjoy working exposure mode=automatic
       LebedevRI | 4. on https://github.com/darktable-org/darktable/blob/master/src/iop/demosaic.c#L4911 add something like
                 | if(is_leica_monochrom()) tmp.demosaicing_method = DT_IOP_DEMOSAIC_PASSTHROUGH_MONOCHROME;
       LebedevRI | that should get you 90% there

And maybe name the function is_monochrome_camera

Associated revisions

Revision 5dd21704
Added by Roman Lebedev 3 months ago

Merge remote-tracking branch 'upstream/pr/1621'

Refs. #11912.

  • upstream/pr/1621:
    Disable cacorrect, invert, and temperature for monochrome cameras
    Improve monochrome raw handling

History

#1 Updated by Roman Lebedev 3 months ago

Kelvie Wong wrote:

Having used raw DNGs out of the Leica Monochrom camera, there are a few quality-of-life things that could be improved.

1. Right now, monochrom DNGs aren't read as real raws apparently, so modifying the code to read it is a real raw will allow some functions to work again (like auto exposure)

I don't think there is anything else other than exposure mode=manual that is not working because of it.
Well, and less data to deal with, so maybe slight performance/memory consumption changes.

2. Demosaicing is on by default

It isn't, but with these changes, it will have to be.

3. Lens correction auto-applies CA correction when selected, which can add colour to a monochrome image!

it would also be one liner, on https://github.com/darktable-org/darktable/blob/master/src/iop/lens.c#L1136 add

if(is_leica_monochrom()) tmp.demosaicing_method &= ~LF_MODIFY_TCA;

#2 Updated by Kelvie Wong 3 months ago

<deleted>
Didn't see Roman's reply

#4 Updated by Kelvie Wong 3 months ago

This was just merged, and I think can be closed!

#5 Updated by Roman Lebedev 3 months ago

  • Assignee set to Kelvie Wong
  • Status changed from New to Fixed
  • System changed from Ubuntu to all
  • Affected Version changed from 2.4.0 to git master branch
  • % Done changed from 0 to 100

#6 Updated by Roman Lebedev 3 months ago

  • Target version set to 2.6.0

Also available in: Atom PDF