AVIファイルを作成​する際にエラーが表示​されるのはなぜですか​?

14 views (last 30 days)
MathWorks Support Team
MathWorks Support Team on 14 Dec 2009
下記のようにAVIファイルを作成すると、エラーが表示されます。
mov = avifile('fn6.avi');
figure
line
mov = addframe(mov,gcf);
pause
mov = addframe(mov,gcf);
mov = close(mov);
(エラーメッセージ)
Error using ==> avifile.addframe>ValidateFrame
Frame must be 560 by 421.
回避方法を教えてください。

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 14 Dec 2009
GETFRAME関数をご利用いただくことで回避することが可能です。
mov = avifile('pd3.avi');
figure
surf(peaks)
frame = getframe(gcf);
mov = addframe(mov,frame);
frame = getframe(gcf);
mov = addframe(mov,frame);
mov = close(mov);

More Answers (0)

Categories

Find more on 印刷と保存 in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!