OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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/test/render_pass_test_utils.h" | 5 #include "cc/test/render_pass_test_utils.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "cc/quads/debug_border_draw_quad.h" | 10 #include "cc/quads/debug_border_draw_quad.h" |
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
279 false); | 279 false); |
280 | 280 |
281 ResourceId plane_resources[4]; | 281 ResourceId plane_resources[4]; |
282 for (int i = 0; i < 4; ++i) { | 282 for (int i = 0; i < 4; ++i) { |
283 plane_resources[i] = resource_provider->CreateResource( | 283 plane_resources[i] = resource_provider->CreateResource( |
284 gfx::Size(20, 12), ResourceProvider::TEXTURE_HINT_IMMUTABLE, | 284 gfx::Size(20, 12), ResourceProvider::TEXTURE_HINT_IMMUTABLE, |
285 resource_provider->best_texture_format()); | 285 resource_provider->best_texture_format()); |
286 resource_provider->AllocateForTesting(plane_resources[i]); | 286 resource_provider->AllocateForTesting(plane_resources[i]); |
287 } | 287 } |
288 YUVVideoDrawQuad::ColorSpace color_space = YUVVideoDrawQuad::REC_601; | 288 YUVVideoDrawQuad::ColorSpace color_space = YUVVideoDrawQuad::REC_601; |
| 289 |
289 YUVVideoDrawQuad* yuv_quad = | 290 YUVVideoDrawQuad* yuv_quad = |
290 to_pass->CreateAndAppendDrawQuad<YUVVideoDrawQuad>(); | 291 to_pass->CreateAndAppendDrawQuad<YUVVideoDrawQuad>(); |
291 yuv_quad->SetNew(shared_state2, rect, opaque_rect, visible_rect, | 292 yuv_quad->SetNew(shared_state2, rect, opaque_rect, visible_rect, |
292 gfx::RectF(.0f, .0f, 100.0f, 100.0f), | 293 gfx::RectF(.0f, .0f, 100.0f, 100.0f), |
293 gfx::RectF(.0f, .0f, 50.0f, 50.0f), gfx::Size(100, 100), | 294 gfx::RectF(.0f, .0f, 50.0f, 50.0f), gfx::Size(100, 100), |
294 gfx::Size(50, 50), plane_resources[0], plane_resources[1], | 295 gfx::Size(50, 50), plane_resources[0], plane_resources[1], |
295 plane_resources[2], plane_resources[3], color_space, 0.0, | 296 plane_resources[2], plane_resources[3], color_space, |
296 1.0, 8); | 297 gfx::ColorSpace::CreateJpeg(), 0.0, 1.0, 8); |
297 } | 298 } |
298 | 299 |
299 } // namespace cc | 300 } // namespace cc |
OLD | NEW |