/mpv/ - the foss media player

Attached: mpv-easy-player-2-en-us.png (854x904, 37K)

Other urls found in this thread:

github.com/422658476/MPV-EASY-Player
mpv.io/manual/master/#files-on-windows
github.com/mpv-player/mpv/wiki/FAQ#X11Nvidia_with_PRIME
twitter.com/NSFWRedditImage

I got a silly idea recently: what if mpv could play text files?

I think it would work like this:
>txt_hook.lua detects when mpv has been invoked on a text file
>runs the text through TTS to create an audio file
>starts playback of that audio file

maybe for bonus points also create a video stream that displays the text, and sync it with the audio file playback. This would be difficult to pull off, unless maybe I paginated it and then ran TTS individually for each page.

but what would I use to generate a video from text? I'm sure I could get some combination of ffmpeg and maybe imagemagick to do it, but could it be done with only ffmpeg?

Also the matter of TTS portability is a big problem with this idea; I don't know of any good open source / cross platform TTS options available. My prototype would probably use `say` on OSX since that has reasonable quality and a reasonable interface. But what would be best used on Linux? Last time I looked into TTS on linux the offerings were abysmal.

Attached: 1502758725340.jpg (618x474, 42K)

Where are the links?
I need a great .conf for anime.

>mpv easy player
What the hell is this? Terrible name btw

github.com/422658476/MPV-EASY-Player

looks like chinese malware. OP is a fag.

>Terrible name btw
Don't be rude. It seems friendly. Those without the best grasp of a language tend to communicate in a manner a bit too literal and limited, so it seems stilted. But they're trying their best. It's pure.

it probably turns your computer into a chinese hackbot rented out to russians so they can hack elections n shit.

profile=gpu-hq

You're welcome.

Which version of RAVU use? Luma only, YUV or RGB? Are the chroma ones worth?

# Video
gpu-api=vulkan
vulkan-async-compute=yes
vd-lavc-dr=yes

profile=gpu-hq
scale=haasnsoft
cscale=haasnsoft
deband-iterations=4
deband-range=6
deband-threshold=156
deband-grain=24
temporal-dither=yes
video-sync=display-resample

glsl-shader="~~/shaders/ravu/compute/ravu-r4-rgb-smoothtest1.hook"

>looks like chinese malware
To be fair it gets that from mpv.

Total noob here used mpc hc till yesterday, downloaded mpv and installed using the bat and works fine.Now i want to ask how do i make config files or if i can get a good basic one mainly for anime watching what i really care is to prioritize jap dub and eng sub.Thanks

mpv.io/manual/master/#files-on-windows

For video quality start with profile=gpu-hq and change things according to what you want and your hardware can support.

For the dub/sub track selection use:
alang=jpn,jp,ja,eng,en
slang=eng,en,jpn,jp,ja

This is what peak performance looks like
gpu-api=d3d11
gpu-context=d3d11
hwdec=d3d11va
profile=gpu-hq
video-sync=display-resample

>gpu-context=d3d11
No need for it.

Thanks man.
That was my default.

What are all these meme settings?

>these deband settings
unironically kys

Not him but what are some good debanding settings user?
I just downloaded and started reading about mpv.

deband-iterations=2
deband-range=12
deband-threshold=48
deband-grain=0

deband-iterations=16
deband-range=48
deband-threshold=128
deband-grain=64

Has that GUI been implemented yet? I haven't updated in a while. I thought they wanted to add a real GUI or something. Are there any new recommended settings?

Anyone else having problem with the sub-export script? Doesn't work for me. I'm on Linux.

Why are you all using gpu-hq? Isn't that pointless for your 10bit animes?

>that GUI
How? Looks way nicer than default.

Is interpolation a meme or do you find it necessary

but isn't vulkan better?

I get slightly better frame timings with d3d11. And Vulkan still cant take scaled screenshots. With more time I think Vulkan could eventually be better.

meme

>no new stable for 5 months
Is it dead?

