Image processing for pattern restoration
Hi.
I am working on restoring unclearly printed rectangular patterns using MATLAB. All original patterns are exact rectangular, and I am taking photos for collecting original printed images by a camera. The attached images show the original image used (first), the filled image extracted through the written code (second), and the desired final image (third). My goal is to achieve an image like the third one. The edges do not need to be perfectly rectangular; a rough restoration is sufficient. Any clue would be helpful to me. Thank you.
clc; clear;
imFile="image1.jpg";
Image_Original=imread(imFile);
Image_Gray=rgb2gray(Image_Original);
Image_Inversed = imcomplement(Image_Gray);
Image_BW = imbinarize(Image_Inversed);
Image_BW_filled = imfill(Image_BW,"holes");
edges = edge(Image_BW_filled, ‘Canny’);
imshow(Image_BW_filled)Hi.
I am working on restoring unclearly printed rectangular patterns using MATLAB. All original patterns are exact rectangular, and I am taking photos for collecting original printed images by a camera. The attached images show the original image used (first), the filled image extracted through the written code (second), and the desired final image (third). My goal is to achieve an image like the third one. The edges do not need to be perfectly rectangular; a rough restoration is sufficient. Any clue would be helpful to me. Thank you.
clc; clear;
imFile="image1.jpg";
Image_Original=imread(imFile);
Image_Gray=rgb2gray(Image_Original);
Image_Inversed = imcomplement(Image_Gray);
Image_BW = imbinarize(Image_Inversed);
Image_BW_filled = imfill(Image_BW,"holes");
edges = edge(Image_BW_filled, ‘Canny’);
imshow(Image_BW_filled) Hi.
I am working on restoring unclearly printed rectangular patterns using MATLAB. All original patterns are exact rectangular, and I am taking photos for collecting original printed images by a camera. The attached images show the original image used (first), the filled image extracted through the written code (second), and the desired final image (third). My goal is to achieve an image like the third one. The edges do not need to be perfectly rectangular; a rough restoration is sufficient. Any clue would be helpful to me. Thank you.
clc; clear;
imFile="image1.jpg";
Image_Original=imread(imFile);
Image_Gray=rgb2gray(Image_Original);
Image_Inversed = imcomplement(Image_Gray);
Image_BW = imbinarize(Image_Inversed);
Image_BW_filled = imfill(Image_BW,"holes");
edges = edge(Image_BW_filled, ‘Canny’);
imshow(Image_BW_filled) image, image processing, image restoration MATLAB Answers — New Questions