Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
M
mediasoup
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
聂卓夫
mediasoup
Commits
c2b7a206
提交
c2b7a206
authored
9月 16, 2017
作者:
Iñaki Baz Castillo
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix serialization of RTX decoded packets.
上级
a71272bc
显示空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
13 行增加
和
2 行删除
+13
-2
NackGenerator.cpp
worker/src/RTC/NackGenerator.cpp
+2
-2
Producer.cpp
worker/src/RTC/Producer.cpp
+11
-0
没有找到文件。
worker/src/RTC/NackGenerator.cpp
浏览文件 @
c2b7a206
...
@@ -9,10 +9,10 @@ namespace RTC
...
@@ -9,10 +9,10 @@ namespace RTC
{
{
/* Static. */
/* Static. */
constexpr
uint32_t
MaxPacketAge
{
10
000
};
constexpr
uint32_t
MaxPacketAge
{
5
000
};
constexpr
size_t
MaxNackPackets
{
1000
};
constexpr
size_t
MaxNackPackets
{
1000
};
constexpr
uint32_t
DefaultRtt
{
100
};
constexpr
uint32_t
DefaultRtt
{
100
};
constexpr
uint8_t
MaxNackRetries
{
10
};
constexpr
uint8_t
MaxNackRetries
{
8
};
constexpr
uint64_t
TimerInterval
{
50
};
constexpr
uint64_t
TimerInterval
{
50
};
/* Instance methods. */
/* Instance methods. */
...
...
worker/src/RTC/Producer.cpp
浏览文件 @
c2b7a206
...
@@ -14,6 +14,8 @@ namespace RTC
...
@@ -14,6 +14,8 @@ namespace RTC
/* Static. */
/* Static. */
static
constexpr
uint64_t
KeyFrameRequestBlockTimeout
{
1000
};
// In ms.
static
constexpr
uint64_t
KeyFrameRequestBlockTimeout
{
1000
};
// In ms.
static
constexpr
size_t
ClonedPacketBufferSize
{
65536
};
static
uint8_t
ClonedPacketBuffer
[
ClonedPacketBufferSize
];
/* Instance methods. */
/* Instance methods. */
...
@@ -267,6 +269,7 @@ namespace RTC
...
@@ -267,6 +269,7 @@ namespace RTC
// Find the corresponding RtpStreamRecv.
// Find the corresponding RtpStreamRecv.
uint32_t
ssrc
=
packet
->
GetSsrc
();
uint32_t
ssrc
=
packet
->
GetSsrc
();
RTC
::
RtpStreamRecv
*
rtpStream
{
nullptr
};
RTC
::
RtpStreamRecv
*
rtpStream
{
nullptr
};
std
::
unique_ptr
<
RTC
::
RtpPacket
>
rtxDecodedPacket
;
if
(
this
->
rtpStreams
.
find
(
ssrc
)
!=
this
->
rtpStreams
.
end
())
if
(
this
->
rtpStreams
.
find
(
ssrc
)
!=
this
->
rtpStreams
.
end
())
{
{
...
@@ -291,6 +294,14 @@ namespace RTC
...
@@ -291,6 +294,14 @@ namespace RTC
// Process the packet.
// Process the packet.
if
(
!
rtpStream
->
ReceiveRtxPacket
(
packet
))
if
(
!
rtpStream
->
ReceiveRtxPacket
(
packet
))
return
;
return
;
// We need to clone the RTX decoded packet so it becomes later serializable
// by just taking its GetData() and GetSize(), so clone it and reassign the
// new RtpPacket to the packet pointer (so the rest of the code below doesn't
// need any change) and assign it to the unique_ptr to be automatically
// freed once this method returns.
packet
=
packet
->
Clone
(
ClonedPacketBuffer
);
rtxDecodedPacket
.
reset
(
packet
);
}
}
else
else
{
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论