lensfun
0.3.2.0
|
Adding new cameras is very easy. You just have to know its crop factor, and the EXIF identification strings for this camera; that's all.
If you don't know the crop factor, you can search in google for e.g. “Nikon D300 sensor size”. Let's suppose you found out that your sensor size is 23.6 × 15.8mm. Now compute the length of the diagonal using Pythagora's theorem:
\[ d = \sqrt{23.6^2 + 15.8^2}\,\mathrm{mm} = 28.4\,\mathrm{mm} \]
Now you just divide the magic number 43.27 (the diagonal of a usual 35mm film frame) by the number you got:
\[ \mathrm{cropfactor} = \frac{43.27}{28.4} = 1.523 \]
Now you must find out the identification string for your camera from EXIF data. For this you can use the exiv2 script:
$ exiv2 blah.nef .... Camera make : NIKON CORPORATION Camera model : NIKON D300 ....
Now you can create a XML entry for your camera:
<camera> <maker>Nikon Corporation</maker> <maker lang="en">Nikon</maker> <model>Nikon D300</model> <model lang="en">D300</model> <mount>Nikon F AF</mount> <cropfactor>1.523</cropfactor> </camera>
Now add this definition to a XML database file along Lensfun database search path and your camera will be detected and Lensfun will work properly with images produced by it.