Questions tagged [mpv]

The [mpv] tag is for questions about programmatically interacting with the mpv media player or its C library.

mpv is a free, open source, and cross-platform media player. It is a fork of mplayer2 and MPlayer. It shares some features with the former projects while introducing many more.

mpv can be controlled via a command line interface and/or via a JSON-based IPC protocol. It also has a C API which makes it usable as a library.

92 questions
0
votes
0 answers

Is there a way to stream from mpv player's playback directly to web?

I've got a python project that, in a loop, writes strings to be interpreted by mpv and drop them in a terminal shell. MPV Player is called and reproduces the sequence of cuts with variables randomly chosen on python. The thing is: I need to stream…
Fitipe
  • 1
  • 1
  • 2
0
votes
1 answer

MPV (FFmpeg) stack 2 videos and then crop output without re-encoding?

I have two 16:9 ratio videos, I want to horizontally stack them, but then crop the resulting video output by about 900px from the right border whilst playing it within mpv and without re-encoding. Libavfilter does have a crop functionality, but in…
crackerbear
  • 148
  • 1
  • 1
  • 7
0
votes
1 answer

play a video file after gnome login

I want to see a video clip when I start using computer (and after login into Gnome) automatically. how can I do that in Linux (Manjaro)? I tried to make this by Systemd service but I was not successful. this is my Systemd service…
0
votes
0 answers

ffmpeg problems with streaming mp4 over udp in local network

I'm streaming mp4 video files (some of them are avi converted to mp4 with ffmpeg earlier) over udp://232.255.23.23:1234 from linux (embedded) with ffmpeg v3.4.2 to multiple linux (antix) machines that play the stream with MPV, all of this happens in…
AJ Cole
  • 169
  • 2
  • 13
0
votes
1 answer

GTKmm Opengl context not initialized

I am trying to create a Video Player inside GTKmm, for this I am using mpv. The documentation says, that I can embed the video player using an OpenGL view. However, I am having difficulties implementing the player inside a GTKmm app. I have a…
J.Paravicini
  • 882
  • 12
  • 39
0
votes
1 answer

libmpv intptr_t of an NSView

I am trying to use libmpv in a swift project. I have everything linked up and am trying to follow the basic example. The problem is, that to show a video, I have to pass an integer pointer (intptr_t) to the wid command. In Objective-C this would be…
J.Paravicini
  • 882
  • 12
  • 39
0
votes
1 answer

Linux play video command freezes after a few seconds

I run a shell command in a Java jar application, I use Runtime and process exec, but after some minutes the video and the java process freezes. When I run the command alone in shell console it works fine. In console it works: ffplay -loglevel debug…
0
votes
1 answer

mpv API : how to go to nth element in playlist?

I control mpv via socat on the terminal (bash script) like this : echo '{ "command": ["playlist-next" ] }' | socat - /tmp/mpvsocket and it works but I don't know the syntax to use for playlist-pos echo '{ "command": ["playlist-pos", "100" ] }' |…
Neo Mosaid
  • 367
  • 3
  • 17
0
votes
1 answer

i3: Starting mpv from ranger on different workspace

I would like to configure my i3wm and ranger file manager in such a way that when I choose a movie in ranger, it opens video in mpv on workspace 10 in fullscreen. The problem is that everything works fine without --fs (fullscreen option on mpv), but…
Grandariel
  • 21
  • 1
  • 2
0
votes
1 answer

Wrong path returned from MPV player using mp.get_property("path") spaces on Windows

I have my video in the following locaton with spaces on Windows. "c:\GoogleDrive\CMD Scripts_video\test.mp4" MPV function in Lua script returns cut path with special characters ~1 video_path =…
user2432166
  • 151
  • 1
  • 8
0
votes
1 answer

Docker container running python-mpv: Cannot open shared object file libmmal_core.so

On my Raspberry Pi 3 Model B, I'd like to run python-mpv inside a Docker container. My Docker version is 18.02.0-ce, build fc4de44. Both the Raspberry and the Docker container run "Raspbian Stretch". This is the Dockerfile: FROM…
Wolkenarchitekt
  • 20,170
  • 29
  • 111
  • 174
0
votes
1 answer

Add running text to video stream with vdpau

I have a task to add running text to video stream (or file) on receive. Video need to be run on cubieboard with Armbian. I tested with mpv, with flag --hwdec=vdpau, and the video runs smoother that without it. To add running text I tried to use…
Arsel Muginov
  • 83
  • 3
  • 6
0
votes
0 answers

Initiate mpv video play from php exec

Trying to initiate a mpv video play on a linux server with php exec command from a remote machine. Only able to get audio working. Getting error for video. code on php file: $cmd = "DISPLAY=:1 mpv video/test.mp4 --ao=alsa:device=[hw:1]"; $out =…
Sevon
  • 1
  • 2
0
votes
1 answer

Autoload - after opening file set to loop current file

I'm using this script https://github.com/mpv-player/mpv/blob/master/TOOLS/lua/autoload.lua Sometimes when open such file, I want to loop current file. Normally for that I use: #L cycle-values loop-file "inf" "no" # toggle infinite looping but…
rofrol
  • 14,438
  • 7
  • 79
  • 77
-1
votes
2 answers

How to launch python script from mpv/lua

I have written an mpv script in python using https://github.com/iwalton3/python-mpv-jsonipc I'm now trying to launch the script when mpv opens but cant seem to get it to launch I tried running from mpv with mp.command("run", "python3",…
k-on fan
  • 101
  • 4