Compute horizontal, vertical, left, right profile of a character image

5 Ansichten (letzte 30 Tage)
Rajesh M
Rajesh M am 26 Nov. 2015
Kommentiert: Arsalan Akbar am 26 Apr. 2018
How to calculate left, right, top, and bottom profile of a character image of size MxN. That is outside distance between the bounding box of character image and the edge of the character. (on each row of each first encountered pixels from left for left profile, similarly for right, top, and bottom edges of bounding box.) I want to store it into arrays array equal to size M for left/right and N for top/bottom for image/character. Note:
Thanks

Antworten (1)

Image Analyst
Image Analyst am 26 Nov. 2015
What's the difference between the top and bottom profile? To get vertical and horizontal profiles, use sum() or mean():
verticalProfile = sum(grayImage, 2);
horizontalProfile = sum(grayImage, 1); % Or could use mean()
  3 Kommentare
Image Analyst
Image Analyst am 28 Nov. 2015
You could probably use the distance transform, bwdist().
Arsalan Akbar
Arsalan Akbar am 26 Apr. 2018
i have posted a question . this is the link . please can you check this https://www.mathworks.com/matlabcentral/answers/397454-image-with-horizontal-longitudinal-view

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Image Processing Toolbox finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by