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" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 uint32 InsertSyncPoint() override; | 63 uint32 InsertSyncPoint() override; |
64 uint32 InsertFutureSyncPoint() override; | 64 uint32 InsertFutureSyncPoint() override; |
65 void RetireSyncPoint(uint32 sync_point) override; | 65 void RetireSyncPoint(uint32 sync_point) override; |
66 void SignalSyncPoint(uint32 sync_point, | 66 void SignalSyncPoint(uint32 sync_point, |
67 const base::Closure& callback) override; | 67 const base::Closure& callback) override; |
68 void SignalQuery(uint32 query, const base::Closure& callback) override; | 68 void SignalQuery(uint32 query, const base::Closure& callback) override; |
69 void SetSurfaceVisible(bool visible) override; | 69 void SetSurfaceVisible(bool visible) override; |
70 uint32 CreateStreamTexture(uint32 texture_id) override; | 70 uint32 CreateStreamTexture(uint32 texture_id) override; |
71 void SetLock(base::Lock*) override; | 71 void SetLock(base::Lock*) override; |
72 bool IsGpuChannelLost() override; | 72 bool IsGpuChannelLost() override; |
| 73 gpu::CommandBufferNamespace GetNamespaceID() const override; |
| 74 uint64_t GetCommandBufferID() const override; |
73 | 75 |
74 private: | 76 private: |
75 void PumpCommands(); | 77 void PumpCommands(); |
76 | 78 |
77 void OnResize(gfx::Size size, float scale_factor); | 79 void OnResize(gfx::Size size, float scale_factor); |
78 void OnUpdateVSyncParameters(const base::TimeTicks timebase, | 80 void OnUpdateVSyncParameters(const base::TimeTicks timebase, |
79 const base::TimeDelta interval); | 81 const base::TimeDelta interval); |
80 bool OnWaitSyncPoint(uint32_t sync_point); | 82 bool OnWaitSyncPoint(uint32_t sync_point); |
81 void OnParseError(); | 83 void OnParseError(); |
82 void OnContextLost(uint32_t reason); | 84 void OnContextLost(uint32_t reason); |
83 void OnSyncPointRetired(); | 85 void OnSyncPointRetired(); |
84 | 86 |
85 gfx::AcceleratedWidget widget_; | 87 gfx::AcceleratedWidget widget_; |
86 scoped_refptr<gles2::GpuState> gpu_state_; | 88 scoped_refptr<gles2::GpuState> gpu_state_; |
87 scoped_ptr<gpu::CommandBufferService> command_buffer_; | 89 scoped_ptr<gpu::CommandBufferService> command_buffer_; |
88 scoped_ptr<gpu::GpuScheduler> scheduler_; | 90 scoped_ptr<gpu::GpuScheduler> scheduler_; |
89 scoped_ptr<gpu::gles2::GLES2Decoder> decoder_; | 91 scoped_ptr<gpu::gles2::GLES2Decoder> decoder_; |
90 scoped_refptr<gfx::GLContext> context_; | 92 scoped_refptr<gfx::GLContext> context_; |
91 scoped_refptr<gfx::GLSurface> surface_; | 93 scoped_refptr<gfx::GLSurface> surface_; |
92 CommandBufferLocalClient* client_; | 94 CommandBufferLocalClient* client_; |
93 | 95 |
94 base::WeakPtrFactory<CommandBufferLocal> weak_factory_; | 96 base::WeakPtrFactory<CommandBufferLocal> weak_factory_; |
95 | 97 |
96 DISALLOW_COPY_AND_ASSIGN(CommandBufferLocal); | 98 DISALLOW_COPY_AND_ASSIGN(CommandBufferLocal); |
97 }; | 99 }; |
98 | 100 |
99 } // namespace gles2 | 101 } // namespace gles2 |
100 | 102 |
101 #endif // COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ | 103 #endif // COMPONENTS_MUS_GLES2_COMMAND_BUFFER_LOCAL_H_ |
OLD | NEW |