0

我正在尝试复制 T. Mertens 等。人。在论文 [1] 中,作者提出了一种方法,可以将使用不同相机曝光拍摄的多张照片融合成一张“更好”曝光的照片。论文 [2] 还提供了一个 Matlab 演示代码。该方法非常简单:计算每个像素的像素权重图,然后使用权重图和拉普拉斯/高斯金字塔混合方法组合图像,以防止混合伪影。

我基本上已将 Matlab 代码移植到 C++,但与 Matlab 实现相比,生成的图像看起来有些褪色(图片:http: //imageshack.us/photo/my-images/204/exposuresample.jpg/)。

我已经比较了我的 C++ 端口处理工作流程中的不同步骤,但这些似乎没问题。我的金字塔处理似乎有问题。

有图像处理背景的人有什么建议或想法可能导致褪色结果吗?

问候,

[1] http://research.edm.uhasselt.be/%7Etmertens/exposure_fusion/ [2] http://research.edm.uhasselt.be/%7Etmertens/exposure_fusion/exposure_fusion.zip

4

1 回答 1

0

It appears as though the second image is either offset by some constant, effectively causing it to appear 'brighter' and saturated on very bright areas, or it is multiplied by a constant, causing it to be saturated in some areas. You can test this by checking the value of a few pixels you assume to be black. If expected black is indeed black, then it's multiplicative. I cannot make it out in the image you attach.

My bet would be on the first case, though.

To debug this, I would check throughout the algorithm if any pixel operation results in over 255 (or 1, depending if you work with doubles or integers) and work from there. Or for a quick and dirty solution, check if you can correct the final image by subtracting a value or dividing by a small value (1.3 or something)

于 2012-01-07T19:56:05.543 回答