patch to import Jon Smirl's work from Bitkeeper
[mesa.git] / src / mesa / drivers / dri / r128 / r128_vb.h
1 /* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_vb.h,v 1.8 2002/10/30 12:51:46 alanh Exp $ */
2 /**************************************************************************
3
4 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
5 VA Linux Systems Inc., Fremont, California.
6
7 All Rights Reserved.
8
9 Permission is hereby granted, free of charge, to any person obtaining a
10 copy of this software and associated documentation files (the "Software"),
11 to deal in the Software without restriction, including without limitation
12 on the rights to use, copy, modify, merge, publish, distribute, sub
13 license, and/or sell copies of the Software, and to permit persons to whom
14 the Software is furnished to do so, subject to the following conditions:
15
16 The above copyright notice and this permission notice (including the next
17 paragraph) shall be included in all copies or substantial portions of the
18 Software.
19
20 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22 FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
23 ATI, VA LINUX SYSTEMS AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM,
24 DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
25 OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
26 USE OR OTHER DEALINGS IN THE SOFTWARE.
27
28 **************************************************************************/
29
30 /*
31 * Authors:
32 * Keith Whitwell <keith@tungstengraphics.com>
33 *
34 */
35
36 #ifndef R128VB_INC
37 #define R128VB_INC
38
39 #include "mtypes.h"
40 #include "swrast/swrast.h"
41 #include "r128_context.h"
42
43 #define _R128_NEW_VERTEX_STATE (_DD_NEW_SEPARATE_SPECULAR | \
44 _DD_NEW_TRI_LIGHT_TWOSIDE | \
45 _DD_NEW_TRI_UNFILLED | \
46 _NEW_TEXTURE | \
47 _NEW_FOG)
48
49 extern void r128CheckTexSizes( GLcontext *ctx );
50 extern void r128ChooseVertexState( GLcontext *ctx );
51
52 extern void r128BuildVertices( GLcontext *ctx, GLuint start, GLuint count,
53 GLuint newinputs );
54
55 extern void r128PrintSetupFlags(char *msg, GLuint flags );
56
57 extern void r128InitVB( GLcontext *ctx );
58 extern void r128FreeVB( GLcontext *ctx );
59
60 extern void r128_emit_contiguous_verts( GLcontext *ctx,
61 GLuint start,
62 GLuint count );
63
64 extern void r128_emit_indexed_verts( GLcontext *ctx,
65 GLuint start,
66 GLuint count );
67
68 extern void r128_translate_vertex( GLcontext *ctx,
69 const r128Vertex *src,
70 SWvertex *dst );
71
72 extern void r128_print_vertex( GLcontext *ctx, const r128Vertex *v );
73
74 #endif