added GL_SGIX/SGIS_pixel_texture
[mesa.git] / src / mesa / main / config.h
index 9affa9c4d3d788a561563e86fa81b5c4b1e735ae..ffafd3e78d67aac5f9bc478f425ec6ab66ecb8df 100644 (file)
@@ -1,10 +1,10 @@
-/* $Id: config.h,v 1.2 1999/11/11 01:22:25 brianp Exp $ */
+/* $Id: config.h,v 1.9 2000/04/07 00:19:41 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
  * Version:  3.3
  * 
- * Copyright (C) 1999  Brian Paul   All Rights Reserved.
+ * Copyright (C) 1999-2000  Brian Paul   All Rights Reserved.
  * 
  * Permission is hereby granted, free of charge, to any person obtaining a
  * copy of this software and associated documentation files (the "Software"),
@@ -91,7 +91,7 @@
 /* Min and Max line widths and granularity */
 #define MIN_LINE_WIDTH 1.0
 #define MAX_LINE_WIDTH 10.0
-#define LINE_WIDTH_GRANULARITY 1.0
+#define LINE_WIDTH_GRANULARITY 0.1
 
 /* Max texture palette size */
 #define MAX_TEXTURE_PALETTE_SIZE 256
 /* Maxmimum size for CVA.  May be overridden by the drivers.  */
 #define MAX_ARRAY_LOCK_SIZE 3000
 
+/* Subpixel precision for antialiasing, window coordinate snapping */
+#define SUB_PIXEL_BITS 4
+
+/* Size of histogram tables */
+#define HISTOGRAM_TABLE_SIZE 256
+
 
 
 /*
 
 
 /*
- * Bits per depth buffer value:  16 or 32
+ * Bits per depth buffer value:  16 or 32 (GLushort or GLuint)
+ * gl_create_visual() can select any depth in [0, 32].
  */
-#ifdef MESAD3D
-   /* Mesa / Direct3D driver only */
-   extern float g_DepthScale, g_MaxDepth;
-#  define DEPTH_BITS   32
-#  define DEPTH_SCALE  g_DepthScale
-#  define MAX_DEPTH    g_MaxDepth
-#else
-#  define DEPTH_BITS 16
-#  if DEPTH_BITS==16
-#     define MAX_DEPTH 0xffff
-#     define DEPTH_SCALE 65535.0F
-#  elif DEPTH_BITS==32
-#     define MAX_DEPTH 0x3fffffff
-#     define DEPTH_SCALE ((GLfloat) MAX_DEPTH)
-#  else
-#     error "illegal number of depth bits"
-#  endif
-#endif
+#define DEFAULT_SOFTWARE_DEPTH_BITS 16
+#define DEFAULT_SOFTWARE_DEPTH_TYPE GLushort
+
 
 
 /*
  * Bits per color channel (must be 8 at this time!)
  */
 #define CHAN_BITS 8
-
+#define CHAN_MAX ((1 << CHAN_BITS) - 1)
+#define CHAN_MAXF ((GLfloat) CHAN_MAX)
 
 
 /*
  * this number, though things may go better for you if you choose a
  * value of 12n + 3.  
  */
-
 #define VB_START  3
 
-#if defined(FX) && !defined(MITS)
-#  define VB_MAX 72 + VB_START  /* better performance */
-#else
-#  define VB_MAX 480 + VB_START
-#endif
+#define VB_MAX (216 + VB_START)
+
+
 
 /*
  * Actual vertex buffer size.
  * VB_MAX vertices.  (This only happens when mixed primitives are
  * sharing the vb).  
  */
-#define VB_MAX_CLIPPED_VERTS (2 * (6 + MAX_CLIP_PLANES))
+#define VB_MAX_CLIPPED_VERTS ((2 * (6 + MAX_CLIP_PLANES))+1)
 #define VB_SIZE  (VB_MAX + VB_MAX_CLIPPED_VERTS)
 
 
 
 typedef struct gl_context GLcontext;
 
-extern void gl_read_config_file( struct gl_context *ctx );
+extern void
+gl_read_config_file( struct gl_context *ctx );
+
+extern void
+gl_register_config_var(const char *name, void (*notify)( const char *, int ));
 
 #endif