O'Reilly logo

Raspberry Pi: Amazing Projects from Scratch by Richard Grimmett, Matthew Poole, Arush Kakkar, Ashwin Pajankar

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Rendering the video

We are now ready to render the video from the sequence of images we just collected. We will begin rendering the video by entering the terminal window. Navigate to the stopmotion folder with the following command:

cd /home/pi/stopmotion

Then, execute the following command to begin rendering the video:

avconv -r 10 -qscale 2 -i frame%03d.jpg animation.mp4

We will now see what each part of this command does:

  • -r specifies the frame rate for the video, which is currently set at 10
  • -qscale specifies the quality for the video and can range from 2-5
  • -i specifies the input file

Once the rendering is complete, you can play it with the following command:

omxplayer animation.mp4

Congratulations! You have just created your own stop-motion animation ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required