フィルターのクリア

Remove Rows/columns of a rgb Image

10 ビュー (過去 30 日間)
marie lasz
marie lasz 2020 年 10 月 10 日
コメント済み: Ameer Hamza 2020 年 10 月 10 日
Hello ,
I have a rgb image 512x512 pixels. I want to remove it's rows or columns pixels. How can I do that in matlab? Any help please :)
Thanks

回答 (1 件)

Ameer Hamza
Ameer Hamza 2020 年 10 月 10 日
Something like this
img; % 3D RGB image array
c = []; % list of columns to delete
r = []; % list of rows to delete
img(r,c,:) = []
  2 件のコメント
marie lasz
marie lasz 2020 年 10 月 10 日
thanks for you kind response. I didn't get this line of code: img(r,c,:) = []?
Ameer Hamza
Ameer Hamza 2020 年 10 月 10 日
This line delete the rows specified in vector 'r', and columns specified in vector 'c' from variable img. [] tells MATLAB to delete those lines.

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

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by