The FFmpeg source replaces the RTSP source beginning with mimoLive 6.0
FFmpeg is a versatile video utility that can process almost any video format and has a huge variety of protocols. This makes it the universal tool for bringing a lot of different sources into mimoLive, including RTSP, RTMP and SRT.
Due to licensing restrictions, FFmpeg needs to be downloaded and installed by the user separately from mimoLive.
The most convenient way to install FFmpeg is by using Homebrew, a so-called package manager for command line tools. You’ll find the most recent instructions at the Homebrew web page.
1. Open Terminal.app and copy/paste this command to install Homebrew:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
2. Install FFmpeg using this command:
brew install ffmpeg
Enter the path to FFmpeg in mimoLive
Before you can use the FFmpeg source, you need to let mimoLive know where to find it.
To find out the path where ffmpeg is installed, you can use the Terminal and issue the command:
Depending on your MacOS version, this can be
/opt/homebrew/bin/ffmpeg but other paths can also exist.
The file at the path is a symbolic link pointing to the “real” location of ffmpeg. In mimoLive 6 beta versions, you may need to find this real path, for example /opt/homebrew/Cellar/ffmpeg/4.4_2/bin/ffmpeg
Enter this path into the FFmpeg Installation Path field in the mimoLive Preferences:
Using the FFmpeg source
FFmpeg runs as a separate process controlled from mimoLive. By default, it is only launched when a layer it is used in is switched live. In some cases, this can take a few seconds.
Once started, however, the FFmpeg source receives data until the source no longer sends data regardless of whether the source is used in a live layer.
To use the FFmpeg source, add it to the Sources column:
FFmpeg Input Parameter
FFmpeg uses command line parameters for instructions of what it should do. You can enter the parameters by clicking on the edit button next to the text field showing the currently active parameters:
If you click “Save” and FFmpeg is running, the process is stopped and restarted with the new parameters. If you click Cancel, the parameters currently in use are preserved and, if it is running, FFmpeg keeps running.
mimoLive adds some default parameters to the ffmpeg command line that you should omit if you’re experimenting with other protocols. The “hidden” parameters are: -f avi -pix_fmt argb -vcodec rawvideo -acodec pcm_s16le -ac 2 -ar 48000
When playing back a local file you need to put a “-re” upfront to your parameters to tell FFmpeg to playback the file in real time.
-re -i file://User/MyUserName/Movies/MyMovie.mp4
See the subsections on RTMP, RTSP and SRT for examples for parameters to use.
Keep Alive Option
FFmpeg will only be started when a layer it is assigned to is switched live. If you want to run FFmpeg as a server, for example to receive live camera streams via RTSP, RTMP or SRT, checking this checkbox will start FFmpeg immediately and keep it running as long as mimoLive is running regardless of whether the input is actually used by a live layer.
The FFmpeg Log Window
Sometimes the FFmpeg source won’t run. Usually this is due to mistake in the complex parameter setup. To monitor what FFmpeg is actually saying about the parameters and the connection process there is a log window which will output of FFmpeg.
The log is divided into three column:
– Timestamp: The first column shows the time when this log entry was produced.
– Source: Sometimes there will be log entries produced by mimoLive rather than FFmpeg itself. This column will help to distinguish those.
– Log Message: This is the original log output by FFmpeg.
At the bottom of the window there are three options available:
– Autoscrolling: If this option is checked, a new log entry will cause a scrolling down automatically to keep up with the newest information.
– Clear: This Button clears the log window in case you want to start a new log.
– Save…: With the Save button the log can be saved to a text file for further inspection.