Overlay binary image image on contrast stretched image to get the final result

1 次查看(过去 30 天)
I have to create a function which should take as input the contrast stretched image and the refined binary mask. The output should be the overlay image.Can anyone help?

采纳的回答

Image Analyst
Image Analyst 2020-5-25
Try imoverlay:
% Read in image.
grayImage = imread('cameraman.tif');
% Read a binary image into the workspace.
BW = imread('text.png');
% Burn the binary image into the grayscale image, specifying the color to be used for the binary mask.
rgbImage = imoverlay(grayImage, BW, 'yellow');
% Display the result.
imshow(rgbImage)
  1 个评论
Mit desai
Mit desai 2020-5-26
Yeah thanks man i think this is as good as my code which i figured later because imoverlay doesnt work in octave which i am using. But this however does the same task!!
Cheers!!
in1=imread('enhanced.jpg');
in2=imread('refinedpicture.jpg');
var1=uint8(in1);
var2=uint8(in2);
figure;
output=imadd(var1,var2);
imshow(output);

请先登录,再进行评论。

更多回答(0 个)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by