0

I'm blending two images by taking the distance transform, and using the result of the distance transform, I perform dt1/(dt1+dt2). This gives me the alpha for both the images, which I then apply it. But this quite frequently leads to duplication, like so:

enter image description here

I've referred to the following (but I couldn't find a conclusive solution):

http://graphics.cs.cmu.edu/courses/15-463/2010_spring/Lectures/blending.pdf

https://dsp.stackexchange.com/questions/29156/blending-artifacts-in-opencv-image-stitching

Community
  • 1
  • 1
Metal
  • 143
  • 2
  • 9
  • What is the your initial problem statement and final expected results, kindly elaborate your question – ZdaR Jul 22 '16 at 09:49
  • have a look at cross-blending / alpha-blending: http://stackoverflow.com/questions/37911062/how-to-obtain-the-right-alpha-value-to-perfectly-blend-two-images/37918596#37918596 – Micka Jul 22 '16 at 09:51
  • My problem statement is, how do I remove the duplication, as seen in the image above. When two images are blended, the vessels of both images are made visible, so there's duplication. – Metal Jul 22 '16 at 09:52
  • 1
    @Micka, I'm using exactly that! – Metal Jul 22 '16 at 09:52
  • so your problem is that the registration isn't good enough? if you change the alpha-value computation (e.g. quadratic decrease to the image border) you might get better results. The better solution would be to use non-linear blending approaches optimized to your problem. Like it was used in "Image quality assessment of endoscopic panorama images." from Behrens et al. (we used intensity based non-linear weights but you could prefer just the distance to the image center as weight) with standard techniques it is unlikely to prevent double-appearances if registration isnt perfect. – Micka Jul 22 '16 at 09:58
  • @Micka, thanks! Could you please explain "quadratic decrease to the image border"? – Metal Jul 22 '16 at 10:00
  • @Metal before blending, square each element of dt1 and dt2. But this will only help if the region of interest (the region where those artifacts happen) is near to the image center in one image and nearer to the border in the other image. If that's not the case it can't be decides which image holds the "better" information for that region. then you might need more overlap of both images. In the end it is important that it would be better to have a better registration right in the beginning. – Micka Jul 22 '16 at 10:15

0 Answers0