OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # | 2 # |
3 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | 3 # Copyright (c) 2011 The Chromium Authors. All rights reserved. |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 | 6 |
7 """code generator for GL/GLES extension wrangler.""" | 7 """code generator for GL/GLES extension wrangler.""" |
8 | 8 |
9 import os | 9 import os |
10 import re | 10 import re |
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
368 ['BOOL', ['wglDestroyPbufferARB'], 'HPBUFFERARB hPbuffer'], | 368 ['BOOL', ['wglDestroyPbufferARB'], 'HPBUFFERARB hPbuffer'], |
369 ['BOOL', ['wglQueryPbufferARB'], | 369 ['BOOL', ['wglQueryPbufferARB'], |
370 'HPBUFFERARB hPbuffer, int iAttribute, int* piValue'], | 370 'HPBUFFERARB hPbuffer, int iAttribute, int* piValue'], |
371 ] | 371 ] |
372 | 372 |
373 GLX_FUNCTIONS = [ | 373 GLX_FUNCTIONS = [ |
374 ['XVisualInfo*', ['glXChooseVisual'], | 374 ['XVisualInfo*', ['glXChooseVisual'], |
375 'Display* dpy, int screen, int* attribList'], | 375 'Display* dpy, int screen, int* attribList'], |
376 ['GLXContext', ['glXCreateContext'], | 376 ['GLXContext', ['glXCreateContext'], |
377 'Display* dpy, XVisualInfo* vis, GLXContext shareList, int direct'], | 377 'Display* dpy, XVisualInfo* vis, GLXContext shareList, int direct'], |
| 378 ['void', ['glXBindTexImageEXT'], |
| 379 'Display* dpy, GLXDrawable drawable, int buffer, int* attribList'], |
| 380 ['void', ['glXReleaseTexImageEXT'], |
| 381 'Display* dpy, GLXDrawable drawable, int buffer'], |
378 ['void', ['glXDestroyContext'], 'Display* dpy, GLXContext ctx'], | 382 ['void', ['glXDestroyContext'], 'Display* dpy, GLXContext ctx'], |
379 ['int', ['glXMakeCurrent'], | 383 ['int', ['glXMakeCurrent'], |
380 'Display* dpy, GLXDrawable drawable, GLXContext ctx'], | 384 'Display* dpy, GLXDrawable drawable, GLXContext ctx'], |
381 ['void', ['glXCopyContext'], | 385 ['void', ['glXCopyContext'], |
382 'Display* dpy, GLXContext src, GLXContext dst, unsigned long mask'], | 386 'Display* dpy, GLXContext src, GLXContext dst, unsigned long mask'], |
383 ['void', ['glXSwapBuffers'], 'Display* dpy, GLXDrawable drawable'], | 387 ['void', ['glXSwapBuffers'], 'Display* dpy, GLXDrawable drawable'], |
384 ['GLXPixmap', ['glXCreateGLXPixmap'], | 388 ['GLXPixmap', ['glXCreateGLXPixmap'], |
385 'Display* dpy, XVisualInfo* visual, Pixmap pixmap'], | 389 'Display* dpy, XVisualInfo* visual, Pixmap pixmap'], |
386 ['void', ['glXDestroyGLXPixmap'], 'Display* dpy, GLXPixmap pixmap'], | 390 ['void', ['glXDestroyGLXPixmap'], 'Display* dpy, GLXPixmap pixmap'], |
387 ['int', ['glXQueryExtension'], 'Display* dpy, int* errorb, int* event'], | 391 ['int', ['glXQueryExtension'], 'Display* dpy, int* errorb, int* event'], |
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
652 GenerateSource(source_file, functions, set_name) | 656 GenerateSource(source_file, functions, set_name) |
653 source_file.close() | 657 source_file.close() |
654 | 658 |
655 source_file = open(os.path.join(dir, 'gl_bindings_autogen_mock.cc'), 'wb') | 659 source_file = open(os.path.join(dir, 'gl_bindings_autogen_mock.cc'), 'wb') |
656 GenerateMockSource(source_file, GL_FUNCTIONS) | 660 GenerateMockSource(source_file, GL_FUNCTIONS) |
657 source_file.close() | 661 source_file.close() |
658 | 662 |
659 | 663 |
660 if __name__ == '__main__': | 664 if __name__ == '__main__': |
661 main(sys.argv[1:]) | 665 main(sys.argv[1:]) |
OLD | NEW |