| 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/compositor/gpu_process_transport_factory.h" | 5 #include "content/browser/compositor/gpu_process_transport_factory.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 234 | 234 |
| 235 scoped_ptr<BrowserCompositorOutputSurface> surface; | 235 scoped_ptr<BrowserCompositorOutputSurface> surface; |
| 236 #if defined(USE_OZONE) | 236 #if defined(USE_OZONE) |
| 237 if (ui::SurfaceFactoryOzone::GetInstance()->CanShowPrimaryPlaneAsOverlay()) { | 237 if (ui::SurfaceFactoryOzone::GetInstance()->CanShowPrimaryPlaneAsOverlay()) { |
| 238 surface.reset(new GpuSurfacelessBrowserCompositorOutputSurface( | 238 surface.reset(new GpuSurfacelessBrowserCompositorOutputSurface( |
| 239 context_provider, | 239 context_provider, |
| 240 per_compositor_data_[compositor]->surface_id, | 240 per_compositor_data_[compositor]->surface_id, |
| 241 &output_surface_map_, | 241 &output_surface_map_, |
| 242 compositor->vsync_manager(), | 242 compositor->vsync_manager(), |
| 243 CreateOverlayCandidateValidator(compositor->widget()), | 243 CreateOverlayCandidateValidator(compositor->widget()), |
| 244 GL_RGB8_OES)); | 244 GL_RGBX8_CHROMIUM)); |
| 245 } | 245 } |
| 246 #endif | 246 #endif |
| 247 if (!surface) | 247 if (!surface) |
| 248 surface.reset(new GpuBrowserCompositorOutputSurface( | 248 surface.reset(new GpuBrowserCompositorOutputSurface( |
| 249 context_provider, | 249 context_provider, |
| 250 per_compositor_data_[compositor]->surface_id, | 250 per_compositor_data_[compositor]->surface_id, |
| 251 &output_surface_map_, | 251 &output_surface_map_, |
| 252 compositor->vsync_manager(), | 252 compositor->vsync_manager(), |
| 253 CreateOverlayCandidateValidator(compositor->widget()))); | 253 CreateOverlayCandidateValidator(compositor->widget()))); |
| 254 | 254 |
| (...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 473 FOR_EACH_OBSERVER(ImageTransportFactoryObserver, | 473 FOR_EACH_OBSERVER(ImageTransportFactoryObserver, |
| 474 observer_list_, | 474 observer_list_, |
| 475 OnLostResources()); | 475 OnLostResources()); |
| 476 | 476 |
| 477 // Kill things that use the shared context before killing the shared context. | 477 // Kill things that use the shared context before killing the shared context. |
| 478 lost_gl_helper.reset(); | 478 lost_gl_helper.reset(); |
| 479 lost_shared_main_thread_contexts = NULL; | 479 lost_shared_main_thread_contexts = NULL; |
| 480 } | 480 } |
| 481 | 481 |
| 482 } // namespace content | 482 } // namespace content |
| OLD | NEW |