简体   繁体   English

使用网格进行图像变形

[英]Image warping using mesh

I would like to warp one fisheye image: Left:我想扭曲一张鱼眼图像: 左:

Into this target image:进入这个目标图像:

The target image is actually a part of the synthetic panorama:目标图像实际上是合成全景图的一部分:

I know a method called mesh warping, like:我知道一种称为网格扭曲的方法,例如:

But how am I able to find or define a irregular mesh like this?但是我如何才能找到或定义这样的不规则网格? Very grateful if someone can give me some suggestions.如果有人能给我一些建议,非常感谢。 I would like to have this mesh, so that I can use this mesh for every frame of a video and warp every frame into this target image.我想要这个网格,以便我可以将这个网格用于视频的每一帧,并将每一帧扭曲到这个目标图像中。

Is this a one-off project, or are you trying to write an automatic procedure?这是一次性项目,还是您正在尝试编写自动程序?

If the former, you can just hand-tag corresponding points in the two images till you have enough coverage, particularly in the more "curvy" areas, then warp using (for example) a thin-plate spline defined by the point correspondences.如果是前者,您可以手动标记两个图像中的对应点,直到您有足够的覆盖范围,尤其是在更“弯曲”的区域,然后使用(例如)由点对应定义的薄板样条线进行扭曲。 This works iteratively: match some points, warp, figure out where the error is largest, add more point matches there.这是迭代地工作:匹配一些点,扭曲,找出错误最大的地方,在那里添加更多点匹配。 Doing all this in, say, Matlab or Python+OpenCv is quite easy.在 Matlab 或 Python+OpenCv 中完成所有这些工作非常容易。

You can then try to automate it using feature extraction and matching.然后,您可以尝试使用特征提取和匹配将其自动化。 The trouble is you'll need to use both point and line correspondences...问题是你需要同时使用点和线对应...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM