OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_GLES2_CONFORM_TEST_CONTEXT_H_ | 5 #ifndef GPU_GLES2_CONFORM_TEST_CONTEXT_H_ |
6 #define GPU_GLES2_CONFORM_TEST_CONTEXT_H_ | 6 #define GPU_GLES2_CONFORM_TEST_CONTEXT_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "gpu/command_buffer/client/gles2_cmd_helper.h" | 12 #include "gpu/command_buffer/client/gles2_cmd_helper.h" |
13 #include "gpu/command_buffer/client/gpu_control.h" | 13 #include "gpu/command_buffer/client/gpu_control.h" |
14 #include "gpu/command_buffer/service/command_buffer_service.h" | 14 #include "gpu/command_buffer/service/command_buffer_service.h" |
15 #include "gpu/command_buffer/service/command_executor.h" | 15 #include "gpu/command_buffer/service/command_executor.h" |
16 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" | 16 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
17 #include "gpu/command_buffer/service/gpu_preferences.h" | 17 #include "gpu/command_buffer/service/gpu_preferences.h" |
18 #include "gpu/config/gpu_driver_bug_workarounds.h" | 18 #include "gpu/config/gpu_driver_bug_workarounds.h" |
19 #include "ui/gfx/native_widget_types.h" | 19 #include "ui/gfx/native_widget_types.h" |
20 #include "ui/gl/gl_context.h" | 20 #include "ui/gl/gl_context.h" |
21 #include "ui/gl/gl_context.h" | 21 #include "ui/gl/gl_context.h" |
22 #include "ui/gl/gl_surface.h" | 22 #include "ui/gl/gl_surface.h" |
23 #include "ui/gl/gl_surface.h" | 23 #include "ui/gl/gl_surface.h" |
24 #include <EGL/egl.h> | 24 #include <EGL/egl.h> |
25 | 25 |
26 namespace gpu { | 26 namespace gpu { |
| 27 class ServiceDiscardableManager; |
27 class TransferBuffer; | 28 class TransferBuffer; |
28 | 29 |
29 namespace gles2 { | 30 namespace gles2 { |
30 class GLES2CmdHelper; | 31 class GLES2CmdHelper; |
31 class GLES2Interface; | 32 class GLES2Interface; |
32 } // namespace gles2 | 33 } // namespace gles2 |
33 } // namespace gpu | 34 } // namespace gpu |
34 | 35 |
35 namespace egl { | 36 namespace egl { |
36 class Display; | 37 class Display; |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
98 void MarkServiceContextLost(); | 99 void MarkServiceContextLost(); |
99 bool WasServiceContextLost() const; | 100 bool WasServiceContextLost() const; |
100 bool IsCompatibleSurface(Surface* surface) const; | 101 bool IsCompatibleSurface(Surface* surface) const; |
101 bool Flush(gl::GLSurface* gl_surface); | 102 bool Flush(gl::GLSurface* gl_surface); |
102 | 103 |
103 Display* display_; | 104 Display* display_; |
104 const Config* config_; | 105 const Config* config_; |
105 bool is_current_in_some_thread_; | 106 bool is_current_in_some_thread_; |
106 bool is_destroyed_; | 107 bool is_destroyed_; |
107 gpu::GpuPreferences gpu_preferences_; | 108 gpu::GpuPreferences gpu_preferences_; |
| 109 std::unique_ptr<gpu::ServiceDiscardableManager> discardable_manager_; |
108 const gpu::GpuDriverBugWorkarounds gpu_driver_bug_workarounds_; | 110 const gpu::GpuDriverBugWorkarounds gpu_driver_bug_workarounds_; |
109 std::unique_ptr<gpu::TransferBufferManager> transfer_buffer_manager_; | 111 std::unique_ptr<gpu::TransferBufferManager> transfer_buffer_manager_; |
110 std::unique_ptr<gpu::CommandBufferService> command_buffer_; | 112 std::unique_ptr<gpu::CommandBufferService> command_buffer_; |
111 std::unique_ptr<gpu::gles2::GLES2CmdHelper> gles2_cmd_helper_; | 113 std::unique_ptr<gpu::gles2::GLES2CmdHelper> gles2_cmd_helper_; |
112 std::unique_ptr<gpu::gles2::GLES2Decoder> decoder_; | 114 std::unique_ptr<gpu::gles2::GLES2Decoder> decoder_; |
113 std::unique_ptr<gpu::CommandExecutor> command_executor_; | 115 std::unique_ptr<gpu::CommandExecutor> command_executor_; |
114 std::unique_ptr<gpu::TransferBuffer> transfer_buffer_; | 116 std::unique_ptr<gpu::TransferBuffer> transfer_buffer_; |
115 | 117 |
116 scoped_refptr<gl::GLContext> gl_context_; | 118 scoped_refptr<gl::GLContext> gl_context_; |
117 | 119 |
118 std::unique_ptr<gpu::gles2::GLES2Interface> client_gl_context_; | 120 std::unique_ptr<gpu::gles2::GLES2Interface> client_gl_context_; |
119 DISALLOW_COPY_AND_ASSIGN(Context); | 121 DISALLOW_COPY_AND_ASSIGN(Context); |
120 }; | 122 }; |
121 | 123 |
122 } // namespace egl | 124 } // namespace egl |
123 | 125 |
124 #endif // GPU_GLES2_CONFORM_TEST_CONTEXT_H_ | 126 #endif // GPU_GLES2_CONFORM_TEST_CONTEXT_H_ |
OLD | NEW |