Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
M
mediasoup
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
聂卓夫
mediasoup
Commits
2e9c231b
Unverified
提交
2e9c231b
authored
11月 21, 2023
作者:
Iñaki Baz Castillo
提交者:
GitHub
11月 21, 2023
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix RTCP DLRR (Delay Since Last Receiver Report) block parsing (#1234)
上级
c65f8ffd
显示空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
100 行增加
和
6 行删除
+100
-6
CHANGELOG.md
CHANGELOG.md
+5
-0
Makefile
worker/Makefile
+3
-3
remote_bitrate_estimator_abs_send_time.cc
...trate_estimator/remote_bitrate_estimator_abs_send_time.cc
+4
-0
XrDelaySinceLastRr.cpp
worker/src/RTC/RTCP/XrDelaySinceLastRr.cpp
+1
-3
TestXr.cpp
worker/test/src/RTC/RTCP/TestXr.cpp
+87
-0
没有找到文件。
CHANGELOG.md
浏览文件 @
2e9c231b
# Changelog
# Changelog
### NEXT
*
Fix RTCP DLRR (Delay Since Last Receiver Report) block parsing (
[
PR #1234
](
https://github.com/versatica/mediasoup/pull/1234
)
).
### 3.13.3
### 3.13.3
*
Node: Fix issue when 'pause'/'resume' events are not emitted (
[
PR #1231
](
https://github.com/versatica/mediasoup/pull/1231
)
by @douglaseel).
*
Node: Fix issue when 'pause'/'resume' events are not emitted (
[
PR #1231
](
https://github.com/versatica/mediasoup/pull/1231
)
by @douglaseel).
...
...
worker/Makefile
浏览文件 @
2e9c231b
...
@@ -213,7 +213,7 @@ libmediasoup-worker: setup flatc
...
@@ -213,7 +213,7 @@ libmediasoup-worker: setup flatc
flatc
:
setup
flatc
:
setup
$(MESON)
compile
-C
$(BUILD_DIR)
flatbuffers-generator
$(MESON)
compile
-C
$(BUILD_DIR)
flatbuffers-generator
xcode
:
setup
xcode
:
setup
flatc
$(MESON)
setup
--buildtype
debug
--backend
xcode
$(MEDIASOUP_OUT_DIR)
/xcode
$(MESON)
setup
--buildtype
debug
--backend
xcode
$(MEDIASOUP_OUT_DIR)
/xcode
lint
:
lint
:
...
@@ -234,7 +234,7 @@ else
...
@@ -234,7 +234,7 @@ else
$(BUILD_DIR)/mediasoup-worker-test
--invisibles
--use-colour
=
yes
$(MEDIASOUP_TEST_TAGS)
$(BUILD_DIR)/mediasoup-worker-test
--invisibles
--use-colour
=
yes
$(MEDIASOUP_TEST_TAGS)
endif
endif
test-asan
:
setup
test-asan
:
setup
flatc
$(MESON)
compile
-C
$(BUILD_DIR)
-j
$(CORES)
mediasoup-worker-test-asan
$(MESON)
compile
-C
$(BUILD_DIR)
-j
$(CORES)
mediasoup-worker-test-asan
$(MESON)
install
-C
$(BUILD_DIR)
--no-rebuild
--tags
mediasoup-worker-test-asan
$(MESON)
install
-C
$(BUILD_DIR)
--no-rebuild
--tags
mediasoup-worker-test-asan
ASAN_OPTIONS
=
detect_leaks
=
1
$(BUILD_DIR)
/mediasoup-worker-test-asan
--invisibles
--use-colour
=
yes
$(MEDIASOUP_TEST_TAGS)
ASAN_OPTIONS
=
detect_leaks
=
1
$(BUILD_DIR)
/mediasoup-worker-test-asan
--invisibles
--use-colour
=
yes
$(MEDIASOUP_TEST_TAGS)
...
@@ -249,7 +249,7 @@ tidy:
...
@@ -249,7 +249,7 @@ tidy:
-checks
=
$(MEDIASOUP_TIDY_CHECKS)
\
-checks
=
$(MEDIASOUP_TIDY_CHECKS)
\
-quiet
-quiet
fuzzer
:
setup
fuzzer
:
setup
flatc
$(MESON)
compile
-C
$(BUILD_DIR)
-j
$(CORES)
mediasoup-worker-fuzzer
$(MESON)
compile
-C
$(BUILD_DIR)
-j
$(CORES)
mediasoup-worker-fuzzer
$(MESON)
install
-C
$(BUILD_DIR)
--no-rebuild
--tags
mediasoup-worker-fuzzer
$(MESON)
install
-C
$(BUILD_DIR)
--no-rebuild
--tags
mediasoup-worker-fuzzer
...
...
worker/deps/libwebrtc/libwebrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_abs_send_time.cc
浏览文件 @
2e9c231b
...
@@ -289,6 +289,8 @@ void RemoteBitrateEstimatorAbsSendTime::IncomingPacketInfo(
...
@@ -289,6 +289,8 @@ void RemoteBitrateEstimatorAbsSendTime::IncomingPacketInfo(
if
(
payload_size
>
kMinProbePacketSize
&&
if
(
payload_size
>
kMinProbePacketSize
&&
(
!
remote_rate_
.
ValidEstimate
()
||
(
!
remote_rate_
.
ValidEstimate
()
||
now_ms
-
first_packet_time_ms_
<
kInitialProbingIntervalMs
))
{
now_ms
-
first_packet_time_ms_
<
kInitialProbingIntervalMs
))
{
#if MS_LOG_DEV_LEVEL == 3
// TODO(holmer): Use a map instead to get correct order?
// TODO(holmer): Use a map instead to get correct order?
if
(
total_probes_received_
<
kMaxProbePackets
)
{
if
(
total_probes_received_
<
kMaxProbePackets
)
{
int
send_delta_ms
=
-
1
;
int
send_delta_ms
=
-
1
;
...
@@ -306,6 +308,8 @@ void RemoteBitrateEstimatorAbsSendTime::IncomingPacketInfo(
...
@@ -306,6 +308,8 @@ void RemoteBitrateEstimatorAbsSendTime::IncomingPacketInfo(
send_delta_ms
,
send_delta_ms
,
recv_delta_ms
);
recv_delta_ms
);
}
}
#endif
probes_
.
push_back
(
Probe
(
send_time_ms
,
arrival_time_ms
,
payload_size
));
probes_
.
push_back
(
Probe
(
send_time_ms
,
arrival_time_ms
,
payload_size
));
++
total_probes_received_
;
++
total_probes_received_
;
// Make sure that a probe which updated the bitrate immediately has an
// Make sure that a probe which updated the bitrate immediately has an
...
...
worker/src/RTC/RTCP/XrDelaySinceLastRr.cpp
浏览文件 @
2e9c231b
...
@@ -75,14 +75,12 @@ namespace RTC
...
@@ -75,14 +75,12 @@ namespace RTC
{
{
report
->
AddSsrcInfo
(
ssrcInfo
);
report
->
AddSsrcInfo
(
ssrcInfo
);
offset
+=
ssrcInfo
->
GetSize
();
offset
+=
ssrcInfo
->
GetSize
();
reportLength
-=
ssrcInfo
->
GetSize
();
}
}
else
else
{
{
return
report
.
release
();
return
report
.
release
();
}
}
offset
+=
ssrcInfo
->
GetSize
();
reportLength
-=
DelaySinceLastRr
::
SsrcInfo
::
BodySize
;
}
}
return
report
.
release
();
return
report
.
release
();
...
...
worker/test/src/RTC/RTCP/TestXr.cpp
浏览文件 @
2e9c231b
#include "common.hpp"
#include "common.hpp"
#include "RTC/RTCP/XR.hpp"
#include "RTC/RTCP/XrDelaySinceLastRr.hpp"
#include "RTC/RTCP/XrDelaySinceLastRr.hpp"
#include "RTC/RTCP/XrReceiverReferenceTime.hpp"
#include "RTC/RTCP/XrReceiverReferenceTime.hpp"
#include <catch2/catch.hpp>
#include <catch2/catch.hpp>
...
@@ -6,6 +7,92 @@
...
@@ -6,6 +7,92 @@
using
namespace
RTC
::
RTCP
;
using
namespace
RTC
::
RTCP
;
SCENARIO
(
"RTCP XR parsing"
,
"[parser][rtcp][xr]"
)
{
// clang-format off
uint8_t
buffer
[]
=
{
0xa0
,
0xcf
,
0x00
,
0x08
,
// Padding, Type: 207 (XR), Length: 8
0x5d
,
0x93
,
0x15
,
0x34
,
// Sender SSRC: 0x5d931534
// Extended Report DLRR
0x05
,
0x00
,
0x00
,
0x06
,
// BT: 5 (DLRR), Block Length: 6
0x11
,
0x12
,
0x13
,
0x14
,
// SSRC 1
0x00
,
0x11
,
0x00
,
0x11
,
// LRR 1
0x11
,
0x00
,
0x11
,
0x00
,
// DLRR 1
0x21
,
0x22
,
0x23
,
0x24
,
// SSRC 2
0x00
,
0x22
,
0x00
,
0x22
,
// LRR 2
0x22
,
0x00
,
0x22
,
0x00
,
// DLRR 2
0x00
,
0x00
,
0x00
,
0x04
// Padding (4 bytes)
};
// clang-format on
SECTION
(
"parse XR packet"
)
{
auto
*
packet
=
ExtendedReportPacket
::
Parse
(
buffer
,
sizeof
(
buffer
));
REQUIRE
(
packet
);
// Despite total buffer size is 40 bytes, our GetSize() method doesn't not
// consider RTCP padding (4 bytes in this case).
REQUIRE
(
packet
->
GetSize
()
==
36
);
REQUIRE
(
packet
->
GetCount
()
==
0
);
REQUIRE
(
packet
->
GetSsrc
()
==
0x5d931534
);
size_t
blockIdx
{
0u
};
for
(
auto
it
=
packet
->
Begin
();
it
!=
packet
->
End
();
++
it
,
++
blockIdx
)
{
auto
*
block
=
*
it
;
switch
(
blockIdx
)
{
case
0
:
{
REQUIRE
(
block
->
GetSize
()
==
28
);
size_t
ssrcInfoIdx
{
0u
};
auto
*
dlrrBlock
=
reinterpret_cast
<
DelaySinceLastRr
*>
(
block
);
for
(
auto
it2
=
dlrrBlock
->
Begin
();
it2
!=
dlrrBlock
->
End
();
++
it2
,
++
ssrcInfoIdx
)
{
auto
*
ssrcInfo
=
*
it2
;
switch
(
ssrcInfoIdx
)
{
case
0
:
{
REQUIRE
(
ssrcInfo
->
GetSsrc
()
==
0x11121314
);
REQUIRE
(
ssrcInfo
->
GetLastReceiverReport
()
==
0x00110011
);
REQUIRE
(
ssrcInfo
->
GetDelaySinceLastReceiverReport
()
==
0x11001100
);
break
;
}
case
1
:
{
REQUIRE
(
ssrcInfo
->
GetSsrc
()
==
0x21222324
);
REQUIRE
(
ssrcInfo
->
GetLastReceiverReport
()
==
0x00220022
);
REQUIRE
(
ssrcInfo
->
GetDelaySinceLastReceiverReport
()
==
0x22002200
);
break
;
}
}
}
// There are 2 SSRC infos.
REQUIRE
(
ssrcInfoIdx
==
2
);
break
;
}
}
}
// There are 1 block (the DLRR block).
REQUIRE
(
blockIdx
==
1
);
delete
packet
;
}
}
SCENARIO
(
"RTCP XrDelaySinceLastRt parsing"
,
"[parser][rtcp][xr-dlrr]"
)
SCENARIO
(
"RTCP XrDelaySinceLastRt parsing"
,
"[parser][rtcp][xr-dlrr]"
)
{
{
SECTION
(
"create RRT"
)
SECTION
(
"create RRT"
)
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论