How to save detected feature points on chess board pattern

1 vue (au cours des 30 derniers jours)
Yunseok Song
Yunseok Song le 10 Mai 2016
Modifié(e) : Matt Cohen le 16 Mai 2016
Hi guys
I'm trying to find a feature points on chessboard pattern using 'detectCheckboardPoints' function.
Basically provided example shows how to plot the points on the chessboard pattern like below
=====================================================================================
imageFileNames = imageFileNames(imagesUsed);
for i = 1:numel(imageFileNames)
I = imread(imageFileNames{i});
subplot(2, 2, i);
imshow(I); hold on; plot(imagePoints(:,1,i), imagePoints(:,2,i), 'ro');
end
=====================================================================================
But, i want to save feature points on a chessboard pattern as an 'png' file.
how can i make it?
Thankyou

Réponses (1)

Matt Cohen
Matt Cohen le 16 Mai 2016
Modifié(e) : Matt Cohen le 16 Mai 2016
Hi Yunseok,
I understand that you have found the feature points on a chessboard pattern and are interested in saving it as a PNG file.
You should be able to use the PRINT function to save a figure as a PNG file. The following code saves the current figure as a PNG file with name 'checkboardPattern':
print('checkboardPattern','-dpng')
Try adding this line after the for loop in the code you provided and see if it accomplishes the desired task. You can also manually save the figure to an image by using the "File -> Save As" option from the figure's menubar.
You can refer to the documentation link for the PRINT function provided above for more information on how to use it and other input arguments for the function.
I hope this proves to be helpful for you.
Matt

Community Treasure Hunt

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

Start Hunting!

Translated by