1bcc6eddd335e97d49ed2ef3a1440f94d58dce12dJon Smirl/*
2adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellCopyright (C) The Weather Channel, Inc.  2002.  All Rights Reserved.
3adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
4adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellThe Weather Channel (TM) funded Tungsten Graphics to develop the
5adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwellinitial release of the Radeon 8500 driver under the XFree86 license.
6adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellThis notice must be preserved.
7adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
8adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellPermission is hereby granted, free of charge, to any person obtaining
9adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwella copy of this software and associated documentation files (the
10adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell"Software"), to deal in the Software without restriction, including
11adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwellwithout limitation the rights to use, copy, modify, merge, publish,
12adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwelldistribute, sublicense, and/or sell copies of the Software, and to
13adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwellpermit persons to whom the Software is furnished to do so, subject to
14adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwellthe following conditions:
15adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
16adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellThe above copyright notice and this permission notice (including the
17adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwellnext paragraph) shall be included in all copies or substantial
18adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwellportions of the Software.
19adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
20adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
21adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
23adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellIN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE
24adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellLIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
25adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
26adbec39bbf671ad80f6c557801e274cac0d305faKeith WhitwellWITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
28adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell**************************************************************************/
29adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
30adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell/*
31adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell * Authors:
32adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell *   Keith Whitwell <keith@tungstengraphics.com>
33adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell */
34adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
35adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell#ifndef __R200_STATE_H__
36adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell#define __R200_STATE_H__
37adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
38adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell#include "r200_context.h"
39adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
40adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwellextern void r200InitState( r200ContextPtr rmesa );
41d1ca1599f0319f5c99852ce24420aa592e806db0Alex Deucherextern void r200InitStateFuncs( radeonContextPtr radeon, struct dd_function_table *functions );
42f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200InitTnlFuncs( struct gl_context *ctx );
43adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
44f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200UpdateMaterial( struct gl_context *ctx );
45adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
46f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200UpdateViewportOffset( struct gl_context *ctx );
47f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200UpdateWindow( struct gl_context *ctx );
48f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200UpdateDrawBuffer(struct gl_context *ctx);
49adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
50f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern GLboolean r200ValidateState( struct gl_context *ctx );
51adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
52f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200_vtbl_update_scissor( struct gl_context *ctx );
53dbf59de6d2f8be526e97af6c768622e6ca3cf6b1Pauli Nieminen
54f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200Fallback( struct gl_context *ctx, GLuint bit, GLboolean mode );
55adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell#define FALLBACK( rmesa, bit, mode ) do {				\
56adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell   if ( 0 ) fprintf( stderr, "FALLBACK in %s: #%d=%d\n",		\
57adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell		     __FUNCTION__, bit, mode );				\
584637235183b80963536f2364e4d50fcb894886ddDave Airlie   r200Fallback( rmesa->radeon.glCtx, bit, mode );				\
59adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell} while (0)
60adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
61f9995b30756140724f41daf963fa06167912be7fKristian Høgsbergextern void r200LightingSpaceChange( struct gl_context *ctx );
62adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell
63adbec39bbf671ad80f6c557801e274cac0d305faKeith Whitwell#endif
64