[英]Matlab Video of logical images
I have a video where I apply chroma key to each frame to extract color. 我有一个视频,在其中我将色度键应用于每个帧以提取颜色。
newImage = (checkR)&(checkG)&(checkB);% for each frame
In the end I put all frames in similar video container like: 1x39(frames) of type struct where each struct now contains cdata not in int, but in logical. 最后,我将所有帧放在类似的视频容器中,例如:struct类型的1x39(frames),其中每个结构现在都包含cdata而不是int,而是逻辑上的。 I get an error when I try to play the new video. 尝试播放新视频时出现错误。 I can view individual frames by extracting them, but I need a video. 我可以通过提取来查看单个帧,但是我需要一个视频。
movie(b); % doesnt work
gives error: 给出错误:
??? Error using ==> movie
Movie cdata must be of type uint8 array
Do I have to convert it to int? 我必须将其转换为int吗?
OR 要么
apply some binary mask which I do not know how to do? 涂一些我不知道该怎么做的二进制掩码?
You can convert it to uint8
by 您可以通过以下方式将其转换为uint8
b=uint8(b);
then call movie
然后打电话给movie
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.