フィルターのクリア

find the the gravity

1 回表示 (過去 30 日間)
ibleteus
ibleteus 2012 年 9 月 28 日
I have amorph shape in my picture, how can i find the gravity and auto draw a rectangular around it of find gravity and the width and height of shape. I used (regionprop (BW,'centroid') to find center but in this section i have problem. first i defined that any z>0 must be calculated, but the result was to strange. i

採用された回答

Image Analyst
Image Analyst 2012 年 9 月 28 日
Did you run my Image Segmentation Tutorial? http://www.mathworks.com/matlabcentral/fileexchange/?term=authorid%3A31862 All you have to do is replace Centroid by WeightedCentroid and it will give you the center of gravity. Centroid does not do that - it assumes all pixels in the blob are weighted the same (have the same gray level), in other words, it uses only the binary image, not the grayscale image.

その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by