Write images from matrices in a cell array? Error?!
1 次查看(过去 30 天)
显示 更早的评论
Hi,
I have a cell in which several 320*320*3 matrices a stored. I would like to convert these matrices into images or even more preferably into a movie. I tried imwrite:
>> cleaned_img{1,k}=imwrite(cleaned{1,k},'jpg')
With the error:
Error using imwrite. Too many output arguments.
What am I doing wrong?
Another question:
Is there a way to view the matrices in the 1*360 cell with the imshow command in a way that I can skip from one image to the other without having to type imshow(cleaned{1,1}) to imshow(cleaned{1,360})? I would like to use imshow or another tool just like for example irfanview, just for the image data stored in the matrices.
Thank you!
0 个评论
回答(4 个)
Wayne King
2012-10-5
imwrite does not output any arguments. If you want to make a video, why are you needing to use imwrite? See the help for VideoWriter
0 个评论
Image Analyst
2012-10-5
imwrite does not return ANY value. So you can't do that.
By the way, you didn't give it a filename, unless cleaned{1,k} was the name, in which case you didn't give it a numerical image array. Plus, like Wayne said, imwrite is no way to write videos.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Audio and Video Data 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!