Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
Z
ZLMediaKit
概览
Overview
Details
Activity
Cycle Analytics
版本库
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
问题
0
Issues
0
列表
Board
标记
里程碑
合并请求
0
Merge Requests
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
Snippets
成员
Collapse sidebar
Close sidebar
活动
图像
聊天
创建新问题
作业
提交
Issue Boards
Open sidebar
张翔宇
ZLMediaKit
Commits
eb382c3f
Unverified
Commit
eb382c3f
authored
Jul 22, 2023
by
Dw9
Committed by
GitHub
Jul 22, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复whip delete_webrtc未注销流 (#2688)
bug触发条件: 1、obs whip 推流到zlm 2、关闭推流 3、zlm 未注销流
parent
19d6f1a0
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
11 行增加
和
3 行删除
+11
-3
webrtc/WebRtcPusher.cpp
+8
-2
webrtc/WebRtcPusher.h
+3
-1
没有找到文件。
webrtc/WebRtcPusher.cpp
查看文件 @
eb382c3f
...
...
@@ -149,7 +149,7 @@ void WebRtcPusher::onRtcConfigure(RtcConfigure &configure) const {
configure
.
audio
.
direction
=
configure
.
video
.
direction
=
RtpDirection
::
recvonly
;
}
float
WebRtcPusher
::
getLossRate
(
MediaSource
&
sender
,
TrackType
type
){
float
WebRtcPusher
::
getLossRate
(
MediaSource
&
sender
,
TrackType
type
)
{
return
WebRtcTransportImp
::
getLossRate
(
type
);
}
...
...
@@ -159,8 +159,13 @@ void WebRtcPusher::OnDtlsTransportClosed(const RTC::DtlsTransport *dtlsTransport
WebRtcTransportImp
::
OnDtlsTransportClosed
(
dtlsTransport
);
}
void
WebRtcPusher
::
onRtcpBye
(){
void
WebRtcPusher
::
onRtcpBye
()
{
WebRtcTransportImp
::
onRtcpBye
();
}
void
WebRtcPusher
::
onShutdown
(
const
SockException
&
ex
)
{
_push_src
=
nullptr
;
WebRtcTransportImp
::
onShutdown
(
ex
);
}
}
//
namespace
mediakit
\ No newline at end of file
webrtc/WebRtcPusher.h
查看文件 @
eb382c3f
...
...
@@ -23,15 +23,17 @@ public:
static
Ptr
create
(
const
EventPoller
::
Ptr
&
poller
,
const
RtspMediaSource
::
Ptr
&
src
,
const
std
::
shared_ptr
<
void
>
&
ownership
,
const
MediaInfo
&
info
,
const
ProtocolOption
&
option
,
bool
preferred_tcp
=
false
);
protected
:
///////WebRtcTransportImp override///////
void
onStartWebRTC
()
override
;
void
onDestory
()
override
;
void
onRtcConfigure
(
RtcConfigure
&
configure
)
const
override
;
void
onRecvRtp
(
MediaTrack
&
track
,
const
std
::
string
&
rid
,
RtpPacket
::
Ptr
rtp
)
override
;
void
onShutdown
(
const
SockException
&
ex
)
override
;
void
onRtcpBye
()
override
;
//// dtls相关的回调 ////
void
OnDtlsTransportClosed
(
const
RTC
::
DtlsTransport
*
dtlsTransport
)
override
;
void
OnDtlsTransportClosed
(
const
RTC
::
DtlsTransport
*
dtlsTransport
)
override
;
protected
:
///////MediaSourceEvent override///////
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论