How can I recover to original image after i changed to gray level ?

1 view (last 30 days)
Img=imread('image1.jpg');
Gray=rgb2gray(img);
How convert Gray to original color now????

Accepted Answer

Image Analyst
Image Analyst on 18 Sep 2015
Very simple in fact trivial:
Gray = Img;

More Answers (1)

Walter Roberson
Walter Roberson on 18 Sep 2015
If you are using uint8 RGB, then there are 256^3 different RGB combinations and they must map to 256 values. On average, each gray level must correspond to 256^2 = 65536 different RGB combinations. So given only the gray level, how can you possibly know which of the 65536 it "really" is?

Community Treasure Hunt

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

Start Hunting!