Computer Hope

Install Packages

  • sudo eopkg it -c system.devel
  • sudo eopkg it gperf bison flex autoconf automake make texinfo help2man ncurses-devel yasm fribidi fribidi-devel fontconfig fontconfig-devel mesalib mesalib-devel gnutls samba samba-devel pulseaudio pulseaudio-devel libbluray libbluray-devel libdvdread-devel libdvdread luajit luajit-devel libjpeg-turbo libjpeg-turbo-devel v4l-utils v4l-utils-devel libcdio libcdio-devel libcdio-paranoia libcdio-paranoia-devel gettext gettext-devel m4 libtool libtool-devel libvdpau-devel libvdpau libguess libguess-devel libva libva-devel libdvdnav libdvdnav-devel

Build mpv, libass and ffmpeg

  • git clone https://github.com/mpv-player/mpv-build.git
  • cd mpv-build
  • ./use-mpv-release
  • ./use-ffmpeg-release
  • ./update
  • ./rebuild -j8
  • sudo ./install

test

  • mpv file

Easier way to install or build mpv with mmal hardware decoding and ffmpeg/libass

Install

  • mkdir rpimpv && cd rpimpv
  • wget https://awesome.nwgat.ninja/deb/mpv/mpv_0.20.0_armhf.deb https://awesome.nwgat.ninja/deb/mpv/libass_0.13.3-1_armhf.deb https://awesome.nwgat.ninja/deb/mpv/ffmpeg_3.1.3-1_armhf.deb
  • sudo dpkg -i *.deb
  • sudo apt-get -f install
  • sudo apt-get install libluajit
  • wget https://awesome.nwgat.ninja/deb/mpv/mpv.conf -O $HOME/.config/mpv/mpv.conf
  • sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl
  • sudo chmod a+rx /usr/local/bin/youtube-dl

Play a file

  • mpv http://ow.ly/10tB0C (Big Buck Bunny 1080p30)
  • mpv https://www.youtube.com/watch?v=aqz-KE-bpKQ (Big Buck Bunny 1080p30)

mmal error

  • sudo su
  • echo "gpu_mem=159" >> /boot/config.txt
  • echo "gpu_mem=256" >> /boot/config.txt (rpi2/rpi3)
  • sudo reboot

you can tweak the settings in mpv config file, if you need to move the window or change resolution of youtube, it currently defaults to 1080p30

  • nano $HOME/.config/mpv/mpv.conf

note: it will default to borderless non-movable window, this is a limitation of raspberry pi

Build it yourself

  • sudo apt-get install -y gperf bison flex autoconf automake make texinfo help2man libtool libtool-bin ncurses-dev git yasm mercurial cmake cmake-curses-gui libfribidi-dev checkinstall libfontconfig1-dev libgl1-mesa-dev libgles2-mesa-dev gnutls-dev libsmbclient-dev libpulse-dev libbluray-dev libdvdread-dev libluajit-5.1-dev libjpeg-dev libv4l-dev libcdio-cdda-dev libcdio-paranoia-dev
  • git clone https://github.com/mpv-player/mpv-build.git
  • cd mpv-build
  • echo --enable-mmal >> ffmpeg_options
  • ./use-mpv-release
  • ./use-ffmpeg-release
  • ./update
  • ./rebuild -j4
  • sudo ./install

pretty simple check this out

  • choco install youtube-dl ffmpeg
  • youtube-dl -f bestaudio https://www.youtube.com/watch?list=PLyIFQr1wryPKU_QHC9NxCf7LuFAQtTLf0&v=FlgZFZRTUTY

if you get webm files, you can easily remux them to ogg vorbis/opus using

Windows
for %%a in ("*.webm") do ffmpeg -i "%%a" -acodec copy "newfiles\%%~na.mka"

FYI put in a convert.bat file, ffmpeg is also needed in folder or use chocolately

Linux
Todo

Crop Real 4K to UltraHD 4096>3840

ffmpeg -i A001_C014_01217G.4k.y4m -vf "crop=3840:2160:128:0" outputgirl.2160p.y4m

Resize to 1080p

ffmpeg -i outputgirl.2160p.y4m -vf scale=1920:-1 outputgirl.1080p.y4m

Resize to 720p

ffmpeg -i outputgirl.2160p.y4m -vf scale=1280:-1 outputgirl.720p.y4m

Convert source to YUU4MPEG2

ffmpeg -pix_fmt yuv420p -i any-source-video.webm output.y4m

Convert a sequence of images to YUU4MPEG

ffmpeg -f image2 -i "A004_C001_0122K7.00%05d.png" -pix_fmt yuv420p ouput.y4m

extract a single frame

ffmpeg -i input.avi -f image2 -ss 14.342 -vframes 1 frame.png

extract a single frame (altenative method)

ffmpeg -i input.y4m -f image2 -vf select="gte(n\, 1)" -vframes 1 frame.png

extract 1 frame after frame 100

ffmpeg -i input.y4m -f image2 -vf select="gte(n\, 100)" -vframes 1 frame.png

(almost) up to date daala builds for windows
64-bit for now, if anyone need 32-bit just contact me

Daala Websites
Website - GitHub - Demos - Doom9 Discussion

Compiler Details(for nwgat builds)

  • Cygwin64 1.7.32(0.274/5/3) or later
  • libogg 1.3.1-1 or later

Usage

Source: ffmpeg -pix_fmt yuv420p -i any-source-video.webm source.y4m
Source: (720p resize) ffmpeg -pix_fmt yuv420p scale=1280:-1 -i any-source-video.webm source.y4m
Encoding: encoder_example -v 20 source.y4m -o daala-video.ogv
Decoding: dump_video daala-video.ogv -o daala-video.y4m
Playback: Play daala-video.y4m in MPC-BE

Use between 0-55 (0 being lossless), daala supports upto 511 but thats pointless in my testing

Issues

Only use same build for the encoded file.
daala is not finished. so file decoding will break between builds

Download

Receive $10 in credit at DigitalOcean for your VPS Hosting
€1.24 VPS from Time4VPs
Proudly published with Ghost | Theme based on Draugur | Header Image by GUWEIZ@DeviantArt
Creative Commons Licence