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 COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ | 5 #ifndef COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ |
6 #define COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ | 6 #define COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "base/memory/weak_ptr.h" | 11 #include "base/memory/weak_ptr.h" |
12 #include "components/mus/gles2/gpu_state.h" | 12 #include "components/mus/gles2/gpu_state.h" |
13 #include "gpu/command_buffer/client/gpu_control.h" | 13 #include "gpu/command_buffer/client/gpu_control.h" |
14 #include "gpu/command_buffer/common/command_buffer.h" | 14 #include "gpu/command_buffer/common/command_buffer.h" |
15 #include "ui/gfx/geometry/size.h" | 15 #include "ui/gfx/geometry/size.h" |
16 #include "ui/gfx/gpu_memory_buffer.h" | 16 #include "ui/gfx/gpu_memory_buffer.h" |
17 #include "ui/gfx/native_widget_types.h" | 17 #include "ui/gfx/native_widget_types.h" |
18 | 18 |
19 namespace gpu { | 19 namespace gpu { |
20 class CommandBuffer; | 20 class CommandBuffer; |
21 class CommandBufferService; | 21 class CommandBufferService; |
22 class GpuScheduler; | 22 class GpuScheduler; |
23 class GpuControlService; | 23 class GpuControlService; |
| 24 class SyncPointClient; |
| 25 class SyncPointOrderData; |
24 namespace gles2 { | 26 namespace gles2 { |
25 class GLES2Decoder; | 27 class GLES2Decoder; |
26 } | 28 } |
27 } | 29 } |
28 | 30 |
29 namespace gfx { | 31 namespace gfx { |
30 class GLContext; | 32 class GLContext; |
31 class GLSurface; | 33 class GLSurface; |
32 } | 34 } |
33 | 35 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 void OnUpdateVSyncParameters(const base::TimeTicks timebase, | 88 void OnUpdateVSyncParameters(const base::TimeTicks timebase, |
87 const base::TimeDelta interval); | 89 const base::TimeDelta interval); |
88 bool OnWaitSyncPoint(uint32_t sync_point); | 90 bool OnWaitSyncPoint(uint32_t sync_point); |
89 void OnFenceSyncRelease(uint64_t release); | 91 void OnFenceSyncRelease(uint64_t release); |
90 bool OnWaitFenceSync(gpu::CommandBufferNamespace namespace_id, | 92 bool OnWaitFenceSync(gpu::CommandBufferNamespace namespace_id, |
91 uint64_t command_buffer_id, | 93 uint64_t command_buffer_id, |
92 uint64_t release); | 94 uint64_t release); |
93 void OnParseError(); | 95 void OnParseError(); |
94 void OnContextLost(uint32_t reason); | 96 void OnContextLost(uint32_t reason); |
95 | 97 |
| 98 const uint64_t command_buffer_id_; |
96 gfx::AcceleratedWidget widget_; | 99 gfx::AcceleratedWidget widget_; |
97 scoped_refptr<GpuState> gpu_state_; | 100 scoped_refptr<GpuState> gpu_state_; |
98 scoped_ptr<gpu::CommandBufferService> command_buffer_; | 101 scoped_ptr<gpu::CommandBufferService> command_buffer_; |
99 scoped_ptr<gpu::GpuScheduler> scheduler_; | 102 scoped_ptr<gpu::GpuScheduler> scheduler_; |
| 103 scoped_refptr<gpu::SyncPointOrderData> sync_point_order_data_; |
| 104 scoped_ptr<gpu::SyncPointClient> sync_point_client_; |
100 scoped_ptr<gpu::gles2::GLES2Decoder> decoder_; | 105 scoped_ptr<gpu::gles2::GLES2Decoder> decoder_; |
101 scoped_refptr<gfx::GLContext> context_; | 106 scoped_refptr<gfx::GLContext> context_; |
102 scoped_refptr<gfx::GLSurface> surface_; | 107 scoped_refptr<gfx::GLSurface> surface_; |
103 CommandBufferLocalClient* client_; | 108 CommandBufferLocalClient* client_; |
104 | 109 |
105 uint64_t next_fence_sync_release_; | 110 uint64_t next_fence_sync_release_; |
106 | 111 |
107 base::WeakPtrFactory<CommandBufferLocal> weak_factory_; | 112 base::WeakPtrFactory<CommandBufferLocal> weak_factory_; |
108 | 113 |
109 DISALLOW_COPY_AND_ASSIGN(CommandBufferLocal); | 114 DISALLOW_COPY_AND_ASSIGN(CommandBufferLocal); |
110 }; | 115 }; |
111 | 116 |
112 } // namespace mus | 117 } // namespace mus |
113 | 118 |
114 #endif // COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ | 119 #endif // COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ |
OLD | NEW |