OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 """code generator for GL/GLES extension wrangler.""" | 6 """code generator for GL/GLES extension wrangler.""" |
7 | 7 |
8 import optparse | 8 import optparse |
9 import os | 9 import os |
10 import collections | 10 import collections |
(...skipping 873 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
884 'arguments': 'GLboolean enable', }, | 884 'arguments': 'GLboolean enable', }, |
885 ] | 885 ] |
886 | 886 |
887 EGL_FUNCTIONS = [ | 887 EGL_FUNCTIONS = [ |
888 { 'return_type': 'EGLint', | 888 { 'return_type': 'EGLint', |
889 'names': ['eglGetError'], | 889 'names': ['eglGetError'], |
890 'arguments': 'void', }, | 890 'arguments': 'void', }, |
891 { 'return_type': 'EGLDisplay', | 891 { 'return_type': 'EGLDisplay', |
892 'names': ['eglGetDisplay'], | 892 'names': ['eglGetDisplay'], |
893 'arguments': 'EGLNativeDisplayType display_id', }, | 893 'arguments': 'EGLNativeDisplayType display_id', }, |
| 894 { 'return_type': 'EGLDisplay', |
| 895 'known_as': 'eglGetPlatformDisplayEXT', |
| 896 'versions': [{ 'name': 'eglGetPlatformDisplayEXT', |
| 897 'extensions': ['EGL_ANGLE_platform_angle'] }], |
| 898 'arguments': 'EGLenum platform, void* native_display, ' |
| 899 'const EGLint* attrib_list', }, |
894 { 'return_type': 'EGLBoolean', | 900 { 'return_type': 'EGLBoolean', |
895 'names': ['eglInitialize'], | 901 'names': ['eglInitialize'], |
896 'arguments': 'EGLDisplay dpy, EGLint* major, EGLint* minor', }, | 902 'arguments': 'EGLDisplay dpy, EGLint* major, EGLint* minor', }, |
897 { 'return_type': 'EGLBoolean', | 903 { 'return_type': 'EGLBoolean', |
898 'names': ['eglTerminate'], | 904 'names': ['eglTerminate'], |
899 'arguments': 'EGLDisplay dpy', }, | 905 'arguments': 'EGLDisplay dpy', }, |
900 { 'return_type': 'const char*', | 906 { 'return_type': 'const char*', |
901 'names': ['eglQueryString'], | 907 'names': ['eglQueryString'], |
902 'arguments': 'EGLDisplay dpy, EGLint name', }, | 908 'arguments': 'EGLDisplay dpy, EGLint name', }, |
903 { 'return_type': 'EGLBoolean', | 909 { 'return_type': 'EGLBoolean', |
(...skipping 1141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2045 | 2051 |
2046 source_file = open(os.path.join(directory, 'gl_bindings_autogen_mock.cc'), | 2052 source_file = open(os.path.join(directory, 'gl_bindings_autogen_mock.cc'), |
2047 'wb') | 2053 'wb') |
2048 GenerateMockBindingsSource(source_file, GL_FUNCTIONS) | 2054 GenerateMockBindingsSource(source_file, GL_FUNCTIONS) |
2049 source_file.close() | 2055 source_file.close() |
2050 return 0 | 2056 return 0 |
2051 | 2057 |
2052 | 2058 |
2053 if __name__ == '__main__': | 2059 if __name__ == '__main__': |
2054 sys.exit(main(sys.argv[1:])) | 2060 sys.exit(main(sys.argv[1:])) |
OLD | NEW |