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

Side by Side Diff: cc/trees/layer_tree_host_impl_unittest.cc

Issue 1039533002: cc: Add support for sending BeginFrames for video. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@misc_video_refactoring
Patch Set: Fix comment. Created 5 years, 8 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 | « cc/trees/layer_tree_host_impl.cc ('k') | cc/trees/layer_tree_impl.h » ('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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 "cc/trees/layer_tree_host_impl.h" 5 #include "cc/trees/layer_tree_host_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 void NotifyReadyToDraw() override {} 137 void NotifyReadyToDraw() override {}
138 void SetNeedsRedrawOnImplThread() override { did_request_redraw_ = true; } 138 void SetNeedsRedrawOnImplThread() override { did_request_redraw_ = true; }
139 void SetNeedsRedrawRectOnImplThread(const gfx::Rect& damage_rect) override { 139 void SetNeedsRedrawRectOnImplThread(const gfx::Rect& damage_rect) override {
140 did_request_redraw_ = true; 140 did_request_redraw_ = true;
141 } 141 }
142 void SetNeedsAnimateOnImplThread() override { did_request_animate_ = true; } 142 void SetNeedsAnimateOnImplThread() override { did_request_animate_ = true; }
143 void SetNeedsPrepareTilesOnImplThread() override { 143 void SetNeedsPrepareTilesOnImplThread() override {
144 did_request_prepare_tiles_ = true; 144 did_request_prepare_tiles_ = true;
145 } 145 }
146 void SetNeedsCommitOnImplThread() override { did_request_commit_ = true; } 146 void SetNeedsCommitOnImplThread() override { did_request_commit_ = true; }
147 void SetVideoNeedsBeginFrames(bool needs_begin_frames) override {}
147 void PostAnimationEventsToMainThreadOnImplThread( 148 void PostAnimationEventsToMainThreadOnImplThread(
148 scoped_ptr<AnimationEventsVector> events) override {} 149 scoped_ptr<AnimationEventsVector> events) override {}
149 bool ReduceContentsTextureMemoryOnImplThread(size_t limit_bytes, 150 bool ReduceContentsTextureMemoryOnImplThread(size_t limit_bytes,
150 int priority_cutoff) override { 151 int priority_cutoff) override {
151 current_limit_bytes_ = limit_bytes; 152 current_limit_bytes_ = limit_bytes;
152 current_priority_cutoff_value_ = priority_cutoff; 153 current_priority_cutoff_value_ = priority_cutoff;
153 return reduce_memory_result_; 154 return reduce_memory_result_;
154 } 155 }
155 bool IsInsideDraw() override { return false; } 156 bool IsInsideDraw() override { return false; }
156 void RenewTreePriority() override {} 157 void RenewTreePriority() override {}
(...skipping 7727 matching lines...) Expand 10 before | Expand all | Expand 10 after
7884 EXPECT_FALSE(frame.render_passes_by_id[RenderPassId(2, 0)]); 7885 EXPECT_FALSE(frame.render_passes_by_id[RenderPassId(2, 0)]);
7885 EXPECT_FALSE(frame.render_passes_by_id[RenderPassId(3, 0)]); 7886 EXPECT_FALSE(frame.render_passes_by_id[RenderPassId(3, 0)]);
7886 EXPECT_EQ(1u, frame.render_passes.size()); 7887 EXPECT_EQ(1u, frame.render_passes.size());
7887 EXPECT_EQ(RenderPassId(1, 0), frame.render_passes[0]->id); 7888 EXPECT_EQ(RenderPassId(1, 0), frame.render_passes[0]->id);
7888 // The RenderPassDrawQuad should be removed from pass1. 7889 // The RenderPassDrawQuad should be removed from pass1.
7889 EXPECT_EQ(0u, pass1->quad_list.size()); 7890 EXPECT_EQ(0u, pass1->quad_list.size());
7890 } 7891 }
7891 7892
7892 } // namespace 7893 } // namespace
7893 } // namespace cc 7894 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | cc/trees/layer_tree_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698