Lens name for legacy lenses?


Hi there,

After Adobe’s announcement of “subscription only” for Lightroom I’m considering switching back to RawTherapee (which I had used as version 2 a long time ago).

I only use legacy glass on my Sony NEX-6 which does not communicate with the camera. So I manually write the lens name into the “LensModel” tag of every raw file using exiftool.

This works fine for LR, but in RT, the lens is shown as “unknown”.

Is there a way to use an arbitrary text string as lens name in RT? Not only for displaying, but also for using it with filtering, flat field correction, lens profiles etc.?

In case this makes a difference, I am using RT 5.0 (I don’t yet have a 64bit machine) on Windows 7.

Thanks for any help!

(Morgan Hardwood) #2


Find your lens in this list and the one that follows it:

Then backup your photos and run:

exiftool -P -overwrite_original_in_place -LensInfo='Sony E 16-70mm f/4 ZA OSS' photo.raw




Thanks for the quick response.

My lenses are not in these tables. Nor does exiftool accept the lens names as arguments for the LensInfo tag (because the lenses are not in the corresponding exiftool tables either, I guess).

No other possibility?

Best regards,


Yes, no problem with EXIFTOOL. I do it all the time. :wink:

exiftool -P -progress -r -overwrite_original -LensMake="[any text]" -LensModel="[any text]" -FNumber="[any value]" -LensSpec="[anything you want]" filename.ext



Hi PanoMeister,

Maybe a misunderstanding. I’m fine with putting into the raw file any values I like, using exiftool. I’ve done this for years.

However, no matter what and where I write, RT just shows an “unknown” lens. Apparently, if I understand Morgan correctly, because my lenses are not in RT’s lens tables.


(Elle Stone) #6

My lenses aren’t in those tables either (old manual focus lenses with no electronics communication with the camera). But I haven’t ever been bothered enough to do anything about it. So I have a question: if @Bezier is willing to compile RT from source, could he add his lenses to the table before compiling RT, following the format of the other lenses in the table, and then would RT be able to display the lens?

(Ingo Weyrich) #7

@Bezier please upload a sample file to filebin.net and post the link here. I will have a look then.


Here is a file:

I set the LensModel, FocalLength, and FocalLengthIn35mmFormat tags using exiftool. LensModel is the only one I’m interested in here. Of course, I could also write any other tag if this provided a solution.

More generally, couldn’t it be an idea that RT, if it doesn’t find a lens using the current algorithm, looks into the LensModel tag? Naturally, I don’t know if this were compatible with the current implementation.

Thanks & best regards


Coming back to this issue, I found a rather, hmm, mean workaround.

I select a lens from the Sony -lenstype tag list and write the corresponding number to the -lenstype tag using exiftool. Then, I open rawtherapee.exe in a hex editor and overwrite the original lens name with my own.

Works, but of course not very nice.

If I were to compile the RT code myself, I guess I could instead modify the appropriate table in the rtexif section, couldn’t I?

Still, I think it would be great if there were a possibility to have the lens name read as a text string from the -lensmodel tag.

By the way, you guys are doing a great job on RT!

Best regards,