필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

To find the lower array of black pixels of a word in an image

조회 수: 1 (최근 30일)
sindhu c
sindhu c 2015년 12월 14일
마감: MATLAB Answer Bot 2021년 8월 20일
I want the lower array of black pixels of this word.I know to count the black pixels but how to get the lower array? Please help me. Thank you

답변 (1개)

Walter Roberson
Walter Roberson 2015년 12월 14일
hprof = ~all(YourImage,2);
first_row_with_black = find(hprof, 1, 'first');
last_row_with_black = find(hprof, 1, 'last');
  댓글 수: 3
Walter Roberson
Walter Roberson 2015년 12월 14일
Change to
hprof = ~all(YourImage,2);
first_row_with_black = find(hprof, 1, 'first')
last_row_with_black = find(hprof, 1, 'last')
sindhu c
sindhu c 2015년 12월 15일
sir,this is what i'm getting .empty array!!

이 질문은 마감되었습니다.

Community Treasure Hunt

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

Start Hunting!

Translated by