OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_COMMAND_BUFFER_SERVICE_GL_CONTEXT_VIRTUAL_H_ | 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_GL_CONTEXT_VIRTUAL_H_ |
6 #define GPU_COMMAND_BUFFER_SERVICE_GL_CONTEXT_VIRTUAL_H_ | 6 #define GPU_COMMAND_BUFFER_SERVICE_GL_CONTEXT_VIRTUAL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include "base/callback_forward.h" | 9 #include "base/callback_forward.h" |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 22 matching lines...) Expand all Loading... |
33 | 33 |
34 // Implement GLContext. | 34 // Implement GLContext. |
35 bool Initialize(gl::GLSurface* compatible_surface, | 35 bool Initialize(gl::GLSurface* compatible_surface, |
36 const gl::GLContextAttribs& attribs) override; | 36 const gl::GLContextAttribs& attribs) override; |
37 bool MakeCurrent(gl::GLSurface* surface) override; | 37 bool MakeCurrent(gl::GLSurface* surface) override; |
38 void ReleaseCurrent(gl::GLSurface* surface) override; | 38 void ReleaseCurrent(gl::GLSurface* surface) override; |
39 bool IsCurrent(gl::GLSurface* surface) override; | 39 bool IsCurrent(gl::GLSurface* surface) override; |
40 void* GetHandle() override; | 40 void* GetHandle() override; |
41 scoped_refptr<gl::GPUTimingClient> CreateGPUTimingClient() override; | 41 scoped_refptr<gl::GPUTimingClient> CreateGPUTimingClient() override; |
42 void OnSetSwapInterval(int interval) override; | 42 void OnSetSwapInterval(int interval) override; |
| 43 std::string GetGLVersion() override; |
| 44 std::string GetGLRenderer() override; |
43 std::string GetExtensions() override; | 45 std::string GetExtensions() override; |
44 void SetSafeToForceGpuSwitch() override; | 46 void SetSafeToForceGpuSwitch() override; |
45 bool WasAllocatedUsingRobustnessExtension() override; | 47 bool WasAllocatedUsingRobustnessExtension() override; |
46 void SetUnbindFboOnMakeCurrent() override; | 48 void SetUnbindFboOnMakeCurrent() override; |
47 gl::YUVToRGBConverter* GetYUVToRGBConverter() override; | 49 gl::YUVToRGBConverter* GetYUVToRGBConverter() override; |
48 | 50 |
49 protected: | 51 protected: |
50 ~GLContextVirtual() override; | 52 ~GLContextVirtual() override; |
51 | 53 |
52 private: | 54 private: |
53 void Destroy(); | 55 void Destroy(); |
54 | 56 |
55 scoped_refptr<gl::GLContext> shared_context_; | 57 scoped_refptr<gl::GLContext> shared_context_; |
56 base::WeakPtr<gles2::GLES2Decoder> decoder_; | 58 base::WeakPtr<gles2::GLES2Decoder> decoder_; |
57 | 59 |
58 DISALLOW_COPY_AND_ASSIGN(GLContextVirtual); | 60 DISALLOW_COPY_AND_ASSIGN(GLContextVirtual); |
59 }; | 61 }; |
60 | 62 |
61 } // namespace gpu | 63 } // namespace gpu |
62 | 64 |
63 #endif // GPU_COMMAND_BUFFER_SERVICE_GL_CONTEXT_VIRTUAL_H_ | 65 #endif // GPU_COMMAND_BUFFER_SERVICE_GL_CONTEXT_VIRTUAL_H_ |
OLD | NEW |