1 (edited by zapper 2021-10-19 00:59:05)

Topic: Easier MPV + SNDIO way to play .mp4 without desync found!

In order to be able to play .mp4 audio/video files...

MAJOR EDIT! THERE IS IN FACT ONE OTHER WAY besides the smplayer method!

mpv --audio-device=sndio + whatever mp4 file you wish to play!

Hope this helps some people! smile

The below still works, but its really the inferior way I think... wink


You cannot use pure mpv if you are using sndio, or the video is out of order and the sound moves faster than the video...

smplayer is required until someone figures out how to make this an easy default within regular mpv or at least feasible.

Anywho, for sndio to work with smplayer on mp4 videos:

Go to Options/preferences/General and enable the following:

Audio/Video Auto synchonization and make the audio output sndio.

I am not sure if this is an issue with other video/audio files, but if you don't do these two things, the video and audio aren't properly in sync.

Just thought I should mention this.

g4jc told me about this once, if I recall correctly.

Long story short, I feel like this should be mentioned in both the wiki and the forums as a sticky.

I was told by one of the devs moments ago that I should post here even if the other 3 don't respond back to me.

Hope this helps someone! smile

Peace!

Small side-note, don't change the A/V auto synchronization factor from 100 to any other number.  I think that might cause problems.  wink

HyperbolaBSD: The Future of Secure Libre Lightweight Operating Systems!

2

Re: Easier MPV + SNDIO way to play .mp4 without desync found!

For future versions we must go thinking about how to keep sndio in mpv, because mpv developers already removed sndio support in upstream -> https://github.com/mpv-player/mpv/commit/71d218eae4b4

~ Jesús E.

3

Re: Easier MPV + SNDIO way to play .mp4 without desync found!

Thanks for the hint! Well, there are these days ... and those decisions ... better to keep that away for the moment, just frustrating. Perhaps keeping the concurrent version as long as possible or doing that with patches coming from OpenBSD - so far people have mpv included. Either way it won't be easier besides I find the comment a little bit strange: "(Note: only supports mono, stereo, 4.0, 5.1 and 7.1 channel layouts.)"

Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

4

Re: Easier MPV + SNDIO way to play .mp4 without desync found!

zapper wrote:

In order to be able to play .mp4 audio/video files...

MAJOR EDIT! THERE IS IN FACT ONE OTHER WAY besides the smplayer method!

mpv --audio-device=sndio + whatever mp4 file you wish to play!

Hope this helps some people! smile

Ahh, thank you @zapper, this is perfect! I was so confused, I was getting sound from iceweasel-uxp, but not from mpv.

5

Re: Easier MPV + SNDIO way to play .mp4 without desync found!

Or simply add the "ao=sndio" in your mpv.conf.

6 (edited by dikasp2 2022-08-20 13:03:47)

Re: Easier MPV + SNDIO way to play .mp4 without desync found!

not sure but i can play mpv fine here, no oodities,  weirdness or anything.
in fact my opionion sndio produce better sound details than pulsoaudiu or pipewure.

im using alsa-sndio btw, it is different from standalone sndio only ?
tested mpv --audio-device=sndio & --ao=sndio has no different from default

this is my usual setup:

doas gpasswd -a yourusername audio
doas pacman -S alsa-sndio alsa-utils sndio
doas rc-update add alsasound default
doas rc-update add sndiod default
alsamixer
alsactl store

7

Re: Easier MPV + SNDIO way to play .mp4 without desync found!

dikasp2 wrote:

not sure but i can play mpv fine here, no oodities,  weirdness or anything.
in fact my opionion sndio produce better sound details than pulsoaudiu or pipewure.

im using alsa-sndio btw, it is different from standalone sndio only ?
tested mpv --audio-device=sndio & --ao=sndio has no different from default

this is my usual setup:

doas gpasswd -a yourusername audio
doas pacman -S alsa-sndio alsa-utils sndio
doas rc-update add alsasound default
doas rc-update add sndiod default
alsamixer
alsactl store

Hmmm, maybe it was fixed since then.

sounds like good news to me

smile

Not sure, yet, but its possible.

HyperbolaBSD: The Future of Secure Libre Lightweight Operating Systems!