flathub / io.mpv.Mpv

https://flathub.org/apps/details/io.mpv.Mpv
9 stars 20 forks source link

Videos can Freeze Ubuntu 22.04.3 LTS, Requiring a Hard Reset #373

Open InklingGirl opened 8 months ago

InklingGirl commented 8 months ago

As the title says, videos that are played – only really recently – via io.mpv.Mpv freeze all video & input on my installation of Ubuntu 22.04.3 LTS (Jammy Jellyfish), requiring a hard reset to resume the system. --hwdec=auto --hwdec-codecs=all is a workaround I found, but I think an actual solution should be sought. If there's anything you think I could provide, please tell me what & how to get it. Thanks.

System & program info:

fastrizwaan commented 8 months ago

the freezing could be due to the Graphics drivers kisak/kisak-mesa please try ubuntu distro's mesa or stable version https://launchpad.net/~kisak/+archive/ubuntu/turtle

Sunspark-007 commented 8 months ago

I get the freeze too on a completely different system. The command line switches also work.

I think these switches should be a default setting because as per my report in https://github.com/flathub/io.mpv.Mpv/issues/377, pressing ctrl-h will freeze playback if started in software decoding mode, but if started with these switches it is possible to switch out of hardware to software using ctrl-h.

Sunspark-007 commented 8 months ago

@InklingGirl Try downgrading from 0.37 to the last version of 0.36, fixed issues for me.

sudo flatpak update --commit=ab5661d5510eea41ba27bf1211d3407009628211547efaa1e64f10fc57780657 io.mpv.Mpv

fastrizwaan commented 8 months ago

Or 0.37 with freedesktop 22.08

sudo flatpak update --commit=5b9dfcbbf3cadf320ea4baf4440f4e40803d290eaa6d6e2ff6d0039a5e5ea315 io.mpv.Mpv
yuntaz0 commented 7 months ago

Thanks! It appears that MPV does not utilize hardware acceleration properly, leading to increased GPU usage and freezing. The first suggestion to use a fallback (falling back to ab5661) works, but the second suggestion to fallback to 5b9dfc does not work for me.

Sunspark-007 commented 7 months ago

I think you should try removing the kisak-mesa ppa. Your 22.04.3 LTS already comes with Mesa 23.

The description for kisak-mesa says it could be unstable, and to try instead https://launchpad.net/~kisak/+archive/ubuntu/turtle/

fastrizwaan commented 7 months ago

ab5661 works with 3rd party gpu drivers. closing as 3rd party mesa drivers in use.

yuntaz0 commented 7 months ago

I'm not using third party mesa drivers, but this issue still exists in the newest commit.

fastrizwaan commented 7 months ago

as can be seen from website: https://launchpad.net/~kisak/+archive/ubuntu/turtle/

The goal of this PPA is to provide newer mesa with the maximum amount of time for regressions to be resolved in upstream mesa. However, this comes at the cost of absolutely no support. Please do not report any issues with this PPA.

If you encounter bugs, ppa-purge this PPA and reproduce the issue with a newer mesa PPA before reporting it upstream.

yuntaz0 commented 7 months ago

Thank you. Should I open another issue because I'm not using Ubuntu or any third party drivers?

System & program info: Hardware model: Framework Laptop 13 AMD Ryzen 7040Series CPU: AMD Ryzen 7 7840U iGPU: Radeon 780M Graphics × 16 OS: Fedora Linux 39.20240204.0 (Silverblue) io.mpv.Mpv version: 0.37.0 io.mpv.Mpv runtime: org.freedesktop.Platform/x86_64/23.08 Flatpak features: all devices & full filesystem access enabled via com.github.tchx84.Flatseal Graphics drivers: mesa-va-drivers-23.3.4-1.fc39.x86_64 DE: GNOME 45.3 GUI theme: Adwaita Window server: Wayland Video compositor: Mutter 45.3

Sunspark-007 commented 7 months ago

Sorry yuntaz0, I assumed that you were the OP. Sorry fastrizwaan, for giving you the mistaken cue.

fastrizwaan commented 7 months ago

@yuntaz0 I am using fedora 39 workstation with intel

$ rpm -qa|grep mesa
mesa-filesystem-23.3.3-1.fc39.x86_64
mesa-libxatracker-23.3.3-1.fc39.x86_64
mesa-va-drivers-23.3.3-1.fc39.x86_64
mesa-vulkan-drivers-23.3.3-1.fc39.x86_64
mesa-libglapi-23.3.3-1.fc39.x86_64
mesa-dri-drivers-23.3.3-1.fc39.x86_64
mesa-libgbm-23.3.3-1.fc39.x86_64
mesa-libEGL-23.3.3-1.fc39.x86_64
mesa-libGL-23.3.3-1.fc39.x86_64

I think it could be due to drivers issue with amd gpu drivers at fedora & ubuntu end, I'd suggest using mpv older version or with differnet gpu driver vo=wlshm which shoudl works for you in wayland.

rizvan@fedora:~/Downloads$ flatpak run io.mpv.Mpv --vo=help
Available video outputs:
  libmpv           render API for libmpv
  gpu              Shader-based GPU Renderer
  gpu-next         Video output based on libplacebo
  vdpau            VDPAU with X11
  wlshm            Wayland SHM video output (software scaling)
  xv               X11/Xv
  sdl              SDL 2.0 Renderer
  dmabuf-wayland   Wayland dmabuf video output
  vaapi            VA API with X11
  x11              X11 (software scaling)
  null             Null video output
  image            Write video frames to image files
  tct              true-color terminals
  drm              Direct Rendering Manager (software scaling)
  sixel            terminal graphics using sixels
  kitty            Kitty terminal graphics protocol

example:

flatpak run io.mpv.Mpv --vo=wlshm ./video.mp4

if you want to make it permanent:

echo "vo=wlshm" >> ~/.var/app/io.mpv.Mpv/config/mpv/mpv.conf

or you may try other drveirs like sdl or etc.

InklingGirl commented 7 months ago

as can be seen from website: https://launchpad.net/~kisak/+archive/ubuntu/turtle/

The goal of this PPA is to provide newer mesa with the maximum amount of time for regressions to be resolved in upstream mesa. However, this comes at the cost of absolutely no support. Please do not report any issues with this PPA.

If you encounter bugs, ppa-purge this PPA and reproduce the issue with a newer mesa PPA before reporting it upstream.

as can be seen from comment:

I'm not using third party mesa drivers, but this issue still exists in the newest commit.

The user is not using a third-party mesa PPA.