Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: 加入音频参数 pulse-allow-suspended=yes #576

Merged
merged 1 commit into from
Feb 11, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/backends/mpv/mpv_proxy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -658,6 +658,9 @@ mpv_handle *MpvProxy::mpv_init()
++p;
}

if(utils::check_wayland_env()) {
my_set_property(m_handle, "pulse-allow-suspended", "yes");
}
//设置hwdec和vo配置
CompositingManager::get().getMpvConfig(m_pConfig);
QMap<QString, QString>::iterator iter = m_pConfig->begin();
Expand Down Expand Up @@ -1441,6 +1444,9 @@ void MpvProxy::refreshDecode()
auto codec = currentInfo.mi.videoCodec();
my_set_property(m_handle, "hwdec-codecs", codec.toLower());

if(utils::check_wayland_env()) {
my_set_property(m_handle, "pulse-allow-suspended", "yes");
}
//play.conf
CompositingManager::get().getMpvConfig(m_pConfig);
QMap<QString, QString>::iterator iter = m_pConfig->begin();
Expand Down