Risposta accettata

The problem is probably that you named your image ‘image’. That’s the name of a quite useful core MATLAB function you will likely want to use. (This is called ‘overshadowing’ — in this instance overshadowing the funciton name with your variable name.)
This works:
I = imread('charuleelaa vanilavarasu_1.jpeg');
gray=rgb2gray(I);
figure(1)
imshow(gray)

Più risposte (1)

Walter Roberson
Walter Roberson il 3 Feb 2016

0 voti

Do not use "image" as the name of a variable.
You do not show your code. Note that you must pass the result of imread to the function, not the file name.

Categorie

Community Treasure Hunt

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

Start Hunting!

Translated by