??? Attempt to reference field of non-structure array.
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Following code is for manipulating matrix of image to change color of some pixel
for row=1:rows
for col=1:columns
s=I(row,col);
if(s.Equals(0))
...... end end end
I am getting following error ??? Attempt to reference field of non-structure array.
0 comentarios
Respuestas (1)
the cyclist
el 16 de Abr. de 2013
In MATLAB syntax,
s.Equals
is referencing a field named "Equals" in a structure named "s".
Are you trying to test if s is equal to zero? If so, then you want
if s==0
2 comentarios
the cyclist
el 16 de Abr. de 2013
Since my answer solved your issue, please accept it, which may help future users seeking a similar solution.
Ver también
Categorías
Más información sobre Get Started with Image Processing Toolbox en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!