[ptx] clens

Pablo d'Angelo pablo.dangelo at web.de
Sun May 7 08:22:16 BST 2006


Daniel M. German schrieb:
> I have updated clens to take advantage of CreatePanorama. It would be
> great if someone can try to compile it and run it.

I'm quite short on time nowadays (my wedding is in one week ;), so I haven't
tried yet. However, the fulla tool distributed with hugin is a superset of
clens (it can do channel specific radial distortion and vignetting
correction at the same time, and also supports the PTLens database).

While writing fulla, I noticed a bug in clens (Which I didn't want to extend
because I don't like a coding style, where everything is done with global
variables. Fixing it would have been a total rewrite anyway). the computed d
coefficent (constant term of the radial distortion polynomial) is wrong, if
the black borders are cut away, leading to distorted output.

The code for the correct calculation of the d coefficient is in
src/tools/fulla.cpp:122 and src/Panorama/SpaceTransform.cpp:941

I have also improved the PTLens db reading routines not to rely on global
variables. You can find them in the hugin source:
src/include/common/PTLensDB.h and src/common/PTLensDB.c

However, in the future I'd like to use a format where also vignetting and
per channel radial distortion can be stored.

ciao
  Pablo


More information about the ptx mailing list