thinking aloud, the fact that the field of view changes when the image is in landscape mode might have interesting repercussions during optimization. I wonder if a better solution would be to scale with respect to the corner of the frame.
-dmg On Mon, Jan 3, 2011 at 3:24 AM, dmg <[email protected]> wrote: > Hi everybody, > > I got curious about how radial correction is computed and did a small test. > > From Helmut's description (remember, he implemented the code): > http://www.all-in-one.ee/~dersch/barrel/barrel.html I learned that the > correction is > > dd + cr + br^2 + ar^3 (found in the function radial). > > Noticed the first parameter dd. In the page above is referred as d, > but d in panotools has a different meaning. > > As he explains, to avoid scaling the sum of dd + c + b + a = 1. > > This is supported by the code. dd is computed from a, b and c to > satisfy the invariant. > > Now, look at the following test: > > http://turingmachine.org/~dmg/temp/test_grid.zip > > It looks as if, in the case of the 2 rectangular images, there is > scaling, but not in the squarish image. > > In the code, the scale of the image is normalized as 1/2 the smallest > of dimensions. This means the image is not scaled with respect to the > longest dimension, > but it is scaled with respect to the shortest dimension. Now, this > example is a bit extreme because the ration width to length is 2. But > even if it was 1.5 (as with > 36mm cameras) the different is significant. > > I suspect helmut did this because most people shoot panoramas with the > camera in portrait mode. This way the "horizontal" field of view, > remains unchanged > after the correction has been applied. > > With this information we should be able to computer a, b and c > parameters from imatest data (such as the ones published at photozone: > http://www.photozone.de/canon-eos/336-canon-ef-35mm-f14-test-report--review?start=1) > > What about the samyang 8mm lens? This radial correction is made before > the photo is remapped to its native projection. One would need to > either: calibrate the lens using the typical methods, or do some math > and approximations > to come to the estimation of these parameters based on the formulas > above. Remember, the lens is closer to stereographic (which we have > implemented in panotools), do not use for this one a typical > equidistant. > > Samyang should donate us a couple of lenses to be able to properly > test the code. It has never been used. > > --dmg > > --- > Daniel M. German > http://turingmachine.org > -- --dmg --- Daniel M. German http://turingmachine.org -- You received this message because you are subscribed to the Google Groups "Hugin and other free panoramic software" group. A list of frequently asked questions is available at: http://wiki.panotools.org/Hugin_FAQ To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/hugin-ptx
