4 ms·
If you're on Linux, don't forget to enable hardware acceleration by adding hwdec=auto to mpv.conf. Works with AMD/Intel/NVIDIA. https://interfacinglinux.com/20
by Venn1 2y ago
If you're on Linux, don't forget to enable hardware acceleration by adding hwdec=auto to mpv.conf. Works with AMD/Intel/NVIDIA.
https://interfacinglinux.com/2024/01/10/hardware-acceleration-with-mpv/ https://interfacinglinux.com/2024/01/10/hardware-acceleratio...
- synergy20 2y agogreat to know this. thanks!
- NavinF 2y agoWhy would that be disabled by default?
- diggan 2y agoDoesn't work on all systems, I presume. Better to default to something that definitely works everywhere. https://github.com/mpv-player/mpv/blob/a3baf94ab9f3b43a8027d74c43991a3c2da732e0/etc/mpv.conf#L69-L73 https://github.com/mpv-player/mpv/blob/a3baf94ab9f3b43a8027d... Would be appropriate to have true/false/auto instead of auto==true though, so auto wouldn't use it unless it confirmed to be working.
- NavinF 2y agoStill, isn't this bizarre? Over the last couple of decades using Windows and macOS across many machines, I've encountered one time I had to mess with settings like this. That's the time I temporarily disabled hw accel in chrome so I could screenshare and watch a show with someone. Meanwhile on Linux you gotta configure every app one at a time because sane defaults and auto configuration weren't invented here.
- crossroadsguy 2y agoBecause if you don't have to enable a flag or two in a text config file what's the fun of using Linux after all :)
- brettermeier 2y agoHahaha yeah, that's why I don't like it.
- varenc 2y agoIn addition to what others have said, hardware decoding comes with other drawbacks. There’s occasionally decoding inaccuracies and there’s no support for most video filters (unless you’re using `auto-copy`)
- tvshtr 2y agoTry watching UHD HDR on intel iGPU without accel, or AV1. MPV also supports vulkan decoders.
- radicality 2y agoDo you know if/why on apple silicon Macs there’s a difference between videotoolbox and videotoolbox-copy ? I thought the SoC memory is shared and that there wouldn’t be a need for copying data from VRAM to RAM.
- krzys 2y agoIf you autodetect hw accel, even the slowest underpowered gpu might get returned, which could result in worstened user experience compared to just using cpu.
- mzajc 2y agoIt breaks on suspend-to-memory for my system with a nVIDIA GPU. I assume that's a driver problem, though.
- shmerl 2y agoI do it like this: vo=gpu-next gpu-api=vulkan hwdec=vulkan gpu-context=waylandvk You can replace hwdec=vulkan with hwdec=vaapi if Vulkan video doesn't work.
- vladvasiliu 2y agoIs there a reason why one would prefer vulkan over vaapi, or the other way round?
- shmerl 2y agoVulkan in theory should be more flexible, but in practice VAAPI still has some advantages when it comes to power efficiency due to Vulkan path lacking some needed features (I think something to do with color space conversions which in Vulkan now have to happen using regular GPU compute units which is inefficient). In the longer term, Vulkan should be preferable in all scenarios. See also some details here: https://github.com/mpv-player/mpv/discussions/13909 https://github.com/mpv-player/mpv/discussions/13909
- troad 2y agoHuh. Apparently I've been watching videos on mpv for years without HW acceleration. Good thing I read this; thanks!
- nijave 2y agoNot sure why but I've had lots of issues with worse performance (lagging/stuttering) on Fedora (I think kernel 6.10) with a Vega 64. Every year or so I'll give it a try and it just won't work well and I give up again.
- steelframe 2y agoYeah, I just pacman-installed mpv and tried running it on a 4k video. My CPU fan immediately kicked on, and top showed multiple cores getting involved. Kept scrolling this HN post to learn about hwdec=auto. Coming from mplayer and vlc my immediate question is, "What tradeoffs are the maintainers trying to make by not making this the default?"