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

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

Issue 1515433002: Replace uses of raw uint32's with a type-checked RtpTimeTicks data type. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Speculative workaround fix for win8_chromium_ng compile error. Created 4 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/sender/vp8_encoder.cc ('k') | media/cast/test/end2end_unittest.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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 // This program benchmarks the theoretical throughput of the cast library. 5 // This program benchmarks the theoretical throughput of the cast library.
6 // It runs using a fake clock, simulated network and fake codecs. This allows 6 // It runs using a fake clock, simulated network and fake codecs. This allows
7 // tests to run much faster than real time. 7 // tests to run much faster than real time.
8 // To run the program, run: 8 // To run the program, run:
9 // $ ./out/Release/cast_benchmarks | tee benchmarkoutput.asc 9 // $ ./out/Release/cast_benchmarks | tee benchmarkoutput.asc
10 // This may take a while, when it is done, you can view the data with 10 // This may take a while, when it is done, you can view the data with
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 if (ssrc == audio_ssrc_) { 121 if (ssrc == audio_ssrc_) {
122 *encoded_audio_bytes_ += frame.data.size(); 122 *encoded_audio_bytes_ += frame.data.size();
123 } else if (ssrc == video_ssrc_) { 123 } else if (ssrc == video_ssrc_) {
124 *encoded_video_bytes_ += frame.data.size(); 124 *encoded_video_bytes_ += frame.data.size();
125 } 125 }
126 transport_->InsertFrame(ssrc, frame); 126 transport_->InsertFrame(ssrc, frame);
127 } 127 }
128 128
129 void SendSenderReport(uint32_t ssrc, 129 void SendSenderReport(uint32_t ssrc,
130 base::TimeTicks current_time, 130 base::TimeTicks current_time,
131 uint32_t current_time_as_rtp_timestamp) final { 131 RtpTimeTicks current_time_as_rtp_timestamp) final {
132 transport_->SendSenderReport(ssrc, 132 transport_->SendSenderReport(ssrc,
133 current_time, 133 current_time,
134 current_time_as_rtp_timestamp); 134 current_time_as_rtp_timestamp);
135 } 135 }
136 136
137 void CancelSendingFrames(uint32_t ssrc, 137 void CancelSendingFrames(uint32_t ssrc,
138 const std::vector<uint32_t>& frame_ids) final { 138 const std::vector<uint32_t>& frame_ids) final {
139 transport_->CancelSendingFrames(ssrc, frame_ids); 139 transport_->CancelSendingFrames(ssrc, frame_ids);
140 } 140 }
141 141
(...skipping 575 matching lines...) Expand 10 before | Expand all | Expand 10 after
717 media::cast::CastBenchmark benchmark; 717 media::cast::CastBenchmark benchmark;
718 if (getenv("PROFILE_FILE")) { 718 if (getenv("PROFILE_FILE")) {
719 std::string profile_file(getenv("PROFILE_FILE")); 719 std::string profile_file(getenv("PROFILE_FILE"));
720 base::debug::StartProfiling(profile_file); 720 base::debug::StartProfiling(profile_file);
721 benchmark.Run(); 721 benchmark.Run();
722 base::debug::StopProfiling(); 722 base::debug::StopProfiling();
723 } else { 723 } else {
724 benchmark.Run(); 724 benchmark.Run();
725 } 725 }
726 } 726 }
OLDNEW
« no previous file with comments | « media/cast/sender/vp8_encoder.cc ('k') | media/cast/test/end2end_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698