Anomunus
Posts: 3
Joined: Wed Oct 02, 2019 8:41 am

Re: GIANT UPDATE: Build FFmpeg and mpv – Automatically in 54 Minutes!

Wed Oct 02, 2019 5:22 pm

Hi, I'm having problems completing the mpv installation in your script. Everything else seemed to have installed fine, and I don't have a problem with checkinstall not being installed. However when I get to that line:

Code: Select all

sudo checkinstall -y --pkgname mpv --pkgversion 0.29.0 ./waf install
After checkinstall lists its summary, it goes on to give me this error:
The project was not configured: run "waf configure" first!

I have no idea what I'm doing wrong, and the .waf/configure line that is before the checkinstall line seems to have run fine. My question is whether or not there's anything I can do without having to nuke the entire Raspbian installation. (If it really comes down to that then I guess I will accept the reality of this situation.)

grrgle
Posts: 4
Joined: Mon Jul 08, 2019 10:57 pm

Re: GIANT UPDATE: Build FFmpeg and mpv – Automatically in 54 Minutes!

Sun Oct 06, 2019 11:19 pm

So I overcame my problems with my earlier install -- not sure what that was about but a clean install got it sorted -- BUT:

I have a file that will play on my CentOS laptop but not on my Pi; the Pi plays at least one other file perfectly, but in this case it only plays the audio:

Code: Select all

[email protected]:~ $ mpv -fs /media/pi/LIVE/\[Bunny_Hat\]Macross_21_\(3CE5C7D8\).mkv
Playing: /media/pi/LIVE/[Bunny_Hat]Macross_21_(3CE5C7D8).mkv
 (+) Video --vid=1 (*) (h264 1440x1080 23.976fps)
 (+) Audio --aid=1 --alang=jpn (*) (aac 2ch 48000Hz)
 (+) Subs  --sid=1 --slang=eng (*) (ass)
AO: [alsa] 48000Hz stereo 2ch float
Using hardware decoding (mmal).
VO: [rpi] 1440x1080 mmal
[vo/rpi] Could not create EGL surface!
[vo/rpi] EGL/GLES initialization for OSD renderer failed.
Could not initialize video chain.
Video: no video
A: 00:00:03 / 00:25:17 (0%)


Exiting... (Quit)
[email protected]:~ $ 
I am pretty sure I have followed the instructions correctly. I tried nuking it and doing it over, with the same result. Anybody have any idea what I might have gotten wrong? Or, if I followed the instructions correctly, why would the system be able to play one file and not another?

grrgle
Posts: 4
Joined: Mon Jul 08, 2019 10:57 pm

Re: GIANT UPDATE: Build FFmpeg and mpv – Automatically in 54 Minutes!

Mon Oct 07, 2019 1:29 pm

(Addendum: the vidware system plays at least two files: the demo included in the install, and also a different file that I had on hand. The file from which this system plays only the audio is known good, as another (CentOS) system using mpv plays both audio and video from this file, using the same USB thumb drive. I also note that the CentOS system presents a GUI from the Applications -> Sound and Video menu, and this feature is absent in my installation from the vidware system. Finally, mpv on the Pi is intermittently unresponsive to keyboard input, e.g. during play of the demo video the q command did not quit the video)

tommyfeelgod
Posts: 1
Joined: Fri Oct 18, 2019 3:27 pm

Re: GIANT UPDATE: Build FFmpeg and mpv – Automatically in 54 Minutes!

Fri Oct 18, 2019 3:39 pm

a easy way ro install ffmpeg under ubuntu 18.04 and buster with all codecs on raspi



mkdir -p ~/ffmpeg_sources ~/bin



sudo apt build-deb ffmpeg




sudo apt-get -y install \
autoconf \
automake \
build-essential \
cmake \
git-core \
libass-dev \
libfreetype6-dev \
libsdl2-dev \
libtool \
libva-dev \
libvdpau-dev \
libvorbis-dev \
libxcb1-dev \
libxcb-shm0-dev \
libxcb-xfixes0-dev libvpx-dev libfdk-aac-dev libmp3lame-dev \
pkg-config \
texinfo libpulse-dev libssh-dev\
wget \
zlib1g-dev nasm yasm libx264-dev libx265-dev libnuma-dev





this bring ffmpeg in your home directory folder ffmpeg_build and bin !!!! dont remove it !!!!!!




cd ~/ffmpeg_sources && wget -O ffmpeg-snapshot.tar.bz2 https://ffmpeg.org/releases/ffmpeg-snapshot.tar.bz2 && tar xjvf ffmpeg-snapshot.tar.bz2 && cd ffmpeg && PATH="$HOME/bin:$PATH" PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" ./configure --prefix="$HOME/ffmpeg_build" --pkg-config-flags="--static" --extra-cflags="-I$HOME/ffmpeg_build/include" --extra-ldflags="-L$HOME/ffmpeg_build/lib" --extra-libs="-lpthread -lm" --bindir="$HOME/bin" --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-nonfree --enable-libsoxr --enable-libvpx --enable-libpulse --enable-libssh --disable-doc --disable-htmlpages --disable-manpages --disable-podpages --disable-txtpages --enable-opengl --enable-libzvbi --enable-omx --enable-omx-rpi --enable-mmal --enable-runtime-cpudetect --enable-x86asm && PATH="$HOME/bin:$PATH" make -j4 && make install && hash -r



copy ffmpeg to user bin

cd bin


cp ff* /usr/local/bin/


be shure ffmpeg is not installd



sudo apt purge ffmpeg

gravityaddiction
Posts: 1
Joined: Sat Nov 02, 2019 6:03 am

Re: GIANT UPDATE: Build FFmpeg and mpv – Automatically in 54 Minutes!

Sat Nov 02, 2019 6:45 am

@RPi_Mike,

Thanks for your work on this. At the point I wrote this comment, your script still works perfect on stretch. It needs a patch (@jonny789) for buster. I also found the wget doesn't grab the glesv2.pc and egl.pc files. The repo has them named brcmglesv2.pc and brcmegl.pc. Hope this post helps someone who was once in my position!

It can't be stressed enough that you should start with a fresh full install of stretch (or buster) as RPI_Mikes original instructions state very clearly.

1. Adding brcm to the .pc filenames when wget downloaded and copied firmware files to the pkgconfig

Code: Select all

wget -q --show-progress --no-use-server-timestamps https://github.com/raspberrypi/firmware/raw/master/hardfp/opt/vc/lib/pkgconfig/brcmglesv2.pc

wget -q --show-progress --no-use-server-timestamps https://github.com/raspberrypi/firmware/raw/master/hardfp/opt/vc/lib/pkgconfig/brcmegl.pc

sudo cp brcmglesv2.pc /opt/vc/lib/pkgconfig

sudo cp brcmegl.pc /opt/vc/lib/pkgconfig


2. Added this patch (Thanks @jonny789) to be run on about line 180 in your script. i pasted this in your script after it moves the build folders and before it builds the apt dependencies.

Code: Select all

cd /home/pi/Vidware_Build/mpv

wget  https://github.com/mpv-player/mpv/files/3458510/0001-6838-Fix-rpi-compile-issues.patch.txt

patch  -p1  <  0001-6838-Fix-rpi-compile-issues.patch.txt



3. when running videos, i found a few extra options specific for the rpi

Code: Select all

mpv --video-sync=display-resample --no-osc --no-osd-bar --osd-on-seek=no --rpi-display=0 --rpi-layer=2 --rpi-background=yes --rpi-osd=no Neutron_Stars_Colliding_1080p.mp4

Return to “Graphics, sound and multimedia”