What do the lens distortion coefficients a, b, and c mean in Hugin/lensfun?
Asked 11/3/2014
4 views
2 answers
0
I'm looking at lens distortion correction in Hugin/lensfun and want to understand what the distortion coefficients a, b, and c actually represent. Are these standard values or specific to this software? A simple explanation of what each coefficient does and how they relate to barrel, pincushion, or more complex distortion would be helpful.
Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0
Photography Stack Exchange contributor
11y ago
2 Answers
7
from http://wiki.panotools.org/Lens_correction_model
The actual lens correction parameters a, b and c which are used to correct for barrel distortion, pincushion distortion and even wavy distortion.
The a and c parameters control more complex forms of distortion. In most cases it will be enough to optimize for the b parameter only, which is good at correcting normal barrel distortion and pincushion distortion.
The lens distortion a, b and c parameters correspond to a third degree polynomial describing radial lens distortion:
r_src = (a * r_dest^3 + b * r_dest^2 + c * r_dest + d ) * r_dest
where r_dest and r_src refer to the normalized radius of an image pixel (distance from the center) A perfect lens would have a=b=c=0.0 and d=1.0 (d is always = 1-(a+b+c)) which resolves into r_src = r_dest
Usual values for a, b and c are below 1.0, in most cases below 0.01. Too high values suggest that you chose a wrong lens type, f.e. fisheye instead of rectilinear or vice versa. This refers to the absolute values of course since a, b and c can be positive or negative (f.e. both 4.5 and -4.5 are considered too high values).
Originally by user32811. Source · Licensed CC BY-SA 4.0
user32811
11y ago
0
Generated from our catalog & community — verify before relying on it.
In Hugin/lensfun, a, b, and c are coefficients in a radial distortion model. They describe how far a point should be moved based on its distance from the image center.
The model is:
r_src = (a·r_dest^3 + b·r_dest^2 + c·r_dest + d) · r_dest
where r_dest and r_src are normalized radii (distance from the center), and d is set so the scaling stays consistent: d = 1 - (a + b + c).
In plain terms:
- b is the main term for ordinary barrel or pincushion distortion, and often the only one needed.
- a and c handle more complex distortion shapes, including stronger edge behavior or “wavy” distortion.
- If a = b = c = 0, then d = 1, so r_src = r_dest: no distortion.
So these values are not arbitrary labels; they are polynomial coefficients used to map ideal image points to distorted or corrected positions. They are part of the distortion model used by Hugin/panotools-style tools.
Recommended products
UniqueBot
AI11y ago
Your Answer
Related Questions
What geometric standard do software lens-correction profiles use?
What’s the difference between perspective distortion and barrel, pincushion, and mustache distortion?
What are barrel and pincushion distortion, and how are they corrected?
How do Micro Four Thirds cameras know a lens’s distortion correction settings?
Why do smartphone wide-angle photos make objects near the edges look stretched, and why isn’t that automatically “fixed”?