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

Side by Side Diff: ui/gl/gl_egl_api_implementation.h

Issue 1203513004: Respect the disabled extension list during binding initialization. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments Created 5 years, 5 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 | « ui/gl/gl_bindings_autogen_wgl.cc ('k') | ui/gl/gl_egl_api_implementation.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) 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 UI_GL_GL_EGL_API_IMPLEMENTATION_H_ 5 #ifndef UI_GL_GL_EGL_API_IMPLEMENTATION_H_
6 #define UI_GL_GL_EGL_API_IMPLEMENTATION_H_ 6 #define UI_GL_GL_EGL_API_IMPLEMENTATION_H_
7 7
8 #include <map>
8 #include <vector> 9 #include <vector>
9 10
10 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
11 #include "gl_bindings.h" 12 #include "gl_bindings.h"
12 #include "ui/gl/gl_export.h" 13 #include "ui/gl/gl_export.h"
13 14
14 namespace base { 15 namespace base {
15 class CommandLine; 16 class CommandLine;
16 } 17 }
17 namespace gfx { 18 namespace gfx {
(...skipping 21 matching lines...) Expand all
39 DriverEGL* driver_; 40 DriverEGL* driver_;
40 }; 41 };
41 42
42 class GL_EXPORT RealEGLApi : public EGLApiBase { 43 class GL_EXPORT RealEGLApi : public EGLApiBase {
43 public: 44 public:
44 RealEGLApi(); 45 RealEGLApi();
45 ~RealEGLApi() override; 46 ~RealEGLApi() override;
46 void Initialize(DriverEGL* driver); 47 void Initialize(DriverEGL* driver);
47 void InitializeWithCommandLine(DriverEGL* driver, 48 void InitializeWithCommandLine(DriverEGL* driver,
48 base::CommandLine* command_line); 49 base::CommandLine* command_line);
49 void InitializeFilteredExtensions();
50 50
51 const char* eglQueryStringFn(EGLDisplay dpy, EGLint name) override; 51 const char* eglQueryStringFn(EGLDisplay dpy, EGLint name) override;
52 52
53 private: 53 private:
54 // Filtered EGL_EXTENSIONS we return to eglQueryStringFn() calls. 54 // Filtered EGL_EXTENSIONS we return to eglQueryStringFn() calls.
55 std::vector<std::string> disabled_exts_; 55 std::vector<std::string> disabled_exts_;
56 std::string filtered_exts_; 56 std::map<EGLDisplay, std::string> filtered_exts_;
57 }; 57 };
58 58
59 59
60 // Inserts a TRACE for every EGL call. 60 // Inserts a TRACE for every EGL call.
61 class GL_EXPORT TraceEGLApi : public EGLApi { 61 class GL_EXPORT TraceEGLApi : public EGLApi {
62 public: 62 public:
63 TraceEGLApi(EGLApi* egl_api) : egl_api_(egl_api) { } 63 TraceEGLApi(EGLApi* egl_api) : egl_api_(egl_api) { }
64 ~TraceEGLApi() override; 64 ~TraceEGLApi() override;
65 65
66 // Include the auto-generated part of this class. We split this because 66 // Include the auto-generated part of this class. We split this because
67 // it means we can easily edit the non-auto generated parts right here in 67 // it means we can easily edit the non-auto generated parts right here in
68 // this file instead of having to edit some template or the code generator. 68 // this file instead of having to edit some template or the code generator.
69 #include "gl_bindings_api_autogen_egl.h" 69 #include "gl_bindings_api_autogen_egl.h"
70 70
71 private: 71 private:
72 EGLApi* egl_api_; 72 EGLApi* egl_api_;
73 }; 73 };
74 74
75 } // namespace gfx 75 } // namespace gfx
76 76
77 #endif // UI_GL_GL_EGL_API_IMPLEMENTATION_H_ 77 #endif // UI_GL_GL_EGL_API_IMPLEMENTATION_H_
78 78
79 79
80 80
OLDNEW
« no previous file with comments | « ui/gl/gl_bindings_autogen_wgl.cc ('k') | ui/gl/gl_egl_api_implementation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698