Merge two images without light effect
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Dear all,
Let say I take two pictures without moving the camera with the difference of few sec. Image 1 is denoted as img1, and Image 2 is denoted as img2. Now I want to concatenate the first half of image with the second half of the image.
img2 (:,1: size(img2,2)/2,:) = img1(:, 1: size(img1,2)/2,:);
There is no problem in exection. However, these two images have light effect though take with the time difference of few seconds. What image processing task should be taken to neutralize the light effect.
2 Commenti
Walter Roberson
il 25 Apr 2016
Your line
img2 (:,1: size(img2,2),:) = img1(:, 1: size(img1,2),:);
does not concatenate. 1: size(img,2) is the same as 1:end when used in the second dimension of img2, and that in turn is the same as just using : . So you have the equivalent of
img2(:,:,:) = img1(:,:,:);
If you want to concatenate use
[img1, img2]
Risposte (1)
Image Analyst
il 25 Apr 2016
If the image brightness at the same part of the image changed as you moved the camera, either due to the lighting changing during that time, or due to shading in the camera (primarily due to the lens), then the overlap region, which you averaged together during the compositing process, may show brightness differences or noticeable edges where it goes from two images to 1 image. So you will have to have a mask to somehow adjust the intensity of one of the images, and you may need to adjust it spatially, like "feather" the intensity so you do not have noticeable edges or sharp intensity discontinuities.
0 Commenti
Vedere anche
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!