| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "content/browser/android/in_process/synchronous_compositor_factory_impl
.h" | 5 #include "content/browser/android/in_process/synchronous_compositor_factory_impl
.h" |
| 6 | 6 |
| 7 #include "content/browser/android/in_process/synchronous_compositor_output_surfa
ce.h" | 7 #include "content/browser/android/in_process/synchronous_compositor_output_surfa
ce.h" |
| 8 #include "content/public/browser/browser_thread.h" | 8 #include "content/public/browser/browser_thread.h" |
| 9 #include "content/renderer/gpu/frame_swap_message_queue.h" | 9 #include "content/renderer/gpu/frame_swap_message_queue.h" |
| 10 #include "gpu/command_buffer/client/gl_in_process_context.h" | 10 #include "gpu/command_buffer/client/gl_in_process_context.h" |
| (...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 209 SynchronousCompositorFactoryImpl::CreateStreamTextureFactory(int frame_id) { | 209 SynchronousCompositorFactoryImpl::CreateStreamTextureFactory(int frame_id) { |
| 210 scoped_refptr<StreamTextureFactorySynchronousImpl> factory( | 210 scoped_refptr<StreamTextureFactorySynchronousImpl> factory( |
| 211 StreamTextureFactorySynchronousImpl::Create( | 211 StreamTextureFactorySynchronousImpl::Create( |
| 212 base::Bind( | 212 base::Bind( |
| 213 &SynchronousCompositorFactoryImpl::TryCreateStreamTextureFactory, | 213 &SynchronousCompositorFactoryImpl::TryCreateStreamTextureFactory, |
| 214 base::Unretained(this)), | 214 base::Unretained(this)), |
| 215 frame_id)); | 215 frame_id)); |
| 216 return factory; | 216 return factory; |
| 217 } | 217 } |
| 218 | 218 |
| 219 blink::WebGraphicsContext3D* | 219 webkit::gpu::WebGraphicsContext3DImpl* |
| 220 SynchronousCompositorFactoryImpl::CreateOffscreenGraphicsContext3D( | 220 SynchronousCompositorFactoryImpl::CreateOffscreenGraphicsContext3D( |
| 221 const blink::WebGraphicsContext3D::Attributes& attributes) { | 221 const blink::WebGraphicsContext3D::Attributes& attributes) { |
| 222 return WrapContextWithAttributes(CreateOffscreenContext(attributes), | 222 return WrapContextWithAttributes(CreateOffscreenContext(attributes), |
| 223 attributes).release(); | 223 attributes).release(); |
| 224 } | 224 } |
| 225 | 225 |
| 226 void SynchronousCompositorFactoryImpl::CompositorInitializedHardwareDraw() { | 226 void SynchronousCompositorFactoryImpl::CompositorInitializedHardwareDraw() { |
| 227 base::AutoLock lock(num_hardware_compositor_lock_); | 227 base::AutoLock lock(num_hardware_compositor_lock_); |
| 228 num_hardware_compositors_++; | 228 num_hardware_compositors_++; |
| 229 } | 229 } |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 267 DCHECK(!service_); | 267 DCHECK(!service_); |
| 268 service_ = service; | 268 service_ = service; |
| 269 } | 269 } |
| 270 | 270 |
| 271 void SynchronousCompositorFactoryImpl::SetRecordFullDocument( | 271 void SynchronousCompositorFactoryImpl::SetRecordFullDocument( |
| 272 bool record_full_document) { | 272 bool record_full_document) { |
| 273 record_full_layer_ = record_full_document; | 273 record_full_layer_ = record_full_document; |
| 274 } | 274 } |
| 275 | 275 |
| 276 } // namespace content | 276 } // namespace content |
| OLD | NEW |