Update talk to 61699344.
TBR=wu@webrtc.org Review URL: https://webrtc-codereview.appspot.com/8809004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@5560 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
e3842897e2
commit
92fdfebedd
@ -45,10 +45,12 @@ struct PacketTimeUpdateParams {
|
||||
srtp_packet_index(-1) {
|
||||
}
|
||||
|
||||
int rtp_sendtime_extension_id; // extension header id present in packet.
|
||||
Buffer srtp_auth_key; // Authentication key.
|
||||
int srtp_auth_tag_len; // Authentication tag length.
|
||||
int64 srtp_packet_index; // Required for Rtp Packet authentication.
|
||||
int rtp_sendtime_extension_id; // extension header id present in packet.
|
||||
std::vector<char> srtp_auth_key; // Authentication key.
|
||||
int srtp_auth_tag_len; // Authentication tag length.
|
||||
int64 srtp_packet_index; // Required for Rtp Packet authentication.
|
||||
int payload_len; // Raw payload length, before any wrapping
|
||||
// like TURN/GTURN.
|
||||
};
|
||||
|
||||
// This structure holds meta information for the packet which is about to send
|
||||
|
@ -539,6 +539,10 @@ class MediaChannel : public sigslot::has_slots<> {
|
||||
const std::vector<RtpHeaderExtension>& extensions) = 0;
|
||||
virtual bool SetSendRtpHeaderExtensions(
|
||||
const std::vector<RtpHeaderExtension>& extensions) = 0;
|
||||
// Returns the absoulte sendtime extension id value from media channel.
|
||||
virtual int GetRtpSendTimeExtnId() const {
|
||||
return -1;
|
||||
}
|
||||
// Sets the initial bandwidth to use when sending starts.
|
||||
virtual bool SetStartSendBandwidth(int bps) = 0;
|
||||
// Sets the maximum allowed bandwidth to use when sending data.
|
||||
|
@ -2467,7 +2467,7 @@ bool WebRtcVideoMediaChannel::GetStats(const StatsOptions& options,
|
||||
// Only call for the default channel because the returned stats are
|
||||
// collected for all the channels using the same estimator.
|
||||
if (engine_->vie()->rtp()->GetReceiveBandwidthEstimatorStats(
|
||||
recv_channels_[0]->channel_id(), &additional_stats)) {
|
||||
recv_channels_[0]->channel_id(), &additional_stats) == 0) {
|
||||
bwe.total_received_propagation_delta_ms =
|
||||
additional_stats.total_propagation_time_delta_ms;
|
||||
bwe.recent_received_propagation_delta_ms.swap(
|
||||
@ -2664,6 +2664,15 @@ bool WebRtcVideoMediaChannel::SetSendRtpHeaderExtensions(
|
||||
return true;
|
||||
}
|
||||
|
||||
int WebRtcVideoMediaChannel::GetRtpSendTimeExtnId() const {
|
||||
const RtpHeaderExtension* send_time_extension = FindHeaderExtension(
|
||||
send_extensions_, kRtpAbsoluteSendTimeHeaderExtension);
|
||||
if (send_time_extension) {
|
||||
return send_time_extension->id;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
bool WebRtcVideoMediaChannel::SetStartSendBandwidth(int bps) {
|
||||
LOG(LS_INFO) << "WebRtcVideoMediaChannel::SetStartSendBandwidth";
|
||||
|
||||
|
@ -273,6 +273,7 @@ class WebRtcVideoMediaChannel : public talk_base::MessageHandler,
|
||||
const std::vector<RtpHeaderExtension>& extensions);
|
||||
virtual bool SetSendRtpHeaderExtensions(
|
||||
const std::vector<RtpHeaderExtension>& extensions);
|
||||
virtual int GetRtpSendTimeExtnId() const;
|
||||
virtual bool SetStartSendBandwidth(int bps);
|
||||
virtual bool SetMaxSendBandwidth(int bps);
|
||||
virtual bool SetOptions(const VideoOptions &options);
|
||||
|
@ -1886,6 +1886,18 @@ TEST_F(WebRtcVideoMediaChannelTest, SetRecvCodecsUnsupportedCodec) {
|
||||
EXPECT_FALSE(channel_->SetRecvCodecs(codecs));
|
||||
}
|
||||
|
||||
TEST_F(WebRtcVideoMediaChannelTest, GetRtpSendTimeExtension) {
|
||||
// Enable RTP timestamp extension.
|
||||
const int id = 12;
|
||||
std::vector<cricket::RtpHeaderExtension> extensions;
|
||||
extensions.push_back(cricket::RtpHeaderExtension(
|
||||
"http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time", id));
|
||||
|
||||
// Verify the send extension id.
|
||||
EXPECT_TRUE(channel_->SetSendRtpHeaderExtensions(extensions));
|
||||
EXPECT_EQ(id, channel_->GetRtpSendTimeExtnId());
|
||||
}
|
||||
|
||||
TEST_F(WebRtcVideoMediaChannelTest, SetSend) {
|
||||
Base::SetSend();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user