| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #ifndef GPU_IPC_SERVICE_IMAGE_TRANSPORT_SURFACE_OVERLAY_MAC_H_ | 5 #ifndef GPU_IPC_SERVICE_IMAGE_TRANSPORT_SURFACE_OVERLAY_MAC_H_ |
| 6 #define GPU_IPC_SERVICE_IMAGE_TRANSPORT_SURFACE_OVERLAY_MAC_H_ | 6 #define GPU_IPC_SERVICE_IMAGE_TRANSPORT_SURFACE_OVERLAY_MAC_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 private: | 71 private: |
| 72 ~ImageTransportSurfaceOverlayMac() override; | 72 ~ImageTransportSurfaceOverlayMac() override; |
| 73 | 73 |
| 74 void SetLatencyInfo(const std::vector<ui::LatencyInfo>& latency_info); | 74 void SetLatencyInfo(const std::vector<ui::LatencyInfo>& latency_info); |
| 75 void BufferPresented(gpu::SurfaceHandle surface_handle, | 75 void BufferPresented(gpu::SurfaceHandle surface_handle, |
| 76 const base::TimeTicks& vsync_timebase, | 76 const base::TimeTicks& vsync_timebase, |
| 77 const base::TimeDelta& vsync_interval); | 77 const base::TimeDelta& vsync_interval); |
| 78 void SendAcceleratedSurfaceBuffersSwapped( | 78 void SendAcceleratedSurfaceBuffersSwapped( |
| 79 gpu::SurfaceHandle surface_handle, | 79 gpu::SurfaceHandle surface_handle, |
| 80 CAContextID ca_context_id, | 80 CAContextID ca_context_id, |
| 81 bool fullscreen_low_power_ca_context_valid, |
| 82 CAContextID fullscreen_low_power_ca_context_id, |
| 81 const gfx::ScopedRefCountedIOSurfaceMachPort& io_surface, | 83 const gfx::ScopedRefCountedIOSurfaceMachPort& io_surface, |
| 82 const gfx::Size& size, | 84 const gfx::Size& size, |
| 83 float scale_factor, | 85 float scale_factor, |
| 84 std::vector<ui::LatencyInfo> latency_info); | 86 std::vector<ui::LatencyInfo> latency_info); |
| 85 gfx::SwapResult SwapBuffersInternal(const gfx::Rect& pixel_damage_rect); | 87 gfx::SwapResult SwapBuffersInternal(const gfx::Rect& pixel_damage_rect); |
| 86 | 88 |
| 87 GpuChannelManager* manager_; | 89 GpuChannelManager* manager_; |
| 88 base::WeakPtr<GpuCommandBufferStub> stub_; | 90 base::WeakPtr<GpuCommandBufferStub> stub_; |
| 89 SurfaceHandle handle_; | 91 SurfaceHandle handle_; |
| 90 std::vector<ui::LatencyInfo> latency_info_; | 92 std::vector<ui::LatencyInfo> latency_info_; |
| 91 | 93 |
| 92 bool use_remote_layer_api_; | 94 bool use_remote_layer_api_; |
| 93 base::scoped_nsobject<CAContext> ca_context_; | 95 base::scoped_nsobject<CAContext> ca_context_; |
| 96 base::scoped_nsobject<CAContext> fullscreen_low_power_ca_context_; |
| 94 std::unique_ptr<ui::CALayerTreeCoordinator> ca_layer_tree_coordinator_; | 97 std::unique_ptr<ui::CALayerTreeCoordinator> ca_layer_tree_coordinator_; |
| 95 | 98 |
| 96 gfx::Size pixel_size_; | 99 gfx::Size pixel_size_; |
| 97 float scale_factor_; | 100 float scale_factor_; |
| 98 | 101 |
| 99 // The renderer ID that all contexts made current to this surface should be | 102 // The renderer ID that all contexts made current to this surface should be |
| 100 // targeting. | 103 // targeting. |
| 101 GLint gl_renderer_id_; | 104 GLint gl_renderer_id_; |
| 102 | 105 |
| 103 // The vsync information provided by the browser. | 106 // The vsync information provided by the browser. |
| 104 bool vsync_parameters_valid_; | 107 bool vsync_parameters_valid_; |
| 105 base::TimeTicks vsync_timebase_; | 108 base::TimeTicks vsync_timebase_; |
| 106 base::TimeDelta vsync_interval_; | 109 base::TimeDelta vsync_interval_; |
| 107 }; | 110 }; |
| 108 | 111 |
| 109 } // namespace gpu | 112 } // namespace gpu |
| 110 | 113 |
| 111 #endif // GPU_IPC_SERVICE_IMAGE_TRANSPORT_SURFACE_OVERLAY_MAC_H_ | 114 #endif // GPU_IPC_SERVICE_IMAGE_TRANSPORT_SURFACE_OVERLAY_MAC_H_ |
| OLD | NEW |