how to get LSB in 8-bit grayscale images
3 ビュー (過去 30 日間)
古いコメントを表示
hi, i have one image (8-Bit Gray-scale Image) and i want to omit it's Least_Significant_Bit of it. But i don know how to do it.
1 件のコメント
採用された回答
その他の回答 (2 件)
Matt J
2013 年 10 月 26 日
編集済み: Matt J
2013 年 10 月 26 日
Whatever the problem is, it doesn't originate in the code you've shown. I get no such result
>> img=uint8(randi([0,255],512)); LSBImg =( im2uint8(img) - rem(im2uint8(img), 2)); g= imsubtract(img,LSBImg);
>> whos img LSBImg g
Name Size Bytes Class Attributes
LSBImg 512x512 262144 uint8
g 512x512 262144 uint8
img 512x512 262144 uint8
1 件のコメント
Image Analyst
2013 年 10 月 27 日
編集済み: Image Analyst
2013 年 10 月 27 日
What code? I didn't see any code - perhaps he edited it away. The code Matt J has look similar to a question I answered in http://www.mathworks.com/matlabcentral/answers/90789#answer_100248 except that I operated on the uint8 image directly and didn't use im2uint8:
% Set LSB = 0
grayImage2 = grayImage - rem(grayImage, 2);
Image Analyst
2013 年 10 月 27 日
Try this:
% Set LSB = 0
grayImage2 = grayImage - rem(grayImage, 2);
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Read, Write, and Modify Image についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!