Streaming live video with ffmpeg/ffplay

Software,Technique — Tags: — John Mars @ 9:33 am

FFmpeg is a multi-platform command-line application for streaming, recording, converting, and saving video and audio. It includes a variety of related programs, including FFplay, which displays video in a window (vanilla FFmpeg on its own does not).

First, install it on your device.

Either build from source, install via your favorite package manager (apt-get, aptitude, brew, etc.), or download a pre-compiled binary (Windows, Mac).

Second, find a stream.

For our project, the ARDrone was streaming video using a custom variant (PaVE) of a regular H.264 video, streaming along TCP port 5555 from

Third, ffplay.

In our case, this easy little command is what did the work (your case will undoubtedly be different):

It has four parts. On the left is ffplay, the application that is doing all of the work. To the right, tcp:// tells ffplay that we will be using the TCP protocol (as opposed to http, ftp, udp, etc.). is the IP address of the server, and :5555 is the port we will be looking at.

Put it all together, and video should flow like a slightly-laggy waterfall (FFplay has some latency issues).

As always, read through all of the documentation and fully understand what you’re trying to accomplish and how you’re going to accomplish it, instead of randomly replacing values.


No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a comment

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License.
(c) 2020 Making Things Interactive | powered by WordPress with Barecity