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

Side by Side Diff: content/browser/media/capture/video_capture_oracle_unittest.cc

Issue 667943003: Standardize usage of virtual/override/final in content/browser/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 "content/browser/media/capture/video_capture_oracle.h" 5 #include "content/browser/media/capture/video_capture_oracle.h"
6 6
7 #include <cstdlib> 7 #include <cstdlib>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 654 matching lines...) Expand 10 before | Expand all | Expand 10 after
665 : public AnimatedContentSamplerTest, 665 : public AnimatedContentSamplerTest,
666 public ::testing::WithParamInterface<Scenario> { 666 public ::testing::WithParamInterface<Scenario> {
667 public: 667 public:
668 AnimatedContentSamplerParameterizedTest() 668 AnimatedContentSamplerParameterizedTest()
669 : count_dropped_frames_(0), count_sampled_frames_(0) {} 669 : count_dropped_frames_(0), count_sampled_frames_(0) {}
670 virtual ~AnimatedContentSamplerParameterizedTest() {} 670 virtual ~AnimatedContentSamplerParameterizedTest() {}
671 671
672 protected: 672 protected:
673 typedef std::pair<gfx::Rect, base::TimeTicks> Event; 673 typedef std::pair<gfx::Rect, base::TimeTicks> Event;
674 674
675 virtual base::TimeDelta GetMinCapturePeriod() const override { 675 base::TimeDelta GetMinCapturePeriod() const override {
676 return GetParam().min_capture_period; 676 return GetParam().min_capture_period;
677 } 677 }
678 678
679 // Generate a sequence of events from the compositor pipeline. The event 679 // Generate a sequence of events from the compositor pipeline. The event
680 // times will all be at compositor vsync boundaries. 680 // times will all be at compositor vsync boundaries.
681 std::vector<Event> GenerateEventSequence(base::TimeTicks begin, 681 std::vector<Event> GenerateEventSequence(base::TimeTicks begin,
682 base::TimeTicks end, 682 base::TimeTicks end,
683 bool include_content_frame_events, 683 bool include_content_frame_events,
684 bool include_random_events) { 684 bool include_random_events) {
685 DCHECK(GetParam().content_period >= GetParam().vsync_interval); 685 DCHECK(GetParam().content_period >= GetParam().vsync_interval);
(...skipping 566 matching lines...) Expand 10 before | Expand all | Expand 10 after
1252 // |event_increment|. 1252 // |event_increment|.
1253 const base::TimeDelta max_acceptable_delta = (i % 100) == 78 ? 1253 const base::TimeDelta max_acceptable_delta = (i % 100) == 78 ?
1254 event_increment * 5 : event_increment * 2; 1254 event_increment * 5 : event_increment * 2;
1255 EXPECT_GE(max_acceptable_delta.InMicroseconds(), delta.InMicroseconds()); 1255 EXPECT_GE(max_acceptable_delta.InMicroseconds(), delta.InMicroseconds());
1256 } 1256 }
1257 last_frame_timestamp = frame_timestamp; 1257 last_frame_timestamp = frame_timestamp;
1258 } 1258 }
1259 } 1259 }
1260 1260
1261 } // namespace content 1261 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698