Image threshold value question
1 回表示 (過去 30 日間)
古いコメントを表示
Hello guys, Normally we set one value 'a', then we have [0 a]= black, [a 255]=white My question is, can we do it like this way, [0 a]=black, [a b]=white, [b 255]=black I hold you can understand my terrible description.
0 件のコメント
採用された回答
Image Analyst
2013 年 2 月 20 日
Sure, just do two comparisons:
binaryImage = grayImage >= a & grayImage <= b;
0 件のコメント
その他の回答 (1 件)
Thorsten
2013 年 2 月 20 日
I = imread('cameraman.tif');
a = 100; b = 150;
ind = setdiff(find(I > a), find(I < b));
B = logical(size(I));
B(ind) = 1;
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Image Processing Toolbox についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!