Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(62)

Side by Side Diff: gpu/command_buffer/build_gles2_cmd_buffer.py

Issue 2236083002: Move mojo/public/c/gpu/* to mojo/public/c/include. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: foo Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « examples/ui/tile/BUILD.gn ('k') | mojo/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 GLES2 command buffers.""" 6 """code generator for GLES2 command buffers."""
7 7
8 import itertools 8 import itertools
9 import os 9 import os
10 import os.path 10 import os.path
(...skipping 10424 matching lines...) Expand 10 before | Expand all | Expand 10 after
10435 camel_case_extension = ToCamelCase(extension) 10435 camel_case_extension = ToCamelCase(extension)
10436 thunks_type = "MojoGLES2Impl%sThunks" % camel_case_extension 10436 thunks_type = "MojoGLES2Impl%sThunks" % camel_case_extension
10437 fields = {"extension": extension, 10437 fields = {"extension": extension,
10438 "extension_lower": extension.lower(), 10438 "extension_lower": extension.lower(),
10439 "camel_case_extension": camel_case_extension, 10439 "camel_case_extension": camel_case_extension,
10440 "thunks_type": thunks_type} 10440 "thunks_type": thunks_type}
10441 body = """ 10441 body = """
10442 #include <stddef.h> 10442 #include <stddef.h>
10443 10443
10444 #define GL_GLEXT_PROTOTYPES 10444 #define GL_GLEXT_PROTOTYPES
10445 #include "mojo/public/c/gpu/GLES2/gl2extmojo.h" 10445 #include <GLES2/gl2extmojo.h>
10446 10446
10447 // Specifies the frozen API for the %(extension)s extension. 10447 // Specifies the frozen API for the %(extension)s extension.
10448 #pragma pack(push, 8) 10448 #pragma pack(push, 8)
10449 struct %(thunks_type)s { 10449 struct %(thunks_type)s {
10450 size_t size; // Should be set to sizeof(*this). 10450 size_t size; // Should be set to sizeof(*this).
10451 10451
10452 #define VISIT_GL_CALL(Function, ReturnType, PARAMETERS, ARGUMENTS) \ 10452 #define VISIT_GL_CALL(Function, ReturnType, PARAMETERS, ARGUMENTS) \
10453 ReturnType(GL_APIENTRY* Function) PARAMETERS; 10453 ReturnType(GL_APIENTRY* Function) PARAMETERS;
10454 #include "mojo/public/platform/native/gles2/call_visitor_%(extension_lower)s_aut ogen.h" 10454 #include "mojo/public/platform/native/gles2/call_visitor_%(extension_lower)s_aut ogen.h"
10455 #undef VISIT_GL_CALL 10455 #undef VISIT_GL_CALL
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
10631 Format(gen.generated_cpp_filenames) 10631 Format(gen.generated_cpp_filenames)
10632 10632
10633 if gen.errors > 0: 10633 if gen.errors > 0:
10634 print "%d errors" % gen.errors 10634 print "%d errors" % gen.errors
10635 return 1 10635 return 1
10636 return 0 10636 return 0
10637 10637
10638 10638
10639 if __name__ == '__main__': 10639 if __name__ == '__main__':
10640 sys.exit(main(sys.argv[1:])) 10640 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « examples/ui/tile/BUILD.gn ('k') | mojo/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698