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

Side by Side Diff: cc/output/delegating_renderer_unittest.cc

Issue 13445009: cc: Move video upload to VideoResourceUpdater. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix software compositing Created 7 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 | Annotate | Revision Log
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 "cc/output/delegating_renderer.h" 5 #include "cc/output/delegating_renderer.h"
6 6
7 #include "cc/test/fake_output_surface.h" 7 #include "cc/test/fake_output_surface.h"
8 #include "cc/test/layer_tree_test.h" 8 #include "cc/test/layer_tree_test.h"
9 #include "cc/test/render_pass_test_common.h" 9 #include "cc/test/render_pass_test_common.h"
10 #include "cc/test/render_pass_test_utils.h" 10 #include "cc/test/render_pass_test_utils.h"
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 return true; 112 return true;
113 } 113 }
114 114
115 virtual void DrawLayersOnThread(LayerTreeHostImpl* host_impl) OVERRIDE { 115 virtual void DrawLayersOnThread(LayerTreeHostImpl* host_impl) OVERRIDE {
116 EXPECT_EQ(1u, output_surface_->num_sent_frames()); 116 EXPECT_EQ(1u, output_surface_->num_sent_frames());
117 117
118 const CompositorFrame& last_frame = output_surface_->last_sent_frame(); 118 const CompositorFrame& last_frame = output_surface_->last_sent_frame();
119 ASSERT_TRUE(last_frame.delegated_frame_data); 119 ASSERT_TRUE(last_frame.delegated_frame_data);
120 120
121 EXPECT_EQ(2u, last_frame.delegated_frame_data->render_pass_list.size()); 121 EXPECT_EQ(2u, last_frame.delegated_frame_data->render_pass_list.size());
122 // Each render pass has 7 resources in it. And the root render pass has a 122 // Each render pass has 9 resources in it. And the root render pass has a
123 // mask resource used when drawing the child render pass. The number 7 may 123 // mask resource used when drawing the child render pass. The number 9 may
124 // change if AppendOneOfEveryQuadType is updated, and the value here should 124 // change if AppendOneOfEveryQuadType() is updated, and the value here
125 // be updated accordingly. 125 // should be updated accordingly.
126 EXPECT_EQ( 126 EXPECT_EQ(
127 15u, last_frame.delegated_frame_data->resource_list.size()); 127 19u, last_frame.delegated_frame_data->resource_list.size());
128 128
129 EndTest(); 129 EndTest();
130 } 130 }
131 }; 131 };
132 132
133 SINGLE_AND_MULTI_THREAD_TEST_F(DelegatingRendererTestResources); 133 SINGLE_AND_MULTI_THREAD_TEST_F(DelegatingRendererTestResources);
134 134
135 } // namespace cc 135 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698