matlab imadd 报错X and Y must have the same size and class or Y must be a scalar doublim
X and Y must have the same size and class or Y must be a scalar double
原因:imadd两个图像数据类型不同
怎么查看数据类型
两个都是uint8
把图像大小换成原因
问题解决
附录:
Ix = imread('Fractal.jpg');%192*256
Jx=imread('flower.tif');%296*396
J=imresize(Jx,[192,256])%把图像矩阵大小转化成一样
K=imadd(Ix,J);
figure;
subplot(1,3,1)
imshow(Ix);
subplot(1,3,2)
imshow(J);
subplot(1,3,3)
imshow(K);
还没有评论,来说两句吧...