How to split an binary image into binary bit sequence?

1 回表示 (過去 30 日間)
Anisa
Anisa 2013 年 1 月 9 日
コメント済み: Anu Sharma 2014 年 4 月 7 日
I have an binary image with size 256x256. I want to split the image into different number of bits. For example:
1 0 1 0 0 0 0 0 0 0 1 0 0 0 1 1 1 1 1 1 0 0 0 0 1 1 1 0 0 0 0 1 0 1 0 1 1 1 1
I want to split it become like this:
[1 0 1 0 0 0 0 0 0 0 1] [0 0 0 1 1] [1 1 1 1] [0 0] [0 0 1] [1 1] [0 0 0 0 1 0 1 0 1 1 1 1]
So, i can use each part for next step.
Any help. Thank you.

採用された回答

Image Analyst
Image Analyst 2013 年 1 月 9 日
For an image, it's the same concept - you can still use linear indexing like that if you want, or you can use 2D indexing if you want:
subImage = fullSizeBinaryImage(row1:row2, column1:column2);

その他の回答 (1 件)

Andrew
Andrew 2013 年 1 月 9 日
編集済み: Andrew 2013 年 1 月 9 日
Hi Anisa,
You can do this in this way:
RawSig=[1 0 1 0 0 0 0 0 0 0 1 0 0 0 1 1 1 1 1 1 0 0 0 0 1 1 1 0 0 0 0 1 0 1 0 1 1 1 1];
FirstPart=RawSig(1:11);
SecPart=RawSig(12:16);
ThirdPart=RawSig(17:20);
Best regards,
Andrew
  2 件のコメント
Anisa
Anisa 2013 年 1 月 9 日
Binary bit above it's just a sample. I need help for image.
Anu Sharma
Anu Sharma 2014 年 4 月 7 日
If we have large sequence of binary.,then how can we split and store it ?
thanks in advance

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeResizing and Reshaping Matrices についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by