MATLAB: 24-bit RGB -> 3-bit RGB conversion

image processing

Hi,
I need a conversion for images whose RGB values are 8-bit each, and I want to degrade them to 3-bit RGB. I think there is no single solution and I'm trying to get an effective way to do it.
Could you help about what kind of functions I need to use?
Thanks.

Best Answer

RGB3 = uint8(IMG >= 128);