problem with rgb to gray conversion

I got the rgb image output but after doing rgb to gray conversion i got null output image. I attached the image for reference. Suggest the way forward.

4 Comments

Did you only do rgb2gray() or did you also do im2double() or perhaps double(), or did you possibly copy the contents of the grayscale image into another array?
I did rgb2gray(). The error was with the code prior to the rgb2gray(), corrected it and got the output also attached the same here. Thanks @ Walter.
So, it's solved now, right?
Yes @ Image Analyst

Sign in to comment.

Answers (0)

Asked:

on 27 Dec 2017

Commented:

on 27 Dec 2017

Community Treasure Hunt

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

Start Hunting!