| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 CONTENT_RENDERER_WEBGRAPHICSCONTEXT3D_PROVIDER_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_WEBGRAPHICSCONTEXT3D_PROVIDER_IMPL_H_ |
| 6 #define CONTENT_RENDERER_WEBGRAPHICSCONTEXT3D_PROVIDER_IMPL_H_ | 6 #define CONTENT_RENDERER_WEBGRAPHICSCONTEXT3D_PROVIDER_IMPL_H_ |
| 7 | 7 |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
| 11 #include "third_party/WebKit/public/platform/WebGraphicsContext3DProvider.h" | 11 #include "third_party/WebKit/public/platform/WebGraphicsContext3DProvider.h" |
| 12 | 12 |
| 13 namespace cc_blink { | 13 namespace cc_blink { |
| 14 class ContextProviderWebContext; | 14 class ContextProviderWebContext; |
| 15 } | 15 } |
| 16 | 16 |
| 17 namespace gpu { |
| 18 namespace gles2 { |
| 19 class GLES2Interface; |
| 20 } |
| 21 } |
| 22 |
| 17 namespace content { | 23 namespace content { |
| 18 | 24 |
| 19 class CONTENT_EXPORT WebGraphicsContext3DProviderImpl | 25 class CONTENT_EXPORT WebGraphicsContext3DProviderImpl |
| 20 : public NON_EXPORTED_BASE(blink::WebGraphicsContext3DProvider) { | 26 : public NON_EXPORTED_BASE(blink::WebGraphicsContext3DProvider) { |
| 21 public: | 27 public: |
| 22 explicit WebGraphicsContext3DProviderImpl( | 28 explicit WebGraphicsContext3DProviderImpl( |
| 23 scoped_refptr<cc_blink::ContextProviderWebContext> provider); | 29 scoped_refptr<cc_blink::ContextProviderWebContext> provider); |
| 24 ~WebGraphicsContext3DProviderImpl() override; | 30 ~WebGraphicsContext3DProviderImpl() override; |
| 25 | 31 |
| 26 // WebGraphicsContext3DProvider implementation. | 32 // WebGraphicsContext3DProvider implementation. |
| 27 blink::WebGraphicsContext3D* context3d() override; | 33 blink::WebGraphicsContext3D* context3d() override; |
| 28 GrContext* grContext() override; | 34 GrContext* grContext() override; |
| 35 gpu::gles2::GLES2Interface* getGLInterface() override; |
| 29 | 36 |
| 30 private: | 37 private: |
| 31 scoped_refptr<cc_blink::ContextProviderWebContext> provider_; | 38 scoped_refptr<cc_blink::ContextProviderWebContext> provider_; |
| 32 }; | 39 }; |
| 33 | 40 |
| 34 } // namespace content | 41 } // namespace content |
| 35 | 42 |
| 36 #endif // CONTENT_RENDERER_WEBGRAPHICSCONTEXT3D_PROVIDER_IMPL_H_ | 43 #endif // CONTENT_RENDERER_WEBGRAPHICSCONTEXT3D_PROVIDER_IMPL_H_ |
| OLD | NEW |