Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
M
mediasoup
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
聂卓夫
mediasoup
Commits
ad4bc122
提交
ad4bc122
authored
6月 26, 2019
作者:
José Luis Millán
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
RTCP XR: cosmetic
上级
15934e3d
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
13 行增加
和
20 行删除
+13
-20
XR.hpp
worker/include/RTC/RTCP/XR.hpp
+3
-4
XrDelaySinceLastRr.hpp
worker/include/RTC/RTCP/XrDelaySinceLastRr.hpp
+8
-9
XrReceiverReferenceTime.hpp
worker/include/RTC/RTCP/XrReceiverReferenceTime.hpp
+2
-2
XrDelaySinceLastRr.cpp
worker/src/RTC/RTCP/XrDelaySinceLastRr.cpp
+0
-4
XrReceiverReferenceTime.cpp
worker/src/RTC/RTCP/XrReceiverReferenceTime.cpp
+0
-1
没有找到文件。
worker/include/RTC/RTCP/XR.hpp
浏览文件 @
ad4bc122
...
@@ -52,12 +52,11 @@ namespace RTC
...
@@ -52,12 +52,11 @@ namespace RTC
ExtendedReportBlock
(
Type
type
);
ExtendedReportBlock
(
Type
type
);
virtual
~
ExtendedReportBlock
()
=
default
;
virtual
~
ExtendedReportBlock
()
=
default
;
ExtendedReportBlock
::
Type
GetType
()
const
;
public
:
public
:
virtual
void
Dump
()
const
=
0
;
virtual
void
Dump
()
const
=
0
;
virtual
size_t
Serialize
(
uint8_t
*
buffer
)
=
0
;
virtual
size_t
Serialize
(
uint8_t
*
buffer
)
=
0
;
virtual
size_t
GetSize
()
const
=
0
;
virtual
size_t
GetSize
()
const
=
0
;
ExtendedReportBlock
::
Type
GetType
()
const
;
protected
:
protected
:
Type
type
;
Type
type
;
...
@@ -97,7 +96,7 @@ namespace RTC
...
@@ -97,7 +96,7 @@ namespace RTC
std
::
vector
<
ExtendedReportBlock
*>
reports
;
std
::
vector
<
ExtendedReportBlock
*>
reports
;
};
};
/
/ Inline ExtendedReportBlock methods.
/
* Inline ExtendedReportBlock instance methods. */
inline
ExtendedReportBlock
::
ExtendedReportBlock
(
Type
type
)
:
type
(
type
)
inline
ExtendedReportBlock
::
ExtendedReportBlock
(
Type
type
)
:
type
(
type
)
{
{
...
@@ -126,7 +125,7 @@ namespace RTC
...
@@ -126,7 +125,7 @@ namespace RTC
this
->
ssrc
=
uint32_t
{
htonl
(
ssrc
)
};
this
->
ssrc
=
uint32_t
{
htonl
(
ssrc
)
};
}
}
/
/ Inline ExtendedReportPacket methods.
/
* Inline ExtendedReportPacket instance methods. */
inline
ExtendedReportPacket
::
ExtendedReportPacket
()
:
Packet
(
Type
::
XR
)
inline
ExtendedReportPacket
::
ExtendedReportPacket
()
:
Packet
(
Type
::
XR
)
{
{
...
...
worker/include/RTC/RTCP/XrDelaySinceLastRr.hpp
浏览文件 @
ad4bc122
...
@@ -29,9 +29,15 @@ namespace RTC
...
@@ -29,9 +29,15 @@ namespace RTC
{
{
class
DelaySinceLastRr
:
public
ExtendedReportBlock
class
DelaySinceLastRr
:
public
ExtendedReportBlock
{
{
public
:
static
DelaySinceLastRr
*
Parse
(
const
uint8_t
*
data
,
size_t
len
);
public
:
public
:
class
SsrcInfo
class
SsrcInfo
{
{
public
:
static
SsrcInfo
*
Parse
(
const
uint8_t
*
data
,
size_t
len
);
public
:
public
:
struct
Body
struct
Body
{
{
...
@@ -40,9 +46,6 @@ namespace RTC
...
@@ -40,9 +46,6 @@ namespace RTC
uint32_t
dlrr
;
uint32_t
dlrr
;
};
};
public
:
static
SsrcInfo
*
Parse
(
const
uint8_t
*
data
,
size_t
len
);
public
:
public
:
// Parsed Report. Points to an external data.
// Parsed Report. Points to an external data.
explicit
SsrcInfo
(
Body
*
body
);
explicit
SsrcInfo
(
Body
*
body
);
...
@@ -68,19 +71,15 @@ namespace RTC
...
@@ -68,19 +71,15 @@ namespace RTC
public
:
public
:
using
Iterator
=
std
::
vector
<
SsrcInfo
*>::
iterator
;
using
Iterator
=
std
::
vector
<
SsrcInfo
*>::
iterator
;
public
:
static
DelaySinceLastRr
*
Parse
(
const
uint8_t
*
data
,
size_t
len
);
public
:
public
:
explicit
DelaySinceLastRr
(
CommonHeader
*
header
);
explicit
DelaySinceLastRr
(
CommonHeader
*
header
);
DelaySinceLastRr
();
DelaySinceLastRr
();
~
DelaySinceLastRr
();
~
DelaySinceLastRr
();
Iterator
Begin
();
Iterator
End
();
public
:
public
:
void
AddSsrcInfo
(
SsrcInfo
*
ssrcInfo
);
void
AddSsrcInfo
(
SsrcInfo
*
ssrcInfo
);
Iterator
Begin
();
Iterator
End
();
/* Pure virtual methods inherited from ExtendedReportBlock. */
/* Pure virtual methods inherited from ExtendedReportBlock. */
public
:
public
:
...
...
worker/include/RTC/RTCP/XrReceiverReferenceTime.hpp
浏览文件 @
ad4bc122
...
@@ -36,10 +36,10 @@ namespace RTC
...
@@ -36,10 +36,10 @@ namespace RTC
public
:
public
:
// Parsed Report. Points to an external data.
// Parsed Report. Points to an external data.
explicit
ReceiverReferenceTime
(
CommonHeader
*
header
);
explicit
ReceiverReferenceTime
(
CommonHeader
*
header
);
// Locally generated Report. Holds the data internally.
// Locally generated Report. Holds the data internally.
ReceiverReferenceTime
();
ReceiverReferenceTime
();
public
:
uint32_t
GetNtpSec
()
const
;
uint32_t
GetNtpSec
()
const
;
void
SetNtpSec
(
uint32_t
ntpSec
);
void
SetNtpSec
(
uint32_t
ntpSec
);
uint32_t
GetNtpFrac
()
const
;
uint32_t
GetNtpFrac
()
const
;
...
@@ -56,7 +56,7 @@ namespace RTC
...
@@ -56,7 +56,7 @@ namespace RTC
uint8_t
raw
[
sizeof
(
Body
)]
=
{
0
};
uint8_t
raw
[
sizeof
(
Body
)]
=
{
0
};
};
};
/* Inline instance methods. */
/* Inline
ReceiverReferenceTime
instance methods. */
inline
ReceiverReferenceTime
::
ReceiverReferenceTime
()
inline
ReceiverReferenceTime
::
ReceiverReferenceTime
()
:
ExtendedReportBlock
(
RTCP
::
ExtendedReportBlock
::
Type
::
RRT
)
:
ExtendedReportBlock
(
RTCP
::
ExtendedReportBlock
::
Type
::
RRT
)
...
...
worker/src/RTC/RTCP/XrDelaySinceLastRr.cpp
浏览文件 @
ad4bc122
...
@@ -65,7 +65,6 @@ namespace RTC
...
@@ -65,7 +65,6 @@ namespace RTC
std
::
unique_ptr
<
DelaySinceLastRr
>
report
(
new
DelaySinceLastRr
(
header
));
std
::
unique_ptr
<
DelaySinceLastRr
>
report
(
new
DelaySinceLastRr
(
header
));
size_t
offset
{
sizeof
(
ExtendedReportBlock
::
CommonHeader
)
};
size_t
offset
{
sizeof
(
ExtendedReportBlock
::
CommonHeader
)
};
uint16_t
reportLength
=
ntohs
(
header
->
length
)
*
4
;
uint16_t
reportLength
=
ntohs
(
header
->
length
)
*
4
;
while
(
len
>
offset
&&
reportLength
>=
sizeof
(
DelaySinceLastRr
::
SsrcInfo
::
Body
))
while
(
len
>
offset
&&
reportLength
>=
sizeof
(
DelaySinceLastRr
::
SsrcInfo
::
Body
))
...
@@ -121,18 +120,15 @@ namespace RTC
...
@@ -121,18 +120,15 @@ namespace RTC
MS_TRACE
();
MS_TRACE
();
MS_DUMP
(
"<DelaySinceLastRr>"
);
MS_DUMP
(
"<DelaySinceLastRr>"
);
MS_DUMP
(
" block type : %"
PRIu8
,
this
->
type
);
MS_DUMP
(
" block type : %"
PRIu8
,
this
->
type
);
MS_DUMP
(
" reserved : 0"
);
MS_DUMP
(
" reserved : 0"
);
MS_DUMP
(
MS_DUMP
(
" length : %"
PRIu16
,
" length : %"
PRIu16
,
static_cast
<
uint16_t
>
((
sizeof
(
SsrcInfo
::
Body
)
*
this
->
ssrcInfos
.
size
()
/
4
)));
static_cast
<
uint16_t
>
((
sizeof
(
SsrcInfo
::
Body
)
*
this
->
ssrcInfos
.
size
()
/
4
)));
for
(
auto
*
ssrcInfo
:
this
->
ssrcInfos
)
for
(
auto
*
ssrcInfo
:
this
->
ssrcInfos
)
{
{
ssrcInfo
->
Dump
();
ssrcInfo
->
Dump
();
}
}
MS_DUMP
(
"</DelaySinceLastRr>"
);
MS_DUMP
(
"</DelaySinceLastRr>"
);
}
}
}
// namespace RTCP
}
// namespace RTCP
...
...
worker/src/RTC/RTCP/XrReceiverReferenceTime.cpp
浏览文件 @
ad4bc122
...
@@ -35,7 +35,6 @@ namespace RTC
...
@@ -35,7 +35,6 @@ namespace RTC
MS_TRACE
();
MS_TRACE
();
MS_DUMP
(
"<ReceiverReferenceTime>"
);
MS_DUMP
(
"<ReceiverReferenceTime>"
);
MS_DUMP
(
" block type : %"
PRIu8
,
this
->
type
);
MS_DUMP
(
" block type : %"
PRIu8
,
this
->
type
);
MS_DUMP
(
" reserved : 0"
);
MS_DUMP
(
" reserved : 0"
);
MS_DUMP
(
" length : 2"
);
MS_DUMP
(
" length : 2"
);
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论