config.h revision 4b334b2db68b1f448165c37fe756cc0aa80b56c5
14b334b2db68b1f448165c37fe756cc0aa80b56c5Brian Paul/* $Id: config.h,v 1.41 2002/10/05 03:01:28 brianp Exp $ */
2afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
3afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
4afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * Mesa 3-D graphics library
5d8af040f5eb2dd2e40339b83a02f4a42b64619adBrian Paul * Version:  4.1
622144ab7552f0799bcfca506bf4ffa7f70a06649Gareth Hughes *
78afe7de8deaf3c9613fd68b344de8c52b02b1879Brian Paul * Copyright (C) 1999-2002  Brian Paul   All Rights Reserved.
822144ab7552f0799bcfca506bf4ffa7f70a06649Gareth Hughes *
9afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * Permission is hereby granted, free of charge, to any person obtaining a
10afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * copy of this software and associated documentation files (the "Software"),
11afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * to deal in the Software without restriction, including without limitation
12afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * the rights to use, copy, modify, merge, publish, distribute, sublicense,
13afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * and/or sell copies of the Software, and to permit persons to whom the
14afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * Software is furnished to do so, subject to the following conditions:
1522144ab7552f0799bcfca506bf4ffa7f70a06649Gareth Hughes *
16afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * The above copyright notice and this permission notice shall be included
17afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * in all copies or substantial portions of the Software.
1822144ab7552f0799bcfca506bf4ffa7f70a06649Gareth Hughes *
19afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
20afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
22afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
23afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
24afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
25afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
26afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
27afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
28afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
29afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * Tunable configuration parameters.
30afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
31afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
32afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
33afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
34afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#ifndef CONFIG_H
35afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define CONFIG_H
36afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
37afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#ifdef HAVE_CONFIG_H
38afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#include "conf.h"
39afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#endif
40afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
41fbd8f212c3866ec98c1d8c9d3db3ddb7e7c479a5Brian Paul
42afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
43afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * OpenGL implementation limits
44afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
45afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
46afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum modelview matrix stack depth: */
47afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_MODELVIEW_STACK_DEPTH 32
48afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
49afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum projection matrix stack depth: */
50afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_PROJECTION_STACK_DEPTH 32
51afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
52afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum texture matrix stack depth: */
53afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_TEXTURE_STACK_DEPTH 10
54afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
55250069dbb443f26f4dcc409c9c873019a5f50f9dBrian Paul/* Maximum color matrix stack depth: */
56250069dbb443f26f4dcc409c9c873019a5f50f9dBrian Paul#define MAX_COLOR_STACK_DEPTH 4
57250069dbb443f26f4dcc409c9c873019a5f50f9dBrian Paul
5830f51ae067379c2b3573c06b707d25a9704df7beBrian Paul/* Vertex program matrix stacks: */
5930f51ae067379c2b3573c06b707d25a9704df7beBrian Paul#define MAX_PROGRAM_MATRICES 8
6030f51ae067379c2b3573c06b707d25a9704df7beBrian Paul#define MAX_PROGRAM_STACK_DEPTH 4
6130f51ae067379c2b3573c06b707d25a9704df7beBrian Paul
62afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum attribute stack depth: */
63afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_ATTRIB_STACK_DEPTH 16
64afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
65afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum client attribute stack depth: */
66afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_CLIENT_ATTRIB_STACK_DEPTH 16
67afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
68afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum recursion depth of display list calls: */
69afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_LIST_NESTING 64
70afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
71afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum number of lights: */
72afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_LIGHTS 8
73afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
74afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum user-defined clipping planes: */
75afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_CLIP_PLANES 6
76afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
77afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum pixel map lookup table size: */
78afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_PIXEL_MAP_TABLE 256
79afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
80afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Number of auxillary color buffers: */
81afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define NUM_AUX_BUFFERS 0
82afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
83afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum order (degree) of curves: */
84afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#ifdef AMIGA
85afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#   define MAX_EVAL_ORDER 12
86afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#else
87afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#   define MAX_EVAL_ORDER 30
88afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#endif
89afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
90afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maximum Name stack depth */
91afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_NAME_STACK_DEPTH 64
92afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
93afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Min and Max point sizes and granularity */
94afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MIN_POINT_SIZE 1.0
956c408b46678637959dba04663fbc34eb9c4bc397Brian Paul#define MAX_POINT_SIZE 20.0
96afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define POINT_SIZE_GRANULARITY 0.1
97afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
98afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Min and Max line widths and granularity */
99afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MIN_LINE_WIDTH 1.0
100afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_LINE_WIDTH 10.0
10165cd4d80c4093e44e6a340b41e7bae3489b7ea4aBrian Paul#define LINE_WIDTH_GRANULARITY 0.1
102afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
10313811376c99addb0616c9397cc7d5715befcd8d4Brian Paul/* Max texture palette / color table size */
10413811376c99addb0616c9397cc7d5715befcd8d4Brian Paul#define MAX_COLOR_TABLE_SIZE 256
105afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
106cd1cefae9146fc14b35ee93a04bdb1b1590fba7bBrian Paul/* Number of 1D/2D texture mipmap levels */
107afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_TEXTURE_LEVELS 12
108afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
109cd1cefae9146fc14b35ee93a04bdb1b1590fba7bBrian Paul/* Number of 3D texture mipmap levels */
110cd1cefae9146fc14b35ee93a04bdb1b1590fba7bBrian Paul#define MAX_3D_TEXTURE_LEVELS 8
111cd1cefae9146fc14b35ee93a04bdb1b1590fba7bBrian Paul
1128afe7de8deaf3c9613fd68b344de8c52b02b1879Brian Paul/* Number of cube texture mipmap levels - GL_ARB_texture_cube_map */
113cd1cefae9146fc14b35ee93a04bdb1b1590fba7bBrian Paul#define MAX_CUBE_TEXTURE_LEVELS 12
114cd1cefae9146fc14b35ee93a04bdb1b1590fba7bBrian Paul
1158afe7de8deaf3c9613fd68b344de8c52b02b1879Brian Paul/* Maximum rectangular texture size - GL_NV_texture_rectangle */
1168afe7de8deaf3c9613fd68b344de8c52b02b1879Brian Paul#define MAX_TEXTURE_RECT_SIZE 2048
1178afe7de8deaf3c9613fd68b344de8c52b02b1879Brian Paul
118afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Number of texture units - GL_ARB_multitexture */
11988f3b89a2cb77766d2009b9868c44e03abe2dbb2Keith Whitwell#define MAX_TEXTURE_UNITS 8
120afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
121a38e117fe61efeee57adfb142296e213b6ca1ba0Brian Paul/* Maximum viewport/image size: */
122a38e117fe61efeee57adfb142296e213b6ca1ba0Brian Paul#define MAX_WIDTH 2048
123f89035b8c45ff13392fe7cb3ce0c2bdb7e4166beBrian Paul#define MAX_HEIGHT 2048
124afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
125afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/* Maxmimum size for CVA.  May be overridden by the drivers.  */
126afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define MAX_ARRAY_LOCK_SIZE 3000
127afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
12865cd4d80c4093e44e6a340b41e7bae3489b7ea4aBrian Paul/* Subpixel precision for antialiasing, window coordinate snapping */
12965cd4d80c4093e44e6a340b41e7bae3489b7ea4aBrian Paul#define SUB_PIXEL_BITS 4
13065cd4d80c4093e44e6a340b41e7bae3489b7ea4aBrian Paul
1310771d159d59a856135e375ba89f6af2a057d4f5bBrian Paul/* Size of histogram tables */
1320771d159d59a856135e375ba89f6af2a057d4f5bBrian Paul#define HISTOGRAM_TABLE_SIZE 256
1330771d159d59a856135e375ba89f6af2a057d4f5bBrian Paul
13482b02f0ef24bf139778c8eec8d62dfa3366dff35Brian Paul/* Max convolution filter sizes */
135a6d46f6b9922327fe9a268b003134a27ba8b931fBrian Paul#define MAX_CONVOLUTION_WIDTH 9
136a6d46f6b9922327fe9a268b003134a27ba8b931fBrian Paul#define MAX_CONVOLUTION_HEIGHT 9
137afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
1381207bf057aeea3376e5e0f03f789a5d67ed4d29dBrian Paul/* GL_ARB_texture_compression */
1391207bf057aeea3376e5e0f03f789a5d67ed4d29dBrian Paul#define MAX_COMPRESSED_TEXTURE_FORMATS 25
1401207bf057aeea3376e5e0f03f789a5d67ed4d29dBrian Paul
1412c3d34c905fa6b831a066afae83b938de05eb241Gareth Hughes/* GL_EXT_texture_filter_anisotropic */
1422c3d34c905fa6b831a066afae83b938de05eb241Gareth Hughes#define MAX_TEXTURE_MAX_ANISOTROPY 16.0
1432c3d34c905fa6b831a066afae83b938de05eb241Gareth Hughes
14487c964d3885d84959f86d5d7d9c4358240b6da3cBrian Paul/* GL_EXT_texture_lod_bias */
14587c964d3885d84959f86d5d7d9c4358240b6da3cBrian Paul#define MAX_TEXTURE_LOD_BIAS 4.0
14687c964d3885d84959f86d5d7d9c4358240b6da3cBrian Paul
1471207bf057aeea3376e5e0f03f789a5d67ed4d29dBrian Paul
148fbd8f212c3866ec98c1d8c9d3db3ddb7e7c479a5Brian Paul
149afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
150afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * Mesa-specific parameters
151afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
152afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
153afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
154afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
155f431a3fb4dc1bf860203d79e54657e3a62bc50dfBrian Paul * Bits per accumulation buffer color component:  8, 16 or 32
156afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
1574b334b2db68b1f448165c37fe756cc0aa80b56c5Brian Paul#define ACCUM_BITS 16
158afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
159afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
160fbd8f212c3866ec98c1d8c9d3db3ddb7e7c479a5Brian Paul/*
16166202b75d561b2275022bea8b5936a7482c1c315Brian Paul * Bits per depth buffer value.  Any reasonable value up to 31 will
16266202b75d561b2275022bea8b5936a7482c1c315Brian Paul * work.  32 doesn't work because of integer overflow problems in the
16366202b75d561b2275022bea8b5936a7482c1c315Brian Paul * rasterizer code.
164fbd8f212c3866ec98c1d8c9d3db3ddb7e7c479a5Brian Paul */
165a1503b00f863a48a517939a42d512f9cfe77f79cBrian Paul#ifndef DEFAULT_SOFTWARE_DEPTH_BITS
166ed30dfa1264ec8875a3162c3c8778bc703bf11d5Brian Paul#define DEFAULT_SOFTWARE_DEPTH_BITS 16
167a1503b00f863a48a517939a42d512f9cfe77f79cBrian Paul#endif
16866202b75d561b2275022bea8b5936a7482c1c315Brian Paul#if DEFAULT_SOFTWARE_DEPTH_BITS <= 16
169ed30dfa1264ec8875a3162c3c8778bc703bf11d5Brian Paul#define DEFAULT_SOFTWARE_DEPTH_TYPE GLushort
17066202b75d561b2275022bea8b5936a7482c1c315Brian Paul#else
17166202b75d561b2275022bea8b5936a7482c1c315Brian Paul#define DEFAULT_SOFTWARE_DEPTH_TYPE GLuint
17266202b75d561b2275022bea8b5936a7482c1c315Brian Paul#endif
173ed30dfa1264ec8875a3162c3c8778bc703bf11d5Brian Paul
174afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
175afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
176afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
177afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * Bits per stencil value:  8
178afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
179afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define STENCIL_BITS 8
180afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
181afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
182afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
183d8af040f5eb2dd2e40339b83a02f4a42b64619adBrian Paul * Bits per color channel:  8, 16 or 32
184afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
185785c3469f45ef4b96f2622cd1575229a1fd9d250Brian Paul#ifndef CHAN_BITS
186afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define CHAN_BITS 8
187785c3469f45ef4b96f2622cd1575229a1fd9d250Brian Paul#endif
188afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
189afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
190afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg/*
191afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * Color channel component order
192afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg * (changes will almost certainly cause problems at this time)
193afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg */
194afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define RCOMP 0
195afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define GCOMP 1
196afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define BCOMP 2
197afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg#define ACOMP 3
198afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
199afb833d4e89c312460a4ab9ed6a7a8ca4ebbfe1cjtg
2000ab16e01348a8feceda9ee55f14b035e400d3c01Brian Paul#endif /* CONFIG_H */
201