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

11 visualizzazioni (ultimi 30 giorni)
im = imread('pout.tif');
bit1 = bitget(im, 1); % lsb for example
imshow(bit1, []

Risposta accettata

Walter Roberson
Walter Roberson il 18 Ott 2016
"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.

Più risposte (0)

Categorie

Scopri di più su Images in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by