1 Star 0 Fork 10

chenguanglee/kylin-video

forked from src-openEuler/kylin-video 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0002-fix-build-error-about-mpv-0.35.1.patch 3.05 KB
一键复制 编辑 原始数据 按行查看 历史
peijiankang 提交于 2024-04-16 11:14 . update version to 3.1.4.2
From 2f0783d673591d0f9496898b3d0111ac2b161fbc Mon Sep 17 00:00:00 2001
From: peijiankang <peijiankang@kylinos.cn>
Date: Tue, 16 Apr 2024 13:02:23 +0800
Subject: [PATCH] fix build error about mpv 0.35.1
---
src/core/mpvcore.cpp | 52 ++++++++++++++++++++++----------------------
1 file changed, 26 insertions(+), 26 deletions(-)
diff --git a/src/core/mpvcore.cpp b/src/core/mpvcore.cpp
index 4b5e94e..64fc8f2 100644
--- a/src/core/mpvcore.cpp
+++ b/src/core/mpvcore.cpp
@@ -1703,32 +1703,32 @@ bool MpvCore::event(QEvent *event)
// mpv_event_log_message *message = static_cast<mpv_event_log_message*>(event->data);
break;
}
- case MPV_EVENT_TRACK_SWITCHED:
- KyInfo() << "[mpv event] MPV_EVENT_TRACK_SWITCHED";
- // 轨道id改变
- mpv_get_property(m_mpvHandle, "sid", MPV_FORMAT_INT64, &sid);
- if (sid > m_stracks)
- sid = 0;
-
- g_core_signal->notifySubId(sid);
- if(sid != m_sid && sid >= 0)
- {
- m_sid = sid;
- if (sid == 0) {
- ShowText(tr("subtitle : ").append("no"));
- }
- // 字幕改变
- for(Mpv::Track tck : m_fileInfo.stracks)
- if(tck.id == sid)
- ShowText(tr("subtitle : ").append(tck.title));
- }
- mpv_get_property(m_mpvHandle, "aid", MPV_FORMAT_INT64, &aid);
- g_core_signal->notifyAudioId(aid);
- mpv_get_property(m_mpvHandle, "vid", MPV_FORMAT_INT64, &vid);
- g_core_signal->notifyVideoId(vid);
- m_vid = vid;
- m_aid = aid;
- break;
+ //case MPV_EVENT_TRACK_SWITCHED:
+ // KyInfo() << "[mpv event] MPV_EVENT_TRACK_SWITCHED";
+ // // 轨道id改变
+ // mpv_get_property(m_mpvHandle, "sid", MPV_FORMAT_INT64, &sid);
+ // if (sid > m_stracks)
+ // sid = 0;
+
+ // g_core_signal->notifySubId(sid);
+ // if(sid != m_sid && sid >= 0)
+ // {
+ // m_sid = sid;
+ // if (sid == 0) {
+ // ShowText(tr("subtitle : ").append("no"));
+ // }
+ // // 字幕改变
+ // for(Mpv::Track tck : m_fileInfo.stracks)
+ // if(tck.id == sid)
+ // ShowText(tr("subtitle : ").append(tck.title));
+ // }
+ // mpv_get_property(m_mpvHandle, "aid", MPV_FORMAT_INT64, &aid);
+ // g_core_signal->notifyAudioId(aid);
+ // mpv_get_property(m_mpvHandle, "vid", MPV_FORMAT_INT64, &vid);
+ // g_core_signal->notifyVideoId(vid);
+ // m_vid = vid;
+ // m_aid = aid;
+ // break;
default: // unhandled events
break;
}
--
2.43.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/kr-space/kylin-video.git
git@gitee.com:kr-space/kylin-video.git
kr-space
kylin-video
kylin-video
master

搜索帮助