| 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 #ifndef MEDIA_CAST_AUDIO_SENDER_H_ | 5 #ifndef MEDIA_CAST_AUDIO_SENDER_H_ |
| 6 #define MEDIA_CAST_AUDIO_SENDER_H_ | 6 #define MEDIA_CAST_AUDIO_SENDER_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 void SendEncodedAudioFrame( | 48 void SendEncodedAudioFrame( |
| 49 scoped_ptr<transport::EncodedAudioFrame> audio_frame, | 49 scoped_ptr<transport::EncodedAudioFrame> audio_frame, |
| 50 const base::TimeTicks& recorded_time); | 50 const base::TimeTicks& recorded_time); |
| 51 | 51 |
| 52 private: | 52 private: |
| 53 friend class LocalRtcpAudioSenderFeedback; | 53 friend class LocalRtcpAudioSenderFeedback; |
| 54 | 54 |
| 55 void ResendPackets( | 55 void ResendPackets( |
| 56 const MissingFramesAndPacketsMap& missing_frames_and_packets); | 56 const MissingFramesAndPacketsMap& missing_frames_and_packets); |
| 57 | 57 |
| 58 void StoreStatistics(const transport::RtcpSenderInfo& sender_info, | |
| 59 base::TimeTicks time_sent, | |
| 60 uint32 rtp_timestamp); | |
| 61 | |
| 62 void ScheduleNextRtcpReport(); | 58 void ScheduleNextRtcpReport(); |
| 63 void SendRtcpReport(); | 59 void SendRtcpReport(); |
| 64 | 60 |
| 65 void InitializeTimers(); | 61 void InitializeTimers(); |
| 66 | 62 |
| 67 scoped_refptr<CastEnvironment> cast_environment_; | 63 scoped_refptr<CastEnvironment> cast_environment_; |
| 68 transport::CastTransportSender* const transport_sender_; | 64 transport::CastTransportSender* const transport_sender_; |
| 69 scoped_ptr<AudioEncoder> audio_encoder_; | 65 scoped_ptr<AudioEncoder> audio_encoder_; |
| 70 RtpSenderStatistics rtp_stats_; | 66 RtpTimestampHelper rtp_timestamp_helper_; |
| 71 scoped_ptr<LocalRtcpAudioSenderFeedback> rtcp_feedback_; | 67 scoped_ptr<LocalRtcpAudioSenderFeedback> rtcp_feedback_; |
| 72 Rtcp rtcp_; | 68 Rtcp rtcp_; |
| 73 bool timers_initialized_; | 69 bool timers_initialized_; |
| 74 CastInitializationStatus cast_initialization_cb_; | 70 CastInitializationStatus cast_initialization_cb_; |
| 75 | 71 |
| 76 // NOTE: Weak pointers must be invalidated before all other member variables. | 72 // NOTE: Weak pointers must be invalidated before all other member variables. |
| 77 base::WeakPtrFactory<AudioSender> weak_factory_; | 73 base::WeakPtrFactory<AudioSender> weak_factory_; |
| 78 | 74 |
| 79 DISALLOW_COPY_AND_ASSIGN(AudioSender); | 75 DISALLOW_COPY_AND_ASSIGN(AudioSender); |
| 80 }; | 76 }; |
| 81 | 77 |
| 82 } // namespace cast | 78 } // namespace cast |
| 83 } // namespace media | 79 } // namespace media |
| 84 | 80 |
| 85 #endif // MEDIA_CAST_AUDIO_SENDER_H_ | 81 #endif // MEDIA_CAST_AUDIO_SENDER_H_ |
| OLD | NEW |