OLD | NEW |
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/layers/video_layer_impl.h" | 5 #include "cc/layers/video_layer_impl.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "cc/layers/video_frame_provider_client_impl.h" | 9 #include "cc/layers/video_frame_provider_client_impl.h" |
10 #include "cc/quads/io_surface_draw_quad.h" | 10 #include "cc/quads/io_surface_draw_quad.h" |
(...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 io_surface_quad->SetNew(shared_quad_state, | 294 io_surface_quad->SetNew(shared_quad_state, |
295 quad_rect, | 295 quad_rect, |
296 opaque_rect, | 296 opaque_rect, |
297 visible_quad_rect, | 297 visible_quad_rect, |
298 visible_rect.size(), | 298 visible_rect.size(), |
299 frame_resources_[0], | 299 frame_resources_[0], |
300 IOSurfaceDrawQuad::UNFLIPPED); | 300 IOSurfaceDrawQuad::UNFLIPPED); |
301 break; | 301 break; |
302 } | 302 } |
303 #if defined(VIDEO_HOLE) | 303 #if defined(VIDEO_HOLE) |
304 // This block and other blocks wrapped around #if defined(GOOGLE_TV) is not | 304 // This block and other blocks wrapped around #if defined(VIDEO_HOLE) is not |
305 // maintained by the general compositor team. Please contact the following | 305 // maintained by the general compositor team. Please contact the following |
306 // people instead: | 306 // people instead: |
307 // | 307 // |
308 // wonsik@chromium.org | 308 // wonsik@chromium.org |
309 // ycheo@chromium.org | 309 // lcwu@chromium.org |
310 case VideoFrameExternalResources::HOLE: { | 310 case VideoFrameExternalResources::HOLE: { |
311 DCHECK_EQ(frame_resources_.size(), 0u); | 311 DCHECK_EQ(frame_resources_.size(), 0u); |
312 SolidColorDrawQuad* solid_color_draw_quad = | 312 SolidColorDrawQuad* solid_color_draw_quad = |
313 render_pass->CreateAndAppendDrawQuad<SolidColorDrawQuad>(); | 313 render_pass->CreateAndAppendDrawQuad<SolidColorDrawQuad>(); |
314 | 314 |
315 // Create a solid color quad with transparent black and force no | 315 // Create a solid color quad with transparent black and force no |
316 // blending / no anti-aliasing. | 316 // blending / no anti-aliasing. |
317 gfx::Rect opaque_rect = quad_rect; | 317 gfx::Rect opaque_rect = quad_rect; |
318 solid_color_draw_quad->SetAll(shared_quad_state, | 318 solid_color_draw_quad->SetAll(shared_quad_state, |
319 quad_rect, | 319 quad_rect, |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
369 void VideoLayerImpl::SetProviderClientImpl( | 369 void VideoLayerImpl::SetProviderClientImpl( |
370 scoped_refptr<VideoFrameProviderClientImpl> provider_client_impl) { | 370 scoped_refptr<VideoFrameProviderClientImpl> provider_client_impl) { |
371 provider_client_impl_ = provider_client_impl; | 371 provider_client_impl_ = provider_client_impl; |
372 } | 372 } |
373 | 373 |
374 const char* VideoLayerImpl::LayerTypeAsString() const { | 374 const char* VideoLayerImpl::LayerTypeAsString() const { |
375 return "cc::VideoLayerImpl"; | 375 return "cc::VideoLayerImpl"; |
376 } | 376 } |
377 | 377 |
378 } // namespace cc | 378 } // namespace cc |
OLD | NEW |