2D meshes example

Hi everybody, I hope you can help me here. I'm looking for files examples of 2D coordinates of any object (or mat files for matlab). for example the cat attached. I'm looking for a long time and didn't find anything. it doesn't need to be accurate, just to be a nice closed curve of the object that I can load and draw in matlab. any links/ideas?
Edit: That is NOT a do it for me question!!! why did you close my question??? I just asked for a link of 2d files (files of x,y coordinates). I didn't ask for any code!

2 个评论

That is NOT a do it for me question!!! why did you close my question??? I just asked for a link for 2d files (files of x,y coordinates). I didn't ask for any code!
You can obtain the boundary of any grayscale image after converting it to a binary image(2 dimensional array of zeroes and ones representing black and white), which would automatically form a closed loop.The following is an example code to obtain the the boundary of a grayscale image in the form of binary image. You can use 'imshow' function to plot the binary image.
% Read grayscale image into the workspace.
>>I = imread('rice.png');
%% % Convert grayscale image to binary image using local adaptive % thresholding.
>>BW = imbinarize(I);
Calculate the perimeters of objects in the image.
>>BW2 = bwperim(BW,8);
Display the original image and the perimeters side-by-side.
>>imshowpair(BW,BW2,'montage')
Please refer the below links for more information:
https://www.mathworks.com/help/images/ref/bwboundaries.html https://www.mathworks.com/help/images/ref/bwperim.html https://www.mathworks.com/matlabcentral/answers/167306-find-the-coordinates-of-an-image

请先登录,再进行评论。

回答(0 个)

类别

帮助中心File Exchange 中查找有关 Introduction to Installation and Licensing 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by