impixelを使用して矩形領域のピクセル値を取得するにはどうすればよいですか。
9 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
impixel関数を用いて、画像の矩形領域(例えば5行5列の25ピクセル)のピクセル値を取得したいです。
c = [ ];
r = [ ];
impixel (Image , c, r)
において、cとrをどのように定義すればよいでしょうか。
6 Kommentare
Antworten (1)
Hiroshi Iwamura
am 6 Apr. 2023
余談ですが、対話型ですので
I = imread('peppers.png');
[x, y, p] = impixel(I)
としてマウスクリックで指定すれば(リターンで終了)座標も得られます。
その座標をそのまま使って
p2 = impixel(I,x,y);
とすることもできます。
Siehe auch
Kategorien
Mehr zu オブジェクト解析 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!