From 9f90548a67df0a9f1425a1c884186bf48eb7be21 Mon Sep 17 00:00:00 2001 From: xiongziliang <771730766@qq.com> Date: Thu, 27 Aug 2026 23:17:37 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=BC=96=E8=AF=91=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Player/PlayerProxy.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/Player/PlayerProxy.cpp b/src/Player/PlayerProxy.cpp index b888d441..1b781c56 100644 --- a/src/Player/PlayerProxy.cpp +++ b/src/Player/PlayerProxy.cpp @@ -16,7 +16,9 @@ #include "Rtmp/RtmpPlayer.h" #include "Rtsp/RtspMediaSource.h" #include "Rtsp/RtspPlayer.h" +#if defined(ENABLE_WEBRTC) #include "webrtc/WebRtcProxyPlayer.h" +#endif #include "Util/MD5.h" #include "Util/logger.h" #include "Util/mini.h" @@ -280,7 +282,11 @@ void PlayerProxy::play(const string &url) { void PlayerProxy::setDirectProxy() { MediaSource::Ptr mediaSource; - if (dynamic_pointer_cast(_delegate) || dynamic_pointer_cast(_delegate)) { + if (dynamic_pointer_cast(_delegate) +#if defined(ENABLE_WEBRTC) + || dynamic_pointer_cast(_delegate) +#endif + ) { // rtsp拉流 [AUTO-TRANSLATED:189cf691] // Rtsp stream GET_CONFIG(bool, directProxy, Rtsp::kDirectProxy);