what is lsb planes of an image and what is its significance?

9 次查看(过去 30 天)
im = imread('pout.tif');
bit1 = bitget(im, 1); % lsb for example
imshow(bit1, []

采纳的回答

Walter Roberson
Walter Roberson 2016-10-18
"LSB" is Least Significant Bit.
Suppose you had 8 bits per pixel, 0 to 255. Then the Most Significant Bit (MSB) would be the bit that was either 0 or 128. A change in the MSB would make a difference of up to half of the available brightness. For example, 17 compared to 145 is a change in just the MSB. The Least Significant Bit (LSB) is the other end, the bit which can only make a difference of 1; for example 16 vs 17 is a change in the least significant bit
147 decimal = 10010001 binary
| | |
| | |--- contributes 1 out of the 147, least significant
| |------- contributes 16 out of the 147, intermediate significance
|---------- contributes 128 out of the 147, most significant
When discussing LSB, the topic is often about steganography or watermarking. In those two very closely related topics, the significance of LSB is that if you need to change a bit of the data, then the LSB is the one that produces the least visual change, and so would be least likely to be noticed by the user.
Have look at
image(uint8(2.^(0:7)));colormap(gray(256))
the left bar has only the LSB set; the second bar has only the second bit set; the third bar has only the third bit set, and so on to the right that has most significant bit set. On the typical display settings that I use, I can clearly make out bar 6, 7, and 8, but I have a difficult time determining the boundary between bar 4 and bar 5, with 1 through 4 completely indistinguishable; even if I turn up to full brightness I have a hard time telling where the boundary between 4 and 5 is. So a change to bar 1, the least significant of them, would be visually invisible to me.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Images 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by