| 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 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 234 gfx::RectF(0, 0, 100, 100), gfx::Size(100, 100), false, | 234 gfx::RectF(0, 0, 100, 100), gfx::Size(100, 100), false, |
| 235 false); | 235 false); |
| 236 | 236 |
| 237 ResourceId plane_resources[4]; | 237 ResourceId plane_resources[4]; |
| 238 for (int i = 0; i < 4; ++i) { | 238 for (int i = 0; i < 4; ++i) { |
| 239 plane_resources[i] = resource_provider->CreateResource( | 239 plane_resources[i] = resource_provider->CreateResource( |
| 240 gfx::Size(20, 12), ResourceProvider::TEXTURE_HINT_IMMUTABLE, | 240 gfx::Size(20, 12), ResourceProvider::TEXTURE_HINT_IMMUTABLE, |
| 241 resource_provider->best_texture_format(), gfx::ColorSpace()); | 241 resource_provider->best_texture_format(), gfx::ColorSpace()); |
| 242 resource_provider->AllocateForTesting(plane_resources[i]); | 242 resource_provider->AllocateForTesting(plane_resources[i]); |
| 243 } | 243 } |
| 244 YUVVideoDrawQuad::ColorSpace color_space = YUVVideoDrawQuad::REC_601; | |
| 245 | 244 |
| 246 YUVVideoDrawQuad* yuv_quad = | 245 YUVVideoDrawQuad* yuv_quad = |
| 247 to_pass->CreateAndAppendDrawQuad<YUVVideoDrawQuad>(); | 246 to_pass->CreateAndAppendDrawQuad<YUVVideoDrawQuad>(); |
| 248 yuv_quad->SetNew(shared_state2, rect, opaque_rect, visible_rect, | 247 yuv_quad->SetNew(shared_state2, rect, opaque_rect, visible_rect, |
| 249 gfx::RectF(.0f, .0f, 100.0f, 100.0f), | 248 gfx::RectF(.0f, .0f, 100.0f, 100.0f), |
| 250 gfx::RectF(.0f, .0f, 50.0f, 50.0f), gfx::Size(100, 100), | 249 gfx::RectF(.0f, .0f, 50.0f, 50.0f), gfx::Size(100, 100), |
| 251 gfx::Size(50, 50), plane_resources[0], plane_resources[1], | 250 gfx::Size(50, 50), plane_resources[0], plane_resources[1], |
| 252 plane_resources[2], plane_resources[3], color_space, | 251 plane_resources[2], plane_resources[3], 0.0, 1.0, 8); |
| 253 gfx::ColorSpace::CreateJpeg(), 0.0, 1.0, 8); | |
| 254 } | 252 } |
| 255 | 253 |
| 256 } // namespace cc | 254 } // namespace cc |
| OLD | NEW |