Re: [PanoTools-devel] tilt functions

 Re: [PanoTools-devel] tilt functions From: Pablo d'Angelo - 2009-09-22 20:14:54 ```D M German wrote: > > Hi Pablo, > > I think it is great that you implemented this. > > But, are both methods solving the same problem? I think they are not. > > Imagine a very long wall, all of which is a single plane. The tilt model > does not assume a translation of the center of the image, only a > remapping of the plane. In such a case, as the person walks along the > wall, the angle for tilt is small, and the scale close to 1. > > If I understand correctly, this new positional model moves the photo > viewing point to the center of the panosphere. As the wall gets longer, > I would imagine the error becomes larger. and we have the problem of the > sphere being bound at 360 degrees. Actually, the new model is bound to a plane, so it can't handle anything more than 179 degrees. If the pano is straightened properly, the rectilinear view of the plane won't be distorted, even if it is extremly wide. For an illustration, take a panorama that has been captured close to a wide (and completely flat) facade, and view it in an interative viewer. Zoom out to an extremely wide view (lets say hfov=130 or so). If you view the facade head on without distortion. If you move a little, it will start to exhibit lots of perspective "distortion". I think the fact that there is only one plane through which the images are remapped could actually improve stability for longer areas. In my current implementation, the plane on which the non center cameras are projected is currently fixed to z=-1 (straight ahead). The default pano camera is then located at 0,0,0 and we only images that have X,Y,Z != 0 go through this plane. This means that images that are located at the origin can be stitched to full spherical without problems. This is fine for normal mosaics, but for nadir patching, the plane should be in the at y=-1. Ideally the plane should be configurable. > Correct me if I am wrong, but I think the tilt functions can be used for > mosaics of a known plane better than the spherical model. I guess both could be used. I tried with the aerial images posted on hugin-ptx and I didn't manage to get a decent result with even only a small number of images. With my new model is is much better but not perfect yet. Once both things are in, we can try and see which the pros and cons of each method. > Please commit the changes. I'll add new parameters for your model in the > parser. Just tell me what you need. Ok, I have just commited my changes. If you open adjust.c and search for MOSAIC_XYZ, you can see what is required. If MOSAIC_XYZ is defined, the tilt mode is replaced with the method described above. I'd like to reuse the X,Y,Z parameters in the script, but I'd have to do quite some digging to introduce them to the optimizer, you probably know better which places need to be modified. It would be great if you could add these to the correct_Prefs struct and the places where the optimizer needs it. ciao Pablo ```