複数ファイルに対してコマンド実行
Afficher commentaires plus anciens
n = 12;
for i = 1:n
data = ['32deg_cam1_ (', num2str(i),').jpg'];
pic = imread(data);
gray = rgb2gray(pic);
bw = imbinarize(gray);
bw2 = bwareaopen(bw,30);
boundaries = bwboundaries(bw2,'noholes');
imshow(bw2);
hold on
for k = 1:n
b = boundaries{k};
plot(b(:,2),b(:,1),'g','LineWidth',2);
end
end
複数のイメージ(12枚の写真)に対してのコマンドです.途中までは12枚すべてに処理がなされているのですが,hold on 以下を追加すると1枚目にしかプログラムが適用されませんでした.エラーはなかったのですが,どう変えればよいのでしょうか.
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur イメージ タイプの変換 dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!




