VirtualBox

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

Last change on this file since 25943 was 18882, checked in by vboxsync, 16 years ago

crOpenGL: exported the remaining Additions bits to OSE

  • Property svn:eol-style set to native
File size: 3.4 KB
Line 
1print """
2/** @file
3 * VBox OpenGL chromium functions header
4 */
5
6/*
7 * Copyright (C) 2009 Sun Microsystems, Inc.
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 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
18 * Clara, CA 95054 USA or visit http://www.sun.com if you need
19 * additional information or have any questions.
20 */
21"""
22# Copyright (c) 2001, Stanford University
23# All rights reserved.
24#
25# See the file LICENSE.txt for information on redistributing this software.
26
27import sys
28
29import apiutil
30
31apiutil.CopyrightC()
32
33print """
34/* DO NOT EDIT - THIS FILE GENERATED BY THE DD_gl.py SCRIPT */
35#ifndef __DD_GL_H__
36#define __DD_GL_H__
37
38#include "chromium.h"
39#include "cr_string.h"
40#include "cr_version.h"
41#include "stub.h"
42
43"""
44
45commoncall_special = [
46 "ArrayElement",
47 "Begin",
48 "CallList",
49 "CallLists",
50 "Color3f",
51 "Color3fv",
52 "Color4f",
53 "Color4fv",
54 "EdgeFlag",
55 "End",
56 "EvalCoord1f",
57 "EvalCoord1fv",
58 "EvalCoord2f",
59 "EvalCoord2fv",
60 "EvalPoint1",
61 "EvalPoint2",
62 "FogCoordfEXT",
63 "FogCoordfvEXT",
64 "Indexf",
65 "Indexfv",
66 "Materialfv",
67 "MultiTexCoord1fARB",
68 "MultiTexCoord1fvARB",
69 "MultiTexCoord2fARB",
70 "MultiTexCoord2fvARB",
71 "MultiTexCoord3fARB",
72 "MultiTexCoord3fvARB",
73 "MultiTexCoord4fARB",
74 "MultiTexCoord4fvARB",
75 "Normal3f",
76 "Normal3fv",
77 "SecondaryColor3fEXT",
78 "SecondaryColor3fvEXT",
79 "TexCoord1f",
80 "TexCoord1fv",
81 "TexCoord2f",
82 "TexCoord2fv",
83 "TexCoord3f",
84 "TexCoord3fv",
85 "TexCoord4f",
86 "TexCoord4fv",
87 "Vertex2f",
88 "Vertex2fv",
89 "Vertex3f",
90 "Vertex3fv",
91 "Vertex4f",
92 "Vertex4fv",
93 "VertexAttrib1fNV",
94 "VertexAttrib1fvNV",
95 "VertexAttrib2fNV",
96 "VertexAttrib2fvNV",
97 "VertexAttrib3fNV",
98 "VertexAttrib3fvNV",
99 "VertexAttrib4fNV",
100 "VertexAttrib4fvNV",
101 "VertexAttrib1fARB",
102 "VertexAttrib1fvARB",
103 "VertexAttrib2fARB",
104 "VertexAttrib2fvARB",
105 "VertexAttrib3fARB",
106 "VertexAttrib3fvARB",
107 "VertexAttrib4fARB",
108 "VertexAttrib4fvARB",
109 "EvalMesh1",
110 "EvalMesh2",
111 "Rectf",
112 "DrawArrays",
113 "DrawElements",
114 "DrawRangeElements"
115]
116
117# Extern-like declarations
118keys = apiutil.GetDispatchedFunctions(sys.argv[1]+"/APIspec.txt")
119
120for func_name in keys:
121 if "Chromium" == apiutil.Category(func_name):
122 continue
123 if func_name == "BoundsInfoCR":
124 continue
125
126 return_type = apiutil.ReturnType(func_name)
127 params = apiutil.Parameters(func_name)
128
129 if func_name in commoncall_special:
130 print "extern %s vboxDD_gl%s( %s );" % (return_type, func_name,
131 apiutil.MakeDeclarationString( params ))
132 else:
133 if apiutil.MakeDeclarationString(params)=="void":
134 print "extern %s vboxDD_gl%s( GLcontext *ctx );" % (return_type, func_name)
135 else:
136 print "extern %s vboxDD_gl%s( GLcontext *ctx, %s );" % (return_type, func_name,
137 apiutil.MakeDeclarationString( params ))
138
139print "#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