OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "media/cast/video_sender/video_sender.h" | 5 #include "media/cast/video_sender/video_sender.h" |
6 | 6 |
7 #include <list> | 7 #include <list> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 video_config.rtcp_mode, | 142 video_config.rtcp_mode, |
143 base::TimeDelta::FromMilliseconds(video_config.rtcp_interval), | 143 base::TimeDelta::FromMilliseconds(video_config.rtcp_interval), |
144 video_config.sender_ssrc, | 144 video_config.sender_ssrc, |
145 video_config.incoming_feedback_ssrc, | 145 video_config.incoming_feedback_ssrc, |
146 video_config.rtcp_c_name)); | 146 video_config.rtcp_c_name)); |
147 | 147 |
148 // TODO(pwestin): pass cast_initialization to |video_encoder_| | 148 // TODO(pwestin): pass cast_initialization to |video_encoder_| |
149 // and remove this call. | 149 // and remove this call. |
150 cast_environment_->PostTask( | 150 cast_environment_->PostTask( |
151 CastEnvironment::MAIN, FROM_HERE, | 151 CastEnvironment::MAIN, FROM_HERE, |
152 base::Bind(initialization_status, STATUS_INITIALIZED)); | 152 base::Bind(initialization_status, STATUS_VIDEO_INITIALIZED)); |
153 cast_environment_->Logging()->AddRawEventSubscriber(&event_subscriber_); | 153 cast_environment_->Logging()->AddRawEventSubscriber(&event_subscriber_); |
154 } | 154 } |
155 | 155 |
156 VideoSender::~VideoSender() { | 156 VideoSender::~VideoSender() { |
157 cast_environment_->Logging()->RemoveRawEventSubscriber(&event_subscriber_); | 157 cast_environment_->Logging()->RemoveRawEventSubscriber(&event_subscriber_); |
158 } | 158 } |
159 | 159 |
160 void VideoSender::InitializeTimers() { | 160 void VideoSender::InitializeTimers() { |
161 DCHECK(cast_environment_->CurrentlyOn(CastEnvironment::MAIN)); | 161 DCHECK(cast_environment_->CurrentlyOn(CastEnvironment::MAIN)); |
162 if (!initialized_) { | 162 if (!initialized_) { |
(...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
480 | 480 |
481 void VideoSender::ResendPacketsOnTransportThread( | 481 void VideoSender::ResendPacketsOnTransportThread( |
482 const transport::MissingFramesAndPacketsMap& missing_packets) { | 482 const transport::MissingFramesAndPacketsMap& missing_packets) { |
483 DCHECK(cast_environment_->CurrentlyOn(CastEnvironment::TRANSPORT)); | 483 DCHECK(cast_environment_->CurrentlyOn(CastEnvironment::TRANSPORT)); |
484 last_send_time_ = cast_environment_->Clock()->NowTicks(); | 484 last_send_time_ = cast_environment_->Clock()->NowTicks(); |
485 transport_sender_->ResendPackets(false, missing_packets); | 485 transport_sender_->ResendPackets(false, missing_packets); |
486 } | 486 } |
487 | 487 |
488 } // namespace cast | 488 } // namespace cast |
489 } // namespace media | 489 } // namespace media |
OLD | NEW |