3f4a9cefed4181974063581b9ebe81e9f7c50953
[mesa.git] / src / mesa / main / vtxfmt_tmp.h
1
2 /*
3 * Mesa 3-D graphics library
4 * Version: 4.1
5 *
6 * Copyright (C) 1999-2002 Brian Paul All Rights Reserved.
7 *
8 * Permission is hereby granted, free of charge, to any person obtaining a
9 * copy of this software and associated documentation files (the "Software"),
10 * to deal in the Software without restriction, including without limitation
11 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
12 * and/or sell copies of the Software, and to permit persons to whom the
13 * Software is furnished to do so, subject to the following conditions:
14 *
15 * The above copyright notice and this permission notice shall be included
16 * in all copies or substantial portions of the Software.
17 *
18 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
19 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21 * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
22 * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
23 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
24 *
25 * Authors:
26 * Gareth Hughes
27 */
28
29 #ifndef PRE_LOOPBACK
30 #define PRE_LOOPBACK( FUNC )
31 #endif
32
33 static void TAG(ArrayElement)( GLint i )
34 {
35 PRE_LOOPBACK( ArrayElement );
36 _glapi_Dispatch->ArrayElement( i );
37 }
38
39 static void TAG(Color3f)( GLfloat r, GLfloat g, GLfloat b )
40 {
41 PRE_LOOPBACK( Color3f );
42 _glapi_Dispatch->Color3f( r, g, b );
43 }
44
45 static void TAG(Color3fv)( const GLfloat *v )
46 {
47 PRE_LOOPBACK( Color3fv );
48 _glapi_Dispatch->Color3fv( v );
49 }
50
51 static void TAG(Color3ub)( GLubyte r, GLubyte g, GLubyte b )
52 {
53 PRE_LOOPBACK( Color3ub );
54 _glapi_Dispatch->Color3ub( r, g, b );
55 }
56
57 static void TAG(Color3ubv)( const GLubyte *v )
58 {
59 PRE_LOOPBACK( Color3ubv );
60 _glapi_Dispatch->Color3ubv( v );
61 }
62
63 static void TAG(Color4f)( GLfloat r, GLfloat g, GLfloat b, GLfloat a )
64 {
65 PRE_LOOPBACK( Color4f );
66 _glapi_Dispatch->Color4f( r, g, b, a );
67 }
68
69 static void TAG(Color4fv)( const GLfloat *v )
70 {
71 PRE_LOOPBACK( Color4fv );
72 _glapi_Dispatch->Color4fv( v );
73 }
74
75 static void TAG(Color4ub)( GLubyte r, GLubyte g, GLubyte b, GLubyte a )
76 {
77 PRE_LOOPBACK( Color4ub );
78 _glapi_Dispatch->Color4ub( r, g, b, a );
79 }
80
81 static void TAG(Color4ubv)( const GLubyte *v )
82 {
83 PRE_LOOPBACK( Color4ubv );
84 _glapi_Dispatch->Color4ubv( v );
85 }
86
87 static void TAG(EdgeFlag)( GLboolean e )
88 {
89 PRE_LOOPBACK( EdgeFlag );
90 _glapi_Dispatch->EdgeFlag( e );
91 }
92
93 static void TAG(EdgeFlagv)( const GLboolean *v )
94 {
95 PRE_LOOPBACK( EdgeFlagv );
96 _glapi_Dispatch->EdgeFlagv( v );
97 }
98
99 static void TAG(EvalCoord1f)( GLfloat s )
100 {
101 PRE_LOOPBACK( EvalCoord1f );
102 _glapi_Dispatch->EvalCoord1f( s );
103 }
104
105 static void TAG(EvalCoord1fv)( const GLfloat *v )
106 {
107 PRE_LOOPBACK( EvalCoord1fv );
108 _glapi_Dispatch->EvalCoord1fv( v );
109 }
110
111 static void TAG(EvalCoord2f)( GLfloat s, GLfloat t )
112 {
113 PRE_LOOPBACK( EvalCoord2f );
114 _glapi_Dispatch->EvalCoord2f( s, t );
115 }
116
117 static void TAG(EvalCoord2fv)( const GLfloat *v )
118 {
119 PRE_LOOPBACK( EvalCoord2fv );
120 _glapi_Dispatch->EvalCoord2fv( v );
121 }
122
123 static void TAG(EvalPoint1)( GLint i )
124 {
125 PRE_LOOPBACK( EvalPoint1 );
126 _glapi_Dispatch->EvalPoint1( i );
127 }
128
129 static void TAG(EvalPoint2)( GLint i, GLint j )
130 {
131 PRE_LOOPBACK( EvalPoint2 );
132 _glapi_Dispatch->EvalPoint2( i, j );
133 }
134
135 static void TAG(FogCoordfEXT)( GLfloat f )
136 {
137 PRE_LOOPBACK( FogCoordfEXT );
138 _glapi_Dispatch->FogCoordfEXT( f );
139 }
140
141 static void TAG(FogCoordfvEXT)( const GLfloat *v )
142 {
143 PRE_LOOPBACK( FogCoordfvEXT );
144 _glapi_Dispatch->FogCoordfvEXT( v );
145 }
146
147 static void TAG(Indexi)( GLint i )
148 {
149 PRE_LOOPBACK( Indexi );
150 _glapi_Dispatch->Indexi( i );
151 }
152
153 static void TAG(Indexiv)( const GLint *v )
154 {
155 PRE_LOOPBACK( Indexiv );
156 _glapi_Dispatch->Indexiv( v );
157 }
158
159 static void TAG(Materialfv)( GLenum face, GLenum pname, const GLfloat *v )
160 {
161 PRE_LOOPBACK( Materialfv );
162 _glapi_Dispatch->Materialfv( face, pname, v );
163 }
164
165 static void TAG(MultiTexCoord1fARB)( GLenum target, GLfloat a )
166 {
167 PRE_LOOPBACK( MultiTexCoord1fARB );
168 _glapi_Dispatch->MultiTexCoord1fARB( target, a );
169 }
170
171 static void TAG(MultiTexCoord1fvARB)( GLenum target, const GLfloat *tc )
172 {
173 PRE_LOOPBACK( MultiTexCoord1fvARB );
174 _glapi_Dispatch->MultiTexCoord1fvARB( target, tc );
175 }
176
177 static void TAG(MultiTexCoord2fARB)( GLenum target, GLfloat s, GLfloat t )
178 {
179 PRE_LOOPBACK( MultiTexCoord2fARB );
180 _glapi_Dispatch->MultiTexCoord2fARB( target, s, t );
181 }
182
183 static void TAG(MultiTexCoord2fvARB)( GLenum target, const GLfloat *tc )
184 {
185 PRE_LOOPBACK( MultiTexCoord2fvARB );
186 _glapi_Dispatch->MultiTexCoord2fvARB( target, tc );
187 }
188
189 static void TAG(MultiTexCoord3fARB)( GLenum target, GLfloat s,
190 GLfloat t, GLfloat r )
191 {
192 PRE_LOOPBACK( MultiTexCoord3fARB );
193 _glapi_Dispatch->MultiTexCoord3fARB( target, s, t, r );
194 }
195
196 static void TAG(MultiTexCoord3fvARB)( GLenum target, const GLfloat *tc )
197 {
198 PRE_LOOPBACK( MultiTexCoord3fvARB );
199 _glapi_Dispatch->MultiTexCoord3fvARB( target, tc );
200 }
201
202 static void TAG(MultiTexCoord4fARB)( GLenum target, GLfloat s,
203 GLfloat t, GLfloat r, GLfloat q )
204 {
205 PRE_LOOPBACK( MultiTexCoord4fARB );
206 _glapi_Dispatch->MultiTexCoord4fARB( target, s, t, r, q );
207 }
208
209 static void TAG(MultiTexCoord4fvARB)( GLenum target, const GLfloat *tc )
210 {
211 PRE_LOOPBACK( MultiTexCoord4fvARB );
212 _glapi_Dispatch->MultiTexCoord4fvARB( target, tc );
213 }
214
215 static void TAG(Normal3f)( GLfloat x, GLfloat y, GLfloat z )
216 {
217 PRE_LOOPBACK( Normal3f );
218 _glapi_Dispatch->Normal3f( x, y, z );
219 }
220
221 static void TAG(Normal3fv)( const GLfloat *v )
222 {
223 PRE_LOOPBACK( Normal3fv );
224 _glapi_Dispatch->Normal3fv( v );
225 }
226
227 static void TAG(SecondaryColor3fEXT)( GLfloat r, GLfloat g, GLfloat b )
228 {
229 PRE_LOOPBACK( SecondaryColor3fEXT );
230 _glapi_Dispatch->SecondaryColor3fEXT( r, g, b );
231 }
232
233 static void TAG(SecondaryColor3fvEXT)( const GLfloat *v )
234 {
235 PRE_LOOPBACK( SecondaryColor3fvEXT );
236 _glapi_Dispatch->SecondaryColor3fvEXT( v );
237 }
238
239 static void TAG(SecondaryColor3ubEXT)( GLubyte r, GLubyte g, GLubyte b )
240 {
241 PRE_LOOPBACK( SecondaryColor3ubEXT );
242 _glapi_Dispatch->SecondaryColor3ubEXT( r, g, b );
243 }
244
245 static void TAG(SecondaryColor3ubvEXT)( const GLubyte *v )
246 {
247 PRE_LOOPBACK( SecondaryColor3ubvEXT );
248 _glapi_Dispatch->SecondaryColor3ubvEXT( v );
249 }
250
251 static void TAG(TexCoord1f)( GLfloat s )
252 {
253 PRE_LOOPBACK( TexCoord1f );
254 _glapi_Dispatch->TexCoord1f( s );
255 }
256
257 static void TAG(TexCoord1fv)( const GLfloat *tc )
258 {
259 PRE_LOOPBACK( TexCoord1fv );
260 _glapi_Dispatch->TexCoord1fv( tc );
261 }
262
263 static void TAG(TexCoord2f)( GLfloat s, GLfloat t )
264 {
265 PRE_LOOPBACK( TexCoord2f );
266 _glapi_Dispatch->TexCoord2f( s, t );
267 }
268
269 static void TAG(TexCoord2fv)( const GLfloat *tc )
270 {
271 PRE_LOOPBACK( TexCoord2fv );
272 _glapi_Dispatch->TexCoord2fv( tc );
273 }
274
275 static void TAG(TexCoord3f)( GLfloat s, GLfloat t, GLfloat r )
276 {
277 PRE_LOOPBACK( TexCoord3f );
278 _glapi_Dispatch->TexCoord3f( s, t, r );
279 }
280
281 static void TAG(TexCoord3fv)( const GLfloat *tc )
282 {
283 PRE_LOOPBACK( TexCoord3fv );
284 _glapi_Dispatch->TexCoord3fv( tc );
285 }
286
287 static void TAG(TexCoord4f)( GLfloat s, GLfloat t, GLfloat r, GLfloat q )
288 {
289 PRE_LOOPBACK( TexCoord4f );
290 _glapi_Dispatch->TexCoord4f( s, t, r, q );
291 }
292
293 static void TAG(TexCoord4fv)( const GLfloat *tc )
294 {
295 PRE_LOOPBACK( TexCoord4fv );
296 _glapi_Dispatch->TexCoord4fv( tc );
297 }
298
299 static void TAG(Vertex2f)( GLfloat x, GLfloat y )
300 {
301 PRE_LOOPBACK( Vertex2f );
302 _glapi_Dispatch->Vertex2f( x, y );
303 }
304
305 static void TAG(Vertex2fv)( const GLfloat *v )
306 {
307 PRE_LOOPBACK( Vertex2fv );
308 _glapi_Dispatch->Vertex2fv( v );
309 }
310
311 static void TAG(Vertex3f)( GLfloat x, GLfloat y, GLfloat z )
312 {
313 PRE_LOOPBACK( Vertex3f );
314 _glapi_Dispatch->Vertex3f( x, y, z );
315 }
316
317 static void TAG(Vertex3fv)( const GLfloat *v )
318 {
319 PRE_LOOPBACK( Vertex3fv );
320 _glapi_Dispatch->Vertex3fv( v );
321 }
322
323 static void TAG(Vertex4f)( GLfloat x, GLfloat y, GLfloat z, GLfloat w )
324 {
325 PRE_LOOPBACK( Vertex4f );
326 _glapi_Dispatch->Vertex4f( x, y, z, w );
327 }
328
329 static void TAG(Vertex4fv)( const GLfloat *v )
330 {
331 PRE_LOOPBACK( Vertex4fv );
332 _glapi_Dispatch->Vertex4fv( v );
333 }
334
335 static void TAG(CallList)( GLuint i )
336 {
337 PRE_LOOPBACK( CallList );
338 _glapi_Dispatch->CallList( i );
339 }
340
341 static void TAG(Begin)( GLenum mode )
342 {
343 PRE_LOOPBACK( Begin );
344 _glapi_Dispatch->Begin( mode );
345 }
346
347 static void TAG(End)( void )
348 {
349 PRE_LOOPBACK( End );
350 _glapi_Dispatch->End();
351 }
352
353 static void TAG(Rectf)( GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2 )
354 {
355 PRE_LOOPBACK( Rectf );
356 _glapi_Dispatch->Rectf( x1, y1, x2, y2 );
357 }
358
359 static void TAG(DrawArrays)( GLenum mode, GLint start, GLsizei count )
360 {
361 PRE_LOOPBACK( DrawArrays );
362 _glapi_Dispatch->DrawArrays( mode, start, count );
363 }
364
365 static void TAG(DrawElements)( GLenum mode, GLsizei count, GLenum type,
366 const GLvoid *indices )
367 {
368 PRE_LOOPBACK( DrawElements );
369 _glapi_Dispatch->DrawElements( mode, count, type, indices );
370 }
371
372 static void TAG(DrawRangeElements)( GLenum mode, GLuint start,
373 GLuint end, GLsizei count,
374 GLenum type, const GLvoid *indices )
375 {
376 PRE_LOOPBACK( DrawRangeElements );
377 _glapi_Dispatch->DrawRangeElements( mode, start, end, count, type, indices );
378 }
379
380 static void TAG(EvalMesh1)( GLenum mode, GLint i1, GLint i2 )
381 {
382 PRE_LOOPBACK( EvalMesh1 );
383 _glapi_Dispatch->EvalMesh1( mode, i1, i2 );
384 }
385
386 static void TAG(EvalMesh2)( GLenum mode, GLint i1, GLint i2,
387 GLint j1, GLint j2 )
388 {
389 PRE_LOOPBACK( EvalMesh2 );
390 _glapi_Dispatch->EvalMesh2( mode, i1, i2, j1, j2 );
391 }
392
393 static void TAG(VertexAttrib4fNV)( GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w )
394 {
395 PRE_LOOPBACK( VertexAttrib4fNV );
396 _glapi_Dispatch->VertexAttrib4fNV( index, x, y, z, w );
397 }
398
399 static void TAG(VertexAttrib4fvNV)( GLuint index, const GLfloat *v )
400 {
401 PRE_LOOPBACK( VertexAttrib4fvNV );
402 _glapi_Dispatch->VertexAttrib4fvNV( index, v );
403 }
404
405
406 static GLvertexformat TAG(vtxfmt) = {
407 TAG(ArrayElement),
408 TAG(Color3f),
409 TAG(Color3fv),
410 TAG(Color3ub),
411 TAG(Color3ubv),
412 TAG(Color4f),
413 TAG(Color4fv),
414 TAG(Color4ub),
415 TAG(Color4ubv),
416 TAG(EdgeFlag),
417 TAG(EdgeFlagv),
418 TAG(EvalCoord1f),
419 TAG(EvalCoord1fv),
420 TAG(EvalCoord2f),
421 TAG(EvalCoord2fv),
422 TAG(EvalPoint1),
423 TAG(EvalPoint2),
424 TAG(FogCoordfEXT),
425 TAG(FogCoordfvEXT),
426 TAG(Indexi),
427 TAG(Indexiv),
428 TAG(Materialfv),
429 TAG(MultiTexCoord1fARB),
430 TAG(MultiTexCoord1fvARB),
431 TAG(MultiTexCoord2fARB),
432 TAG(MultiTexCoord2fvARB),
433 TAG(MultiTexCoord3fARB),
434 TAG(MultiTexCoord3fvARB),
435 TAG(MultiTexCoord4fARB),
436 TAG(MultiTexCoord4fvARB),
437 TAG(Normal3f),
438 TAG(Normal3fv),
439 TAG(SecondaryColor3fEXT),
440 TAG(SecondaryColor3fvEXT),
441 TAG(SecondaryColor3ubEXT),
442 TAG(SecondaryColor3ubvEXT),
443 TAG(TexCoord1f),
444 TAG(TexCoord1fv),
445 TAG(TexCoord2f),
446 TAG(TexCoord2fv),
447 TAG(TexCoord3f),
448 TAG(TexCoord3fv),
449 TAG(TexCoord4f),
450 TAG(TexCoord4fv),
451 TAG(Vertex2f),
452 TAG(Vertex2fv),
453 TAG(Vertex3f),
454 TAG(Vertex3fv),
455 TAG(Vertex4f),
456 TAG(Vertex4fv),
457 TAG(CallList),
458 TAG(Begin),
459 TAG(End),
460 TAG(VertexAttrib4fNV),
461 TAG(VertexAttrib4fvNV),
462 TAG(Rectf),
463 TAG(DrawArrays),
464 TAG(DrawElements),
465 TAG(DrawRangeElements),
466 TAG(EvalMesh1),
467 TAG(EvalMesh2)
468 };
469
470 #undef TAG
471 #undef PRE_LOOPBACK