(Auto)update libjingle 63913264-> 63948945
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5807 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
0aa04f9f24
commit
987f2c9aae
@ -84,6 +84,8 @@ const char StatsReport::kStatsValueNameFingerprintAlgorithm[] =
|
||||
"googFingerprintAlgorithm";
|
||||
const char StatsReport::kStatsValueNameFirsReceived[] = "googFirsReceived";
|
||||
const char StatsReport::kStatsValueNameFirsSent[] = "googFirsSent";
|
||||
const char StatsReport::kStatsValueNameFrameHeightInput[] =
|
||||
"googFrameHeightInput";
|
||||
const char StatsReport::kStatsValueNameFrameHeightReceived[] =
|
||||
"googFrameHeightReceived";
|
||||
const char StatsReport::kStatsValueNameFrameHeightSent[] =
|
||||
@ -105,6 +107,8 @@ const char StatsReport::kStatsValueNameRenderDelayMs[] = "googRenderDelayMs";
|
||||
|
||||
const char StatsReport::kStatsValueNameFrameRateInput[] = "googFrameRateInput";
|
||||
const char StatsReport::kStatsValueNameFrameRateSent[] = "googFrameRateSent";
|
||||
const char StatsReport::kStatsValueNameFrameWidthInput[] =
|
||||
"googFrameWidthInput";
|
||||
const char StatsReport::kStatsValueNameFrameWidthReceived[] =
|
||||
"googFrameWidthReceived";
|
||||
const char StatsReport::kStatsValueNameFrameWidthSent[] = "googFrameWidthSent";
|
||||
@ -350,10 +354,14 @@ void ExtractStats(const cricket::VideoSenderInfo& info, StatsReport* report) {
|
||||
info.plis_rcvd);
|
||||
report->AddValue(StatsReport::kStatsValueNameNacksReceived,
|
||||
info.nacks_rcvd);
|
||||
report->AddValue(StatsReport::kStatsValueNameFrameWidthInput,
|
||||
info.input_frame_width);
|
||||
report->AddValue(StatsReport::kStatsValueNameFrameHeightInput,
|
||||
info.input_frame_height);
|
||||
report->AddValue(StatsReport::kStatsValueNameFrameWidthSent,
|
||||
info.frame_width);
|
||||
info.send_frame_width);
|
||||
report->AddValue(StatsReport::kStatsValueNameFrameHeightSent,
|
||||
info.frame_height);
|
||||
info.send_frame_height);
|
||||
report->AddValue(StatsReport::kStatsValueNameFrameRateInput,
|
||||
info.framerate_input);
|
||||
report->AddValue(StatsReport::kStatsValueNameFrameRateSent,
|
||||
|
||||
@ -148,6 +148,7 @@ class StatsReport {
|
||||
static const char kStatsValueNameExpandRate[];
|
||||
static const char kStatsValueNameFirsReceived[];
|
||||
static const char kStatsValueNameFirsSent[];
|
||||
static const char kStatsValueNameFrameHeightInput[];
|
||||
static const char kStatsValueNameFrameHeightReceived[];
|
||||
static const char kStatsValueNameFrameHeightSent[];
|
||||
static const char kStatsValueNameFrameRateReceived[];
|
||||
@ -162,6 +163,7 @@ class StatsReport {
|
||||
static const char kStatsValueNameRenderDelayMs[];
|
||||
static const char kStatsValueNameFrameRateInput[];
|
||||
static const char kStatsValueNameFrameRateSent[];
|
||||
static const char kStatsValueNameFrameWidthInput[];
|
||||
static const char kStatsValueNameFrameWidthReceived[];
|
||||
static const char kStatsValueNameFrameWidthSent[];
|
||||
static const char kStatsValueNameJitterReceived[];
|
||||
|
||||
@ -858,8 +858,10 @@ struct VideoSenderInfo : public MediaSenderInfo {
|
||||
firs_rcvd(0),
|
||||
plis_rcvd(0),
|
||||
nacks_rcvd(0),
|
||||
frame_width(0),
|
||||
frame_height(0),
|
||||
input_frame_width(0),
|
||||
input_frame_height(0),
|
||||
send_frame_width(0),
|
||||
send_frame_height(0),
|
||||
framerate_input(0),
|
||||
framerate_sent(0),
|
||||
nominal_bitrate(0),
|
||||
@ -876,8 +878,10 @@ struct VideoSenderInfo : public MediaSenderInfo {
|
||||
int firs_rcvd;
|
||||
int plis_rcvd;
|
||||
int nacks_rcvd;
|
||||
int frame_width;
|
||||
int frame_height;
|
||||
int input_frame_width;
|
||||
int input_frame_height;
|
||||
int send_frame_width;
|
||||
int send_frame_height;
|
||||
int framerate_input;
|
||||
int framerate_sent;
|
||||
int nominal_bitrate;
|
||||
|
||||
@ -806,8 +806,8 @@ class VideoMediaChannelTest : public testing::Test,
|
||||
EXPECT_EQ(0, info.senders[0].firs_rcvd);
|
||||
EXPECT_EQ(0, info.senders[0].plis_rcvd);
|
||||
EXPECT_EQ(0, info.senders[0].nacks_rcvd);
|
||||
EXPECT_EQ(DefaultCodec().width, info.senders[0].frame_width);
|
||||
EXPECT_EQ(DefaultCodec().height, info.senders[0].frame_height);
|
||||
EXPECT_EQ(DefaultCodec().width, info.senders[0].send_frame_width);
|
||||
EXPECT_EQ(DefaultCodec().height, info.senders[0].send_frame_height);
|
||||
EXPECT_GT(info.senders[0].framerate_input, 0);
|
||||
EXPECT_GT(info.senders[0].framerate_sent, 0);
|
||||
|
||||
@ -866,8 +866,8 @@ class VideoMediaChannelTest : public testing::Test,
|
||||
EXPECT_EQ(0, info.senders[0].firs_rcvd);
|
||||
EXPECT_EQ(0, info.senders[0].plis_rcvd);
|
||||
EXPECT_EQ(0, info.senders[0].nacks_rcvd);
|
||||
EXPECT_EQ(DefaultCodec().width, info.senders[0].frame_width);
|
||||
EXPECT_EQ(DefaultCodec().height, info.senders[0].frame_height);
|
||||
EXPECT_EQ(DefaultCodec().width, info.senders[0].send_frame_width);
|
||||
EXPECT_EQ(DefaultCodec().height, info.senders[0].send_frame_height);
|
||||
EXPECT_GT(info.senders[0].framerate_input, 0);
|
||||
EXPECT_GT(info.senders[0].framerate_sent, 0);
|
||||
|
||||
@ -937,12 +937,12 @@ class VideoMediaChannelTest : public testing::Test,
|
||||
info.senders[0].packets_sent + info.senders[1].packets_sent);
|
||||
EXPECT_EQ(1U, info.senders[0].ssrcs().size());
|
||||
EXPECT_EQ(1234U, info.senders[0].ssrcs()[0]);
|
||||
EXPECT_EQ(DefaultCodec().width, info.senders[0].frame_width);
|
||||
EXPECT_EQ(DefaultCodec().height, info.senders[0].frame_height);
|
||||
EXPECT_EQ(DefaultCodec().width, info.senders[0].send_frame_width);
|
||||
EXPECT_EQ(DefaultCodec().height, info.senders[0].send_frame_height);
|
||||
EXPECT_EQ(1U, info.senders[1].ssrcs().size());
|
||||
EXPECT_EQ(5678U, info.senders[1].ssrcs()[0]);
|
||||
EXPECT_EQ(kTestWidth, info.senders[1].frame_width);
|
||||
EXPECT_EQ(kTestHeight, info.senders[1].frame_height);
|
||||
EXPECT_EQ(kTestWidth, info.senders[1].send_frame_width);
|
||||
EXPECT_EQ(kTestHeight, info.senders[1].send_frame_height);
|
||||
// The capturer must be unregistered here as it runs out of it's scope next.
|
||||
EXPECT_TRUE(channel_->SetCapturer(5678, NULL));
|
||||
}
|
||||
|
||||
@ -2368,8 +2368,32 @@ bool WebRtcVideoMediaChannel::GetStats(const StatsOptions& options,
|
||||
sinfo.packets_lost = -1;
|
||||
sinfo.fraction_lost = -1;
|
||||
sinfo.rtt_ms = -1;
|
||||
sinfo.frame_width = static_cast<int>(channel_stream_info->width());
|
||||
sinfo.frame_height = static_cast<int>(channel_stream_info->height());
|
||||
sinfo.input_frame_width = static_cast<int>(channel_stream_info->width());
|
||||
sinfo.input_frame_height =
|
||||
static_cast<int>(channel_stream_info->height());
|
||||
|
||||
VideoCapturer* video_capturer = send_channel->video_capturer();
|
||||
if (video_capturer) {
|
||||
video_capturer->GetStats(&sinfo.adapt_frame_drops,
|
||||
&sinfo.effects_frame_drops,
|
||||
&sinfo.capturer_frame_time);
|
||||
}
|
||||
|
||||
webrtc::VideoCodec vie_codec;
|
||||
// TODO(ronghuawu): Add unit tests to cover the new send stats:
|
||||
// send_frame_width/height.
|
||||
if (!video_capturer || video_capturer->IsMuted()) {
|
||||
sinfo.send_frame_width = 0;
|
||||
sinfo.send_frame_height = 0;
|
||||
} else if (engine()->vie()->codec()->GetSendCodec(channel_id,
|
||||
vie_codec) == 0) {
|
||||
sinfo.send_frame_width = vie_codec.width;
|
||||
sinfo.send_frame_height = vie_codec.height;
|
||||
} else {
|
||||
sinfo.send_frame_width = -1;
|
||||
sinfo.send_frame_height = -1;
|
||||
LOG_RTCERR1(GetSendCodec, channel_id);
|
||||
}
|
||||
sinfo.framerate_input = channel_stream_info->framerate();
|
||||
sinfo.framerate_sent = send_channel->encoder_observer()->framerate();
|
||||
sinfo.nominal_bitrate = send_channel->encoder_observer()->bitrate();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user