VirtualBox

source: vbox/trunk/src/VBox/Additions/common/crOpenGL/DD_glh.py@ 42500

Last change on this file since 42500 was 32394, checked in by vboxsync, 14 years ago

more branding and header fixes

  • Property svn:eol-style set to native
File size: 3.2 KB
Line 
1print """
2/** @file
3 * VBox OpenGL chromium functions header
4 */
5
6/*
7 * Copyright (C) 2009-2010 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17"""
18# Copyright (c) 2001, Stanford University
19# All rights reserved.
20#
21# See the file LICENSE.txt for information on redistributing this software.
22
23import sys
24
25import apiutil
26
27apiutil.CopyrightC()
28
29print """
30/* DO NOT EDIT - THIS FILE GENERATED BY THE DD_gl.py SCRIPT */
31#ifndef __DD_GL_H__
32#define __DD_GL_H__
33
34#include "chromium.h"
35#include "cr_string.h"
36#include "cr_version.h"
37#include "stub.h"
38
39"""
40
41commoncall_special = [
42 "ArrayElement",
43 "Begin",
44 "CallList",
45 "CallLists",
46 "Color3f",
47 "Color3fv",
48 "Color4f",
49 "Color4fv",
50 "EdgeFlag",
51 "End",
52 "EvalCoord1f",
53 "EvalCoord1fv",
54 "EvalCoord2f",
55 "EvalCoord2fv",
56 "EvalPoint1",
57 "EvalPoint2",
58 "FogCoordfEXT",
59 "FogCoordfvEXT",
60 "Indexf",
61 "Indexfv",
62 "Materialfv",
63 "MultiTexCoord1fARB",
64 "MultiTexCoord1fvARB",
65 "MultiTexCoord2fARB",
66 "MultiTexCoord2fvARB",
67 "MultiTexCoord3fARB",
68 "MultiTexCoord3fvARB",
69 "MultiTexCoord4fARB",
70 "MultiTexCoord4fvARB",
71 "Normal3f",
72 "Normal3fv",
73 "SecondaryColor3fEXT",
74 "SecondaryColor3fvEXT",
75 "TexCoord1f",
76 "TexCoord1fv",
77 "TexCoord2f",
78 "TexCoord2fv",
79 "TexCoord3f",
80 "TexCoord3fv",
81 "TexCoord4f",
82 "TexCoord4fv",
83 "Vertex2f",
84 "Vertex2fv",
85 "Vertex3f",
86 "Vertex3fv",
87 "Vertex4f",
88 "Vertex4fv",
89 "VertexAttrib1fNV",
90 "VertexAttrib1fvNV",
91 "VertexAttrib2fNV",
92 "VertexAttrib2fvNV",
93 "VertexAttrib3fNV",
94 "VertexAttrib3fvNV",
95 "VertexAttrib4fNV",
96 "VertexAttrib4fvNV",
97 "VertexAttrib1fARB",
98 "VertexAttrib1fvARB",
99 "VertexAttrib2fARB",
100 "VertexAttrib2fvARB",
101 "VertexAttrib3fARB",
102 "VertexAttrib3fvARB",
103 "VertexAttrib4fARB",
104 "VertexAttrib4fvARB",
105 "EvalMesh1",
106 "EvalMesh2",
107 "Rectf",
108 "DrawArrays",
109 "DrawElements",
110 "DrawRangeElements"
111]
112
113# Extern-like declarations
114keys = apiutil.GetDispatchedFunctions(sys.argv[1]+"/APIspec.txt")
115
116for func_name in keys:
117 if "Chromium" == apiutil.Category(func_name):
118 continue
119 if func_name == "BoundsInfoCR":
120 continue
121
122 return_type = apiutil.ReturnType(func_name)
123 params = apiutil.Parameters(func_name)
124
125 if func_name in commoncall_special:
126 print "extern %s vboxDD_gl%s( %s );" % (return_type, func_name,
127 apiutil.MakeDeclarationString( params ))
128 else:
129 if apiutil.MakeDeclarationString(params)=="void":
130 print "extern %s vboxDD_gl%s( GLcontext *ctx );" % (return_type, func_name)
131 else:
132 print "extern %s vboxDD_gl%s( GLcontext *ctx, %s );" % (return_type, func_name,
133 apiutil.MakeDeclarationString( params ))
134
135print "#endif /* __DD_GL_H__ */"
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette