diff options
Diffstat (limited to 'media/cast/test/receiver.cc')
-rw-r--r-- | media/cast/test/receiver.cc | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/media/cast/test/receiver.cc b/media/cast/test/receiver.cc index ed069b6..94eb86c 100644 --- a/media/cast/test/receiver.cc +++ b/media/cast/test/receiver.cc @@ -65,14 +65,14 @@ const char* kVideoWindowWidth = "1280"; const char* kVideoWindowHeight = "720"; #endif // defined(USE_X11) -void GetPorts(uint16* tx_port, uint16* rx_port) { +void GetPorts(uint16_t* tx_port, uint16_t* rx_port) { test::InputBuilder tx_input( "Enter send port.", DEFAULT_SEND_PORT, 1, 65535); - *tx_port = static_cast<uint16>(tx_input.GetIntInput()); + *tx_port = static_cast<uint16_t>(tx_input.GetIntInput()); test::InputBuilder rx_input( "Enter receive port.", DEFAULT_RECEIVE_PORT, 1, 65535); - *rx_port = static_cast<uint16>(rx_input.GetIntInput()); + *rx_port = static_cast<uint16_t>(rx_input.GetIntInput()); } std::string GetIpAddress(const std::string& display_text) { @@ -273,10 +273,10 @@ class NaivePlayer : public InProcessReceiver, << "Video: Discontinuity in received frames."; video_playout_queue_.push_back(std::make_pair(playout_time, video_frame)); ScheduleVideoPlayout(); - uint16 frame_no; + uint16_t frame_no; if (media::cast::test::DecodeBarcode(video_frame, &frame_no)) { video_play_times_.insert( - std::pair<uint16, base::TimeTicks>(frame_no, playout_time)); + std::pair<uint16_t, base::TimeTicks>(frame_no, playout_time)); } else { VLOG(2) << "Barcode decode failed!"; } @@ -289,7 +289,7 @@ class NaivePlayer : public InProcessReceiver, LOG_IF(WARNING, !is_continuous) << "Audio: Discontinuity in received frames."; base::AutoLock auto_lock(audio_lock_); - uint16 frame_no; + uint16_t frame_no; if (media::cast::DecodeTimestamp(audio_frame->channel(0), audio_frame->frames(), &frame_no)) { @@ -299,7 +299,7 @@ class NaivePlayer : public InProcessReceiver, // that we already missed the first one. if (is_continuous && frame_no == last_audio_frame_no_ + 1) { audio_play_times_.insert( - std::pair<uint16, base::TimeTicks>(frame_no, playout_time)); + std::pair<uint16_t, base::TimeTicks>(frame_no, playout_time)); } last_audio_frame_no_ = frame_no; } else { @@ -476,7 +476,7 @@ class NaivePlayer : public InProcessReceiver, audio_play_times_.size() > 30) { size_t num_events = 0; base::TimeDelta delta; - std::map<uint16, base::TimeTicks>::iterator audio_iter, video_iter; + std::map<uint16_t, base::TimeTicks>::iterator audio_iter, video_iter; for (video_iter = video_play_times_.begin(); video_iter != video_play_times_.end(); ++video_iter) { @@ -517,7 +517,7 @@ class NaivePlayer : public InProcessReceiver, VideoQueueEntry; std::deque<VideoQueueEntry> video_playout_queue_; base::TimeTicks last_popped_video_playout_time_; - int64 num_video_frames_processed_; + int64_t num_video_frames_processed_; base::OneShotTimer video_playout_timer_; @@ -526,15 +526,15 @@ class NaivePlayer : public InProcessReceiver, typedef std::pair<base::TimeTicks, AudioBus*> AudioQueueEntry; std::deque<AudioQueueEntry> audio_playout_queue_; base::TimeTicks last_popped_audio_playout_time_; - int64 num_audio_frames_processed_; + int64_t num_audio_frames_processed_; // These must only be used on the audio thread calling OnMoreData(). scoped_ptr<AudioBus> currently_playing_audio_frame_; int currently_playing_audio_frame_start_; - std::map<uint16, base::TimeTicks> audio_play_times_; - std::map<uint16, base::TimeTicks> video_play_times_; - int32 last_audio_frame_no_; + std::map<uint16_t, base::TimeTicks> audio_play_times_; + std::map<uint16_t, base::TimeTicks> video_play_times_; + int32_t last_audio_frame_no_; }; } // namespace cast @@ -560,7 +560,7 @@ int main(int argc, char** argv) { media::cast::GetVideoReceiverConfig(); // Determine local and remote endpoints. - uint16 remote_port, local_port; + uint16_t remote_port, local_port; media::cast::GetPorts(&remote_port, &local_port); if (!local_port) { LOG(ERROR) << "Invalid local port."; |