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

Side by Side Diff: ui/gl/gl_implementation.cc

Issue 13886018: Add a factory and defines for native Linux surfaces. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: vsync provider, better transport_dib, etc. Created 7 years, 7 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 | Annotate | Revision Log
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 #include "ui/gl/gl_implementation.h" 5 #include "ui/gl/gl_implementation.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "base/at_exit.h" 10 #include "base/at_exit.h"
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 #if defined(OS_WIN) 69 #if defined(OS_WIN)
70 70
71 EGLApi* g_current_egl_context; 71 EGLApi* g_current_egl_context;
72 WGLApi* g_current_wgl_context; 72 WGLApi* g_current_wgl_context;
73 73
74 #elif defined(USE_X11) 74 #elif defined(USE_X11)
75 75
76 EGLApi* g_current_egl_context; 76 EGLApi* g_current_egl_context;
77 GLXApi* g_current_glx_context; 77 GLXApi* g_current_glx_context;
78 78
79 #elif defined(USE_OZONE)
80
81 EGLApi* g_current_egl_context;
82
79 #elif defined(OS_ANDROID) 83 #elif defined(OS_ANDROID)
80 84
81 EGLApi* g_current_egl_context; 85 EGLApi* g_current_egl_context;
82 86
83 #endif 87 #endif
84 88
85 GLImplementation GetNamedGLImplementation(const std::string& name) { 89 GLImplementation GetNamedGLImplementation(const std::string& name) {
86 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kGLImplementationNamePairs); ++i) { 90 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kGLImplementationNamePairs); ++i) {
87 if (name == kGLImplementationNamePairs[i].name) 91 if (name == kGLImplementationNamePairs[i].name)
88 return kGLImplementationNamePairs[i].implementation; 92 return kGLImplementationNamePairs[i].implementation;
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 if (!proc && g_get_proc_address) { 166 if (!proc && g_get_proc_address) {
163 proc = g_get_proc_address(name); 167 proc = g_get_proc_address(name);
164 if (proc) 168 if (proc)
165 return proc; 169 return proc;
166 } 170 }
167 171
168 return proc; 172 return proc;
169 } 173 }
170 174
171 } // namespace gfx 175 } // namespace gfx
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698