Jump to content

About Hand-Coding of Uncoded Lenses


lct

Recommended Posts

Advertisement (gone after registration)

We had some interesting discussions on the LUF about the theoretical and practical value of hand-coding uncoded lenses. The hand coding process is very simple on recent Voigtlander (CV) and Zeiss (ZM) lenses which have a groove on the flange of the lens purposedly. The temptation is therefore great to hand-code these lenses. It is more convenient for archiving purposes and the camera knows the focal length of the lens this way, which allows it to set auto-iso correctly when these settings are based on the focal length of lenses.
Why hesitate in this case? For reasons that would come from the idea that 6-bit coding leads to deep changes in the DNG files, that these changes for Leica lenses may not be suitable for non-Leica ones, and that these changes would be irreversible in PP. 
Don't ask me more please, the authors of this thesis will explain much better than i can do if they wish so.
Just to take a concrete example, i will start with a CV Ultron 28/2 hand-coded as a Summicron 28/2.
Below are 3 snaps on M11 with Lens Detection Off, Lens Detection On with Leica color profile, and Lens Detection On with DNG Matrix Color.
- The worse method, in my opinion, is Lens Detection Off because it does not correct vignetting, contrast, or color saturation;
- The second is Lens Detection On. This way the lens is treated exactly like a Summicron 28/2. This has the advantage of correcting vignetting but also the disadvantage of not correcting contrast and color saturation. 
- The best solution, in my view, is to keep Lens Detection On and to try another color profile, in my example DNG Matrix Color proposed by Iridient Developer.
FWIW

Lens Detection Off:

Welcome, dear visitor! As registered member you'd see an image here…

Simply register for free here – We are always happy to welcome new members!

 

Lens Detection On with Leica color profile:

 

Lens Detection On with DNG Matrix Color: 

 

Link to post
Share on other sites

31 minutes ago, Anbaric said:

I'm curious about the apparently irreversible changes to the raw file. This implies that something apart from metadata changes when the image is captured with coding detected. Can someone explain what this might be?

This might be somewhat similar to the iPhone raw files. The “computational photography” happened before packing into the DNG files. 
 

However, the modification should be much less with Leica Ms. You can conveniently adapt the lenses to other systems and see the differences. 

Edited by tjxism
Link to post
Share on other sites

1 hour ago, lct said:

We had some interesting discussions on the LUF about the theoretical and practical value of hand-coding uncoded lenses. The hand coding process is very simple on recent Voigtlander (CV) and Zeiss (ZM) lenses which have a groove on the flange of the lens purposedly. The temptation is therefore great to hand-code these lenses. It is more convenient for archiving purposes and the camera knows the focal length of the lens this way, which allows it to set auto-iso correctly when these settings are based on the focal length of lenses.
Why hesitate in this case? For reasons that would come from the idea that 6-bit coding leads to deep changes in the DNG files, that these changes for Leica lenses may not be suitable for non-Leica ones, and that these changes would be irreversible in PP. 
Don't ask me more please, the authors of this thesis will explain much better than i can do if they wish so.
Just to take a concrete example, i will start with a CV Ultron 28/2 hand-coded as a Summicron 28/2.
Below are 3 snaps on M11 with Lens Detection Off, Lens Detection On with Leica color profile, and Lens Detection On with DNG Matrix Color.
- The worse method, in my opinion, is Lens Detection Off because it does not correct vignetting, contrast, or color saturation;
- The second is Lens Detection On. This way the lens is treated exactly like a Summicron 28/2. This has the advantage of correcting vignetting but also the disadvantage of not correcting contrast and color saturation. 
- The best solution, in my view, is to keep Lens Detection On and to try another color profile, in my example DNG Matrix Color proposed by Iridient Developer.
FWIW

Lens Detection Off:

 

Lens Detection On with Leica color profile:

 

Lens Detection On with DNG Matrix Color: 

 

Contrast and saturation differences are most likely caused by the selected profile. Why are you comparing the combination of changes applied by lens detection and profiles? They are independent, aren't they?

  • Like 1
Link to post
Share on other sites

I feel it was pointless to explain to you what the benefit and disadvantages are, by coding the lenses incorrectly.

