How do I create 5x5 matrix from a binary image?

The binary images I have appear in a 5x5 grid. But the grid can appear anywhere on the screen, and in different sizes. From the image, I need to produce a 5x5 matrix, 1s for white 0s for black. Any thoughts on how to accomplish this?

댓글 수: 2

At the moment the required result is ambiguous, as you have not defined that the visible grid will always occupy a visual 5 x 5 grid fully. For example at the moment we do not know that it is not possible for there to be
** *
****
* **
** *
which only occupies a 4 x 5 visual grid. The difficulty being that we would not know whether the row of black should be assumed to be on the top or the bottom.
Please insert a screenshot with the green and brown frame icon. Make it easy for us to see your images. It's not easy to see when they're in a .fig file. I have to save them to disk first then open them up in MATLAB. I didn't even bother to look at them. Make it easy for us, not hard.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

도움말 센터File Exchange에서 Images에 대해 자세히 알아보기

태그

질문:

2016년 8월 1일

댓글:

2016년 8월 1일

Community Treasure Hunt

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

Start Hunting!

Translated by