Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(205)

Side by Side Diff: gpu/skia_bindings/grcontext_for_gles2_interface.h

Issue 1880823004: Move skia related files from content/common/gpu/client to gpu/skia_bindings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « gpu/skia_bindings/BUILD.gn ('k') | gpu/skia_bindings/grcontext_for_gles2_interface.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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_COMMON_GPU_CLIENT_GRCONTEXT_FOR_GLES2_INTERFACE_H_ 5 #ifndef GPU_SKIA_BINDINGS_GRCONTEXT_FOR_GLES2_INTERFACE_H_
6 #define CONTENT_COMMON_GPU_CLIENT_GRCONTEXT_FOR_GLES2_INTERFACE_H_ 6 #define GPU_SKIA_BINDINGS_GRCONTEXT_FOR_GLES2_INTERFACE_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "third_party/skia/include/core/SkRefCnt.h" 9 #include "third_party/skia/include/core/SkRefCnt.h"
10 10
11 class GrContext; 11 class GrContext;
12 12
13 namespace gpu { 13 namespace gpu {
14 namespace gles2 { 14 namespace gles2 {
15 class GLES2Interface; 15 class GLES2Interface;
16 } 16 }
17 } 17 }
18 18
19 namespace content { 19 namespace skia_bindings {
20 20
21 // This class binds an offscreen GrContext to an offscreen context3d. The 21 // This class binds an offscreen GrContext to an offscreen context3d. The
22 // context3d is used by the GrContext so must be valid as long as this class 22 // context3d is used by the GrContext so must be valid as long as this class
23 // is alive. 23 // is alive.
24 class GrContextForGLES2Interface { 24 class GrContextForGLES2Interface {
25 public: 25 public:
26 explicit GrContextForGLES2Interface(gpu::gles2::GLES2Interface* gl); 26 explicit GrContextForGLES2Interface(gpu::gles2::GLES2Interface* gl);
27 virtual ~GrContextForGLES2Interface(); 27 virtual ~GrContextForGLES2Interface();
28 28
29 GrContext* get() { return gr_context_.get(); } 29 GrContext* get() { return gr_context_.get(); }
30 30
31 void OnLostContext(); 31 void OnLostContext();
32 void ResetContext(uint32_t state);
32 void FreeGpuResources(); 33 void FreeGpuResources();
33 34
34 private: 35 private:
35 sk_sp<class GrContext> gr_context_; 36 sk_sp<class GrContext> gr_context_;
36 37
37 DISALLOW_COPY_AND_ASSIGN(GrContextForGLES2Interface); 38 DISALLOW_COPY_AND_ASSIGN(GrContextForGLES2Interface);
38 }; 39 };
39 40
40 } // namespace content 41 } // namespace skia_bindings
41 42
42 #endif // CONTENT_COMMON_GPU_CLIENT_GRCONTEXT_FOR_GLES2_INTERFACE_H_ 43 #endif // GPU_SKIA_BINDINGS_GRCONTEXT_FOR_GLES2_INTERFACE_H_
OLDNEW
« no previous file with comments | « gpu/skia_bindings/BUILD.gn ('k') | gpu/skia_bindings/grcontext_for_gles2_interface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698