Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(241)

Side by Side Diff: media/cast/test/receiver.cc

Issue 839983002: Adding "target_frame_rate" variable in lieu of "max_frame_rate" for FrameReceiverConfig (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « media/cast/test/end2end_unittest.cc ('k') | media/cast/test/utility/default_config.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <algorithm> 5 #include <algorithm>
6 #include <climits> 6 #include <climits>
7 #include <cstdarg> 7 #include <cstdarg>
8 #include <cstdio> 8 #include <cstdio>
9 #include <deque> 9 #include <deque>
10 #include <map> 10 #include <map>
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 int window_width, 187 int window_width,
188 int window_height) 188 int window_height)
189 : InProcessReceiver(cast_environment, 189 : InProcessReceiver(cast_environment,
190 local_end_point, 190 local_end_point,
191 remote_end_point, 191 remote_end_point,
192 audio_config, 192 audio_config,
193 video_config), 193 video_config),
194 // Maximum age is the duration of 3 video frames. 3 was chosen 194 // Maximum age is the duration of 3 video frames. 3 was chosen
195 // arbitrarily, but seems to work well. 195 // arbitrarily, but seems to work well.
196 max_frame_age_(base::TimeDelta::FromSeconds(1) * 3 / 196 max_frame_age_(base::TimeDelta::FromSeconds(1) * 3 /
197 video_config.max_frame_rate), 197 video_config.target_frame_rate),
198 #if defined(USE_X11) 198 #if defined(USE_X11)
199 render_(0, 0, window_width, window_height, "Cast_receiver"), 199 render_(0, 0, window_width, window_height, "Cast_receiver"),
200 #endif // defined(USE_X11) 200 #endif // defined(USE_X11)
201 num_video_frames_processed_(0), 201 num_video_frames_processed_(0),
202 num_audio_frames_processed_(0), 202 num_audio_frames_processed_(0),
203 currently_playing_audio_frame_start_(-1) {} 203 currently_playing_audio_frame_start_(-1) {}
204 204
205 ~NaivePlayer() override {} 205 ~NaivePlayer() override {}
206 206
207 void Start() override { 207 void Start() override {
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
591 audio_config, 591 audio_config,
592 video_config, 592 video_config,
593 window_width, 593 window_width,
594 window_height); 594 window_height);
595 player.Start(); 595 player.Start();
596 596
597 base::MessageLoop().Run(); // Run forever (i.e., until SIGTERM). 597 base::MessageLoop().Run(); // Run forever (i.e., until SIGTERM).
598 NOTREACHED(); 598 NOTREACHED();
599 return 0; 599 return 0;
600 } 600 }
OLDNEW
« no previous file with comments | « media/cast/test/end2end_unittest.cc ('k') | media/cast/test/utility/default_config.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698