correction in postproduction has nothing to do with it.

if you mix profile, contrast, and saturation together with embedded lens correction in DNG...

🤦‍♂️

  • Like 1
Link to post
Share on other sites

2 hours ago, Photoworks said:

[...] if you mix profile, contrast, and saturation together with embedded lens correction in DNG...

Colors are the results of all that and BSI sensors are not prone to color shifts in my experience. I noticed this on my A7r2 mod a couple years ago. I got much better outcomes than with my M240 on lenses like S-A 21/3.4, ZM 21/4.5 or CV 15/4.5 v2 yet. I retrieve the same character on the M11 so color corrections must be very discrete on it if any. The least change in color profiles or the least tweak in PP can hide them easily. It is but my modest experience on a dozen hand-coded lenses but i'm always glad to learn new things from people with more experience than me.

Link to post
Share on other sites

Advertisement (gone after registration)

For sake of comparison, my 6-bit coded Elmarit 28/2.8 asph v1 may have some color shift issues on M240 with lens detection off but little to no significant one on BSI sensors (Sony A7r2 mod, Leica M11). 
Couple of boring crops below on the M11, resp. Lens Detection On, Lens Detection Off, and Lens Detection Off with slight vignetting correction.
Color differences are not obvious and can be tweaked easily in PP if needed so with similar experience on a dozen Leica and non-Leica uncoded lenses, i can't figure out a sensible reason against hand-coding any lens of the same focal length as the Leica code actually. 
BTW distortion is corrected in DNG files of digital CL so CL users may wish to check possible compatibility issues there but opcodes can be removed easily from DNG files on this body. 
No idea about SL and other L-mount cameras i have not enough experience with. FWIW.
 
Full frame - Lens Detection On: 

Welcome, dear visitor! As registered member you'd see an image here…

Simply register for free here – We are always happy to welcome new members!

Top right corner - Lens Detection On:

Top right corner - Lens Detection Off:

Top right corner - Lens Detection Off with vignette correction:

 

Link to post
Share on other sites

On 2/27/2023 at 10:28 AM, Anbaric said:

I'm curious about the apparently irreversible changes to the raw file. This implies that something apart from metadata changes when the image is captured with coding detected. Can someone explain what this might be?

DNG's aren't *technically* raw files, sort of, it's complicated. They are effectively raw files in 99% of the ways that matter, but a pure raw file would be the straight output from the sensor and that's not exactly what you get with a Leica DNG. A DNG is more like a lossless, high bitrate image with a metadata compartment. I would assume that there are certain corrections/changes that just are hardcoded in because you'd never want to adjust them or because it's too complicated to store in metadata for raw editors to understand. Italian Flag corrections, I believe are hardcoded, not metadata coded, though I might be wrong about that.

Link to post
Share on other sites

14 minutes ago, wdahab said:

DNG's aren't *technically* raw files, sort of, it's complicated. They are effectively raw files in 99% of the ways that matter, but a pure raw file would be the straight output from the sensor and that's not exactly what you get with a Leica DNG. A DNG is more like a lossless, high bitrate image with a metadata compartment. I would assume that there are certain corrections/changes that just are hardcoded in because you'd never want to adjust them or because it's too complicated to store in metadata for raw editors to understand. Italian Flag corrections, I believe are hardcoded, not metadata coded, though I might be wrong about that.

DNGs are as much raw files as are Nikon NEF or Canon CR2 files. All these files contain metadata and sensor data (that may or may not have been modified to some extent by the camera processor). I don't think there is such a thing as a "pure raw file" as you describe it. If there was, how would you know aperture, lens type, shutter speed, ISO etc.?

The DNG file format differs in being open and not specific to a particular manufacturer. Leica are one company that makes use of the DNG format to "carry" its raw file data.

  • Thanks 1
Link to post
Share on other sites

A pure sensor dump would not be a usable image. DAC, demosaicing, interpolation, black point setting, all must be done before there is a usable file.  Other brands like Nikon/Canon even include noise reduction in their raw files.  There is absolutely no difference in this respect between DNG, NEF, CRW,  etc. The only thing that sets DNG apart is that it is not a proprietary format, unlike the locked ones from CaNikoSony. 

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...