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 891 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
902 'arguments': 'GLboolean enable', }, | 902 'arguments': 'GLboolean enable', }, |
903 ] | 903 ] |
904 | 904 |
905 EGL_FUNCTIONS = [ | 905 EGL_FUNCTIONS = [ |
906 { 'return_type': 'EGLint', | 906 { 'return_type': 'EGLint', |
907 'names': ['eglGetError'], | 907 'names': ['eglGetError'], |
908 'arguments': 'void', }, | 908 'arguments': 'void', }, |
909 { 'return_type': 'EGLDisplay', | 909 { 'return_type': 'EGLDisplay', |
910 'names': ['eglGetDisplay'], | 910 'names': ['eglGetDisplay'], |
911 'arguments': 'EGLNativeDisplayType display_id', }, | 911 'arguments': 'EGLNativeDisplayType display_id', }, |
| 912 { 'return_type': 'EGLDisplay', |
| 913 'known_as': 'eglGetPlatformDisplayEXT', |
| 914 'versions': [{ 'name': 'eglGetPlatformDisplayEXT', |
| 915 'extensions': ['EGL_ANGLE_platform_angle'] }], |
| 916 'arguments': 'EGLenum platform, void* native_display, ' |
| 917 'const EGLint* attrib_list', }, |
912 { 'return_type': 'EGLBoolean', | 918 { 'return_type': 'EGLBoolean', |
913 'names': ['eglInitialize'], | 919 'names': ['eglInitialize'], |
914 'arguments': 'EGLDisplay dpy, EGLint* major, EGLint* minor', }, | 920 'arguments': 'EGLDisplay dpy, EGLint* major, EGLint* minor', }, |
915 { 'return_type': 'EGLBoolean', | 921 { 'return_type': 'EGLBoolean', |
916 'names': ['eglTerminate'], | 922 'names': ['eglTerminate'], |
917 'arguments': 'EGLDisplay dpy', }, | 923 'arguments': 'EGLDisplay dpy', }, |
918 { 'return_type': 'const char*', | 924 { 'return_type': 'const char*', |
919 'names': ['eglQueryString'], | 925 'names': ['eglQueryString'], |
920 'arguments': 'EGLDisplay dpy, EGLint name', }, | 926 'arguments': 'EGLDisplay dpy, EGLint name', }, |
921 { 'return_type': 'EGLBoolean', | 927 { 'return_type': 'EGLBoolean', |
(...skipping 1141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2063 | 2069 |
2064 source_file = open(os.path.join(directory, 'gl_bindings_autogen_mock.cc'), | 2070 source_file = open(os.path.join(directory, 'gl_bindings_autogen_mock.cc'), |
2065 'wb') | 2071 'wb') |
2066 GenerateMockBindingsSource(source_file, GL_FUNCTIONS) | 2072 GenerateMockBindingsSource(source_file, GL_FUNCTIONS) |
2067 source_file.close() | 2073 source_file.close() |
2068 return 0 | 2074 return 0 |
2069 | 2075 |
2070 | 2076 |
2071 if __name__ == '__main__': | 2077 if __name__ == '__main__': |
2072 sys.exit(main(sys.argv[1:])) | 2078 sys.exit(main(sys.argv[1:])) |
OLD | NEW |