plus Integers can only be combined with integers of the same class, or scalar doubles.!!!

1 次查看(过去 30 天)
hello sir. when i run this particular piece of i code i get error. I donot know what is the problem here.can anyon find my mistake and correct me
[length width] = size(I_out);
for i = 1:1:length
for j = 1:1:width
if (I_out(i,j) == WHITE)
I_hybrid(i,j) = I_hybrid(i,j) + [0.25 0 0]; ///error in this line
end
end
  1 个评论
Walter Roberson
Walter Roberson 2013-11-9
What is the intent? Is the intent to take a value that is an integer in the range 0 to 255, and add 1/4 to it, resulting in (for example) 92.25 from 92? Or is the intent to take a value that is a floating point number in the range 0 to 1, and add 1/4 to it, such as taking (92/255) to (92.25/255) ?

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Image Segmentation and Analysis 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by