Skip to content

Commit

Permalink
player: can't render video properly with libmpv(0.38) on Linux (#825)
Browse files Browse the repository at this point in the history
  • Loading branch information
cosven committed Apr 21, 2024
1 parent 3666648 commit e83e4c6
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions feeluown/player/mpvplayer.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,12 @@ def __init__(self, _=None, audio_device=b'auto', winid=None,
mpvkwargs['wid'] = winid
self._version = _mpv_client_api_version()

# old version libmpv can use opengl-cb
if self._version < (1, 107):
mpvkwargs['vo'] = 'opengl-cb'
self.use_opengl_cb = True
else:
self.use_opengl_cb = False
# From libmpv 0.38, libmpv is not the default vo.
# Note if vo is not set to libmpv, the video is rendered in mpv's
# native window instead of feeluown's mpvwidget (tested on KDE+wayland).
# On macOS, this option is optional. I believe the option is also required
# on Windows.
mpvkwargs['vo'] = 'libmpv'

# set log_handler if you want to debug
# mpvkwargs['log_handler'] = self.__log_handler
Expand Down

0 comments on commit e83e4c6

Please sign in to comment.