| 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 |
| 52 // Initialize the preferred GL binding from the given list. The preferred GL | 55 // Initialize the preferred GL binding from the given list. The preferred GL |
| 53 // bindings depend on command line switches passed by the user and which GL | 56 // bindings depend on command line switches passed by the user and which GL |
| 54 // implementations are available and working on the system | 57 // implementations are available and working on the system |
| 55 bool InitializeBestGLBindings( | 58 bool InitializeBestGLBindings( |
| 56 const GLImplementation* allowed_implementations_begin, | 59 const GLImplementation* allowed_implementations_begin, |
| 57 const GLImplementation* allowed_implementations_end); | 60 const GLImplementation* allowed_implementations_end); |
| 58 | 61 |
| 59 // Add a native library to those searched for GL entry points. | 62 // Add a native library to those searched for GL entry points. |
| 60 void AddGLNativeLibrary(base::NativeLibrary library); | 63 void AddGLNativeLibrary(base::NativeLibrary library); |
| 61 | 64 |
| 62 // Set an additional function that will be called to find GL entry points. | 65 // Set an additional function that will be called to find GL entry points. |
| 63 void SetGLGetProcAddressProc(GLGetProcAddressProc proc); | 66 void SetGLGetProcAddressProc(GLGetProcAddressProc proc); |
| 64 | 67 |
| 65 // Find an entry point in the current GL implementation. | 68 // Find an entry point in the current GL implementation. |
| 66 void* GetGLProcAddress(const char* name); | 69 void* GetGLProcAddress(const char* name); |
| 67 | 70 |
| 68 } // namespace gfx | 71 } // namespace gfx |
| 69 | 72 |
| 70 #endif // APP_GFX_GL_GL_IMPLEMENTATION_H_ | 73 #endif // APP_GFX_GL_GL_IMPLEMENTATION_H_ |
| OLD | NEW |