ExifTool Forum

ExifTool => The "exiftool" Application => Topic started by: sam_553817 on August 17, 2010, 07:35:50 AM

Title: Editing Lens ID?
Post by: sam_553817 on August 17, 2010, 07:35:50 AM
Hi,

My Tamron 28-75mm, used on a Sony a850, has (according to your Sony Tags page) a LensType tag of 24.6 which explains why it is showing up as " Minolta/Sony AF 24-105mm F3.5-4.5 (D) or Sigma or Tamron Lens ", which is LensType 24.  This is very annoying as DXO Optics won't let me apply the correction profile for the Minolta/Sony 28-75mm, all of which are more or less the same lens.  The LensType for the Minolta 28-75mm is 39.  Is there a way to change just this tag from 24.6 to 39?  Can it be done in a shortcut or do I need to use the command interface, and how do I do either?  I've read the documentation but I'm just not that knowledgable with this sort of thing.  Will changing just this tag fix this?

Thanks,
Sam.
Title: Re: Editing Lens ID?
Post by: Phil Harvey on August 17, 2010, 07:47:48 AM
Hi Sam,

It doesn't hurt to try:

exiftool -n -lenstype=39 FILE

or

exiftool -lenstype="Minolta AF 28-75mm F2.8 (D)" FILE

- Phil
Title: Re: Editing Lens ID?
Post by: sam_553817 on August 17, 2010, 06:03:12 PM
Hi Phil,

Thanks for the quick reply.  That worked for changing the EXIF, DxO is happy but the images now open up in Lightroom with a pink colour cast?  ANy ideas on that?
Title: Re: Editing Lens ID?
Post by: sam_553817 on August 17, 2010, 06:13:34 PM
Forgot to mention, I get a message saying:

"Warning: [minor] Entries in SubIFD were out of sequence. Fixed."
Title: Re: Editing Lens ID?
Post by: sam_553817 on August 17, 2010, 07:05:04 PM
Comparing the exif of the modified and original files, the following changes have been made:

Original:  JpgFromRawStart: 155683
Modified: JpgFromRawStart: 98388

Original:  LensID: Sigma 18-50mm F2.8 or Sigma 20-40mm F2.8 EX DG Aspherical IF or Tamron SP AF 28-75mm F2.8 XR Di (IF) Macro
Modified: LensID: Minolta AF 28-75mm F2.8 (D)

Original:  LensType: Minolta/Sony AF 24-105mm F3.5-4.5 (D) or Sigma or Tamron Lens
Modified: LensType: Minolta AF 28-75mm F2.8 (D)

Original:  SR2SubIFDLength: 53248
Modified: SR2SubIFDLength: 53068

Original:  SR2SubIFDOffset: 36528
Modified: SR2SubIFDOffset: 41564

Original:  StripOffsets: 688128
Modified: StripOffsets: 608598

Original:  ThumbnailOffset: 32770
Modified: ThumbnailOffset: 94822

Does that help at all?  Sorry for all the q's.

Thanks,
Sam.
Title: Re: Editing Lens ID?
Post by: Phil Harvey on August 17, 2010, 08:01:58 PM
Yes.  This is a bug in Lightroom that has not yet been fixed (although I reported it to them back in January).  See the Known Problems (https://exiftool.org/index.html#problems) section on the ExifTool home page for details.

It is somewhat ironic that DxO reads the edited NEF alright, but Lightroom doesn't because I have read a statement from one of the DxO programmers that said they only support reading of original RAW images.

- Phil
Title: Re: Editing Lens ID?
Post by: sam_553817 on August 18, 2010, 09:22:11 PM
Thats annoying!

May have found a work around though, converting to dng first, then editing exif with the following:

exiftool -n -lenstype=39 -lens="Minolta AF 28-75mm F2.8 (D)" -lensinfo="28/1 75/1 28/10 28/10" -dnglensinfo="28/1 75/1 28/10 28/10" c:\users\sam\desktop\26

But with this I get a warning saying:

"Waring: Not a floating point number for ExifIFD:LensInfo
Waring: Not a floating point number for IFD0:DNGLensInfo"

It still changes the LensInfo tag to "28/1 75/1 28/10 28/10", but not the DNGLensInfo tag, which stays as "24-105mm f/3.5-4.5"

If I use exiftool -n -dnglensinfo= -lenstype=39 -lens="Minolta AF 28-75mm F2.8 (D)" -lensinfo="28/1 75/1 28/10 28/10" c:\users\sam\desktop\26

then I can just get rid of the tag, but I'd rather not do that.

What I am doing wrong here with the LensInfo and DNGLensInfo?
Title: Re: Editing Lens ID?
Post by: Phil Harvey on August 19, 2010, 07:43:26 AM
Both DNGLensInfo and LensInfo are converted the same way (so it shouldn't be writing LensInfo either as you suggested).  With the -n option, they expect 4 floating point numbers, ie. "28 75 2.8 2.8", as mentioned in the EXIF tag name documentation (https://exiftool.org/TagNames/EXIF.html).

- Phil

[edit] Be sure you are using a recent version of ExifTool (8.17 or later, since the LensInfo conversions were improved in that version).
Title: Re: Editing Lens ID?
Post by: sam_553817 on August 19, 2010, 05:07:40 PM
thanks for all your help.