This conversion is easy with ffmpeg in two steps.
Step 1: Generate a movie from your screen.
- Open your animated SVG in Mozilla Firefox or Internet Explorer.
Use this command in a terminal:
ffmpeg -s 1440x640 -r 25 -f x11grab -i :0.0 -b 6000k out.avi
With:
- -s specify the format of your animation (here 1440x640 px).
- -r the frames per seconds (Here 25).
- -f the selection of your screen.
- -b the quality (6000k is good quality).
- out.avi name and format of the file.
Now watch your animation in full screen mode (F11). If your animation is looped it's better.
- Stop the recording (Ctrl + C)
Step 2: Save only the interesting part
Use this command in a terminal:
ffmpeg -i out.avi -b 6000k -r 25 -t "00:00:10" -ss "00:00:09" "final.avi"
With:
- -i the file to cut.
- -b the quality.
- -r the frame rate.
- -t the duration of recording (Here 10s).
- -ss the recording start (Here at 9s).
- final.avi the output fil.
Now you have an .avi file