how to select a particular portion in am image automatically?
1 次查看(过去 30 天)
显示 更早的评论
In a video of a man walking in a plain background... i splited that into frames.now i want in each of the frames just to select where the man is? not the other things.. i used imcrop(a) but its manual thing... is any function avail in matlab to select automatically in a rectangular fasion?
Is my question clear? Thanks in advance...!
0 个评论
采纳的回答
David Legland
2012-9-21
Hi,
using imcrop you can also specify the coordinates of the box. Then you do not have to click. But you have to know the position in advance.
If you are looking for a method that detect the position of the man, this is an image segmentation problem. There are various methods in image processing toolbox. One possibility is to try to use graythresh function, together with im2bw. There are other more complicated algorithms, the most appropriate one depends on the kind of image.
You can extract the bounding box of a region with the "regionprops" function, using the 'BoundingBox' tag.
Regards, David
0 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Image Segmentation and Analysis 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!