[MATLAB] 制作视频

writerObj=VideoWriter('test.avi'); %// 定义一个视频文件用来存动画
writerObj.FrameRate = 30; % 帧率
open(writerObj);  %// 打开该视频文件
figure()
for k=1:10
	plot(...);
	CF = getframe(gcf);
    writeVideo(writerObj,CF); %// 将帧写入视频
end
close(writerObj);
上一篇:Matplotlib学习


下一篇:如何创建一个输出matplotlib图形的函数?