OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 APP_GFX_GL_GL_IMPLEMENTATION_H_ | 5 #ifndef APP_GFX_GL_GL_IMPLEMENTATION_H_ |
6 #define APP_GFX_GL_GL_IMPLEMENTATION_H_ | 6 #define APP_GFX_GL_GL_IMPLEMENTATION_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 | 42 |
43 // Set the current GL implementation. | 43 // Set the current GL implementation. |
44 void SetGLImplementation(GLImplementation implementation); | 44 void SetGLImplementation(GLImplementation implementation); |
45 | 45 |
46 // Get the current GL implementation. | 46 // Get the current GL implementation. |
47 GLImplementation GetGLImplementation(); | 47 GLImplementation GetGLImplementation(); |
48 | 48 |
49 // Get the GL implementation with a given name. | 49 // Get the GL implementation with a given name. |
50 GLImplementation GetNamedGLImplementation(const std::wstring& name); | 50 GLImplementation GetNamedGLImplementation(const std::wstring& name); |
51 | 51 |
52 // Get the name of a GL implementation. | |
53 const char* GetGLImplementationName(GLImplementation implementation); | |
54 | |
55 // Initialize the preferred GL binding from the given list. The preferred GL | 52 // Initialize the preferred GL binding from the given list. The preferred GL |
56 // bindings depend on command line switches passed by the user and which GL | 53 // bindings depend on command line switches passed by the user and which GL |
57 // implementations are available and working on the system | 54 // implementations are available and working on the system |
58 bool InitializeBestGLBindings( | 55 bool InitializeBestGLBindings( |
59 const GLImplementation* allowed_implementations_begin, | 56 const GLImplementation* allowed_implementations_begin, |
60 const GLImplementation* allowed_implementations_end); | 57 const GLImplementation* allowed_implementations_end); |
61 | 58 |
62 // Add a native library to those searched for GL entry points. | 59 // Add a native library to those searched for GL entry points. |
63 void AddGLNativeLibrary(base::NativeLibrary library); | 60 void AddGLNativeLibrary(base::NativeLibrary library); |
64 | 61 |
65 // Set an additional function that will be called to find GL entry points. | 62 // Set an additional function that will be called to find GL entry points. |
66 void SetGLGetProcAddressProc(GLGetProcAddressProc proc); | 63 void SetGLGetProcAddressProc(GLGetProcAddressProc proc); |
67 | 64 |
68 // Find an entry point in the current GL implementation. | 65 // Find an entry point in the current GL implementation. |
69 void* GetGLProcAddress(const char* name); | 66 void* GetGLProcAddress(const char* name); |
70 | 67 |
71 } // namespace gfx | 68 } // namespace gfx |
72 | 69 |
73 #endif // APP_GFX_GL_GL_IMPLEMENTATION_H_ | 70 #endif // APP_GFX_GL_GL_IMPLEMENTATION_H_ |
OLD | NEW |