mpv --show-profile=gpu-hq
Profile gpu-hq:
scale=spline36
cscale=spline36
dscale=mitchell
dither-depth=auto
correct-downscaling=yes
sigmoid-upscaling=yes
deband=yes

github.com/mpv-player/mpv/wiki/FAQ#X11Nvidia_with_PRIME

> If your Xorg-server is older than ABI version 23, or your kernel is older than version 4.5, or your nvidia driver is not up to date, then you will inevitably get tearing due to the lack of PRIME buffer synchronisation.

>If your Xorg-server is older than ABI version 23
By this do they mean X.Org Video Driver or X.Org Server Extension?

[114759.147] (II) Module ABI versions:
[114759.147] X.Org ANSI C Emulation: 0.4
[114759.147] X.Org Video Driver: 23.0
[114759.147] X.Org XInput driver : 24.1
[114759.147] X.Org Server Extension : 10.0

so MPC was just randomly giving me fucktons of unexplainable problems - would get frameskippin when my monitor was in 144hz mode, sometimes when switching between frequencies opening files would just give me a black window, and then out of god damn nowhere files were just taking forever to open.
I got mpv and I'm just using the vanilla config am I good to go? I liked the look of older anime when upscaled with madvr

No stick with MPC

>[114759.147] X.Org Video Driver: 23.0
Pretty sure that's it.

RGB. No.

So this doesn't seem to be anywhere within the mpv manual, or I'm just a blind faggot.

As far as keybinds go, the following three, Alt-0, Alt-1 and Alt-2 rescale the video to half size, normal size and double size respectively. Those are the only options. What I basically want to do is rescale the window up or down in increments, say by 5% or 10% each way. There seem to be no options to do this whatsoever.

I'm running the video borderless, but I want to be able to resize it at will as if I was running WITH the border. What can I do? Is this an impossibility right now?

is there something like this mpv-easy settings menu anywhere else? preferably without moon runes?

Attached: haha memes.png (680x622, 219K)

Alt+1 add window-scale 0.05
Alt+2 add window-scale -0.05

i think i might just print this shit out and stick it on my wall until I memorize them

Attached: mpbindings.png (1250x752, 186K)

Well fucking shit. What do you know. You're a life saver m8. Thanks.

my anime shader:

#Profile anime:
profile=gpu-hq
hwdec=auto-copy
deband=yes
deband-grain=0
deband-iterations=4
scale=ewa_lanczossharp
cscale=ewa_lanczossharp
glsl-shader=~~/shaders/SSimSuperRes.glsl
glsl-shader=~~/shaders/anti-bloating.glsl
glsl-shaders=~~/shaders/adaptive-sharpen.glsl
interpolation=yes
video-sync=display-resample
tscale=oversample
sigmoid-upscaling=yes

For anime: meme
for porn: necessary

I want my settings to update in realtime!

How much grain is too much grain?

Attached: Capture.jpg (164x20, 9K)

Is there a way to make MPV youtube-dl streams buffer an unlimited (or very large) number of seconds/bytes ahead of the current position?
My internet is flaky, and it would be nice if I could buffer large chunks of video without resorting to downloading the whole file.

>the foss media player

the fossile* media player


Use VLC

Wow, talk about a coincidence. I was just about to ask a similar question regarding mpv stream buffering/lag.

You can specify a cache size but I'm unsure how it interacts with ytdl
You'll have to test it for yourself

The most annoying thing is that MPV refuses to cache twitch streams to a file, so you have to reload the stream when you seek into it.

That is the most annoying?

The black 2px uneven margin on the right is more annoying, as well as that strange when moving the window around issue where it loses the border and stretches to display-res but.. halfway between 2 screens..

I think they had issues open for both but either no one could fix it or the entire dev team was too lazy.

what? I've not seen this bug.

Attached: mpv.png (1920x1080, 698K)

The border issue is easily reproduced by just resizing the window a ton of times and moving it around.. you'll get it at some point.

