OMXPlayer is a command-line video player for the Raspberry Pi. It plays video directly from the command line and plays outside your desktop environment. OMXPlayer uses the OpenMAX API to access the hardware video decoder in the GPU. Hardware acceleration along with command-line use allows ultra low overhead, low power video playback. It was originally developed as a testbed for Kodi on the Raspberry Pi.
This fork adds the following features:
-
Position remembering: If you stop playing a file, OMXPlayer will remember where you left off and begin playing from that position next time you play the file.
-
Auto-playlists: OMXPlayer will automatically play the next file in the folder when the previous file finished.
-
Recently played folder: OMXPlayer creates a folder called OMXPlayerRecent off your home directory with links to 20 most recently played files.
-
Experimental DVD support: OMXPlayer can play iso/dmg DVD files as well DVD block devices.
-
CEC Input: OMXPlayer should respond to commands from your TV's remote control.
OMXPlayer does not support software video decoding. HEVC is not supported, and DVD video will only play on systems with mpeg2 hardware decoding. This can be purchased on rpi3 but isn't available on the rpi4.
DVD menus are not supported.
OMXPlayer will not work on 64bit systems.
To compile OMXPlayer natively on you Raspberry PI you will need around 230 MBs of RAM. You will also need the following packages:
Bullseye no longer comes with the required firmware files but it should still be possible to get the required files by compiling and installing RaspberryPi's userland repo (requires cmake).
To compile omxplayer you will also need the following packages*:
git libasound2-dev libpcre2-dev libboost-dev libcairo2-dev libdvdread-dev
libdbus-1-dev libavutil-dev libswresample-dev libavcodec-dev libavformat-dev
Once you have these installed you should be able to compile OMXPlayer with a make
To run OMXPlayer need to disable the kms driver. You can do this by replacing it with the fake
kms driver or by disabling it completely. You can do this by changing the dtoverlay
setting in
your system's /boot/config.txt
file.
# kms is enabled so omxplayer can't run
dtoverlay=vc4-kms-v3d
# the fake kms driver is enabled (note the f before kms)
dtoverlay=vc4-fkms-v3d
# the kms driver is completely disabled
#dtoverlay=vc4-kms-v3d
You will also need the following static libraries:
libbrcmEGL.so libbrcmGLESv2.so libopenmaxil.so
which should be in the /opt/vc/lib
directory.
You will also need the following packages*:
libavcodec58 libavformat58 libavutil56 libswresample3 libcairo2
(These packages are included in the full version of Raspberry PI OS.)
Playing DVDs is experimental and not guaranteed to work. DVD menus are not supported.
To play DVDs you will need to purchase a MPEG-2 licence (only available for the Raspberry PI 3).
While libdvdread8
comes installed with most version of Raspberry PI OS, to play most DVDs you
will need libdvdcss2
. See Videolan's install instructions
on how to get it.
Please see the manpage for command line options.
Please see dbus.md for details on OMXPlayer's dbus interface.
The above package lists assume you have all the packages that come preinstalled with Raspberry PI OS (lite) still installed.
If you don't you will also need:
libraspberrypi-dev libraspberrypi0 libraspberrypi-bin gcc g++ libstdc++-10-dev pkg-config
binutils libc6-dev libfreetype6-dev perl
libc6 libdbus-1-3 libasound2 libfreetype6 libgcc1 libpcre3
libstdc++6 zlib1g ca-certificates dbus libdvdread8