The borderless stretched bug I have not yet figured out how to reproduce, there was an user here complaining about seemingly the same issue, but that was quite a while ago.

Attached: border.jpg (887x279, 93K)

Oh, oh yes. I see it now. It only happens when you drag the window to resize it.
MPV's actually sort of doing the right thing here, by maintaining the video aspect ratio and not cropping it, the window won't fit perfectly around the video. By simply adding a few pixels to the border, you get to maintain the fine window resizing, as well as preserving the perfect aspect ratio without cropping.
There should be an option to turn on fuzzy scaling though, so that you can have MPV crop the video underneath the window when you resize it, or adjust the aspect ratio dynamically to a non-perfect value so that the video will fit in the window.

But the video stays 16:9 no? So why would it have no border on .. say 1080p but on 720p downsized? Rounding issue somewhere?

You can either make the video 16:0.1:9, or crop the bottom row of pixels off to fit under a 15.99:9 window.
It's not a rounding issue, it's the fact that you can't neatly fit a 16:9 video into a 16.01:9 window.

It doesn't seem to matter if I set the cache size or second limit. For whatever reason, it only buffers to 3 seconds at a time while playing, only storing more if you pause. My download speed isn't so shit that it shouldn't be able to handle the stream. Is this just the fault of youtube, or does this fall on mpv?

MPV. It can request as much as it wants from the server, but it's not configured to do so.

What do you mean? Do you mean the program itself isn't configured to, or I haven't configured it properly?

How do VLC and MPC do it then? Cut off pixels? Because the border's are always the same size on them.

I'm not sure. My twitch playback will fill the up to 20s buffer when i give it --cache-secs=20.
It could be a ytdl issue.

They just add big black bars to the window.

That was my sneaking suspicion. I don't if it's just the Youtube API or whatever, but sometimes when using ytdl to download videos, it'll start the dl at near maximum download, but sink lower and lower as it goes on. I'm wondering if Youtube is just throttling on purpose, which would kinda make sense given the sheer size of the site's bandwidth.

My internet is too slow for me to observe that, but it's probably your ISP, not youtube which is throttling. Try running it through a VPN and see if it changes anything.

I highly doubt it's my ISP. Centurylink is pretty much hands off in my experience. And it makes no sense why they would arbitrarily throttle Youtube of all websites, while I routinely get max capacity on any other site (that isn't total ass anyways)

Attached: iseenobars.jpg (1602x372, 112K)

>Centurylink
>is an American telecommunications company
Yeah nah, they're throttling your youtube.
Youtube is the first thing companies throttle because it's the largest bandwidth application on their infrastructure, and 99.99% of users wouldn't notice throttling unless they were direct downloading videos.

That MPC? I'm on Linux, so I'm not sure, but if it allows fine window resizing without tiny black bars, it must either be;
1. adjusting the aspect ratio by a small amount to force the video to fix
or
2. Cropping the video slightly to fit it in either horizontally, or vertically.

1. You can generate video of just subtitles using ffmpeg.

2. mpv can already play just the subtitle against blank screen with audio track.

>TTS
>Text To Speech
>subtitles

oh yes! I forgot completely about subtitles.

So the problem then is how to sync the subtitles with the audio track outputted from TTS.

I think maybe the sane way to do this is to chunk the input file into chunks small enough to display on the screen, run TTS on each chunk, then concatenate each resulting audio file back into one audio stream keeping track of the timestamp at which each begins.

The ultimate objective is to point mpv at an epub and have mpv display the text on the screen, start reading it to me with TTS, and let me skip through the file like I'd normally skip through a media file.

(tackling epub comes after I get this working just for plain text files. epub should be easy if I get that far.)

Attached: 1525362100262.jpg (300x298, 17K)

Wake me when it can play videos without tearing with Aero disabled

>Using stable

You could probably do it with the right config but at the same time you can't expect a smooth experience with areo disabled

>using Windows 7

idiot

No, it's not supported in MPV
But it is supported in VLC and MPC

I'm not sure then, but I stand by the second part of my post.

It is smooth in VLC and MPC with Aero disabled

There isn't a way to play DASH videos with Widevine, right?

>being this retarded

>Wincuck on a soon to be dead OS
>calling a Linux user retarded

my sides

who knows

Great, now just to figure out what they mean by 'up to date' Nvidia.

Haven't noticed tearing with primusrun/optirun on Debian Stretch so far though so I think I'm good.

Is deband=yes worth it? Will I actually see improvements in anime?

deband-grain=0 is best

Yes, especially in dark scenes
If you're watching 10bit anime the improvement will be less notifiable. Banding isn't really an issue now-a-days but most anime encoding groups have no idea what they're doing.

Attached: 1518184605821.png (870x516, 226K)

maybe yes maybe no

Alright, thanks. Is just putting that in the config file enough or should I tweak the deband settings more?

I wouldn't bother, the default deband settings are quite sensible.

Thanks.

how to make mpv play all files contained in folders i drag-and-drop into it? i might just drop any other music player if it could do that simple thing
does it pretend 'there's nothing there to play' on linux too?

you're welcome

what's wrong with $ mpv folder/*?

mpv * is cool enough to bother with adding it to explorer context menu
but it doesn't fucking go into the folders inside the folder and doesn't add files from those folders which is the whole fucking problem

Is there any way to use mpv to combine an srt file and an audio file into an mp4? I can't fine any way to embed srt files using mpv.

Right now I'm using ffmpeg:
#!/bin/bash
PROJECT=$1
PROJECTDIR="/tmp/mpv-txt/$PROJECT"
FRAGMENT=$2
TEXT=$3
mkdir -p $PROJECTDIR

#generate tts audio
say $TEXT -o $PROJECTDIR/tts.aiff

#generate srt file
echo "1" > $PROJECTDIR/tts.srt
echo "00:00:00.000 --> $(ffprobe -v quiet -show_entries format=duration -of default=noprint_wrappers=1:nokey=1 -sexagesimal $PROJECTDIR/tts.aiff | grep -o "[0-9]\+:[0-9]\+:[0-9]\+\.[0-9]\{1,2\}")" >> $PROJECTDIR/tts.srt
echo "$TEXT" >> $PROJECTDIR/tts.srt

#output combined srt and tts audio as an mp4
OUT="$PROJECTDIR/$PROJECT-$FRAGMENT.mp4"
ffmpeg -v quiet -i $PROJECTDIR/tts.aiff -i $PROJECTDIR/tts.srt -c:a mp3 -c:s mov_text $OUT

#add to fragment list and quit
echo $OUT >> $PROJECTDIR/fragments.txt
echo $OUT


(I don't think there is any way I can reasonably support windows. First off this will have an external dependency on either OSX's `say` or linux's `espeak`. Secondly it doesn't look like I can construct SRT files from inside a lua script so I need to use a script to do it. I could rewrite that bash script in something like python but that would add a python dependency windows users would need to resolve. And I don't see any way to use just lua to get generated subtitles into mpv without having an SRT file to load. Somebody please correct me if I'm wrong about that.)

Attached: 1511976239717.jpg (646x400, 20K)

Isn't espeak outdated as fuck?

(Also, the reason I'm combining the SRT and audio into a single mp4 is because I'm going to do this hundreds/thousands of times per file and then concatenate them all together at the very end. This greatly simplifies SRT file generation)

$ find some-folder/ -type f -exec mpv {} +
profit
>explorer
die winfag

Yeah espeak kind of sucks. It works but sounds very mechanical. But it's what exists on linux. If there's a better option I'm not familiar with it.

`say` on OSX has pretty high quality though.

In the future maybe I'll be able to incorporate support for some 'cloud' TTS solutions, provided they allow me to programmatically send them text and download audio files. But that's a low priority.

Actually you know what, I think I'm going to pull in python as a dependency anyway because splitting the input text into sentences would be a royal pain in the ass in Lua or bash.

(Python specifically not because I like it but because most people probably already have it.)