Allow different max texture sizes for 1/2D, 3D and cube maps.
[mesa.git] / src / mesa / tnl / t_context.h
index 582356dd3785c96cf916c970d8bc90d7eaafb410..226b877d8525d705b6edf6fd996ce05478ab2375 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: t_context.h,v 1.23 2001/05/10 12:18:38 keithw Exp $ */
+/* $Id: t_context.h,v 1.28 2001/06/04 16:09:28 keithw Exp $ */
 
 /*
  * Mesa 3-D graphics library
@@ -176,6 +176,9 @@ struct immediate
    GLuint ArrayEltFlags;       /* precalc'ed for glArrayElt */
    GLuint ArrayEltIncr;
    GLuint ArrayEltFlush;
+
+#define FLUSH_ELT_EAGER 0x1
+#define FLUSH_ELT_LAZY 0x2
    GLuint FlushElt;
 
    GLuint MaxTextureUnits;     /* precalc'ed for glMultiTexCoordARB */
@@ -268,6 +271,7 @@ typedef struct vertex_buffer
 
 
    GLuint importable_data;
+   void *import_source;
    void (*import_data)( GLcontext *ctx, GLuint flags, GLuint vecflags );
    /* Callback to the provider of the untransformed input for the
     * render stage (or other stages) to call if they need to write into
@@ -367,7 +371,7 @@ typedef void (*quad_func)( GLcontext *ctx, GLuint v1, GLuint v2,
 typedef void (*render_func)( GLcontext *ctx, GLuint start, GLuint count,
                             GLuint flags );
 typedef void (*interp_func)( GLcontext *ctx,
-                            GLfloat t, GLuint dst, GLuint in, GLuint out,
+                            GLfloat t, GLuint dst, GLuint out, GLuint in,
                             GLboolean force_boundary );
 typedef void (*copy_pv_func)( GLcontext *ctx, GLuint dst, GLuint src );
 
@@ -401,13 +405,25 @@ struct tnl_device_driver {
     */
 
    interp_func RenderInterp;
+   /* The interp function is called by the clipping routines when we need
+    * to generate an interpolated vertex.  All pertinant vertex ancilliary
+    * data should be computed by interpolating between the 'in' and 'out'
+    * vertices.
+    */
+
    copy_pv_func RenderCopyPV;
+   /* The copy function is used to make a copy of a vertex.  All pertinant
+    * vertex attributes should be copied.
+    */
+
    void (*RenderClippedPolygon)( GLcontext *ctx, const GLuint *elts, GLuint n );
-   void (*RenderClippedLine)( GLcontext *ctx, GLuint v0, GLuint v1 );
-   /* Functions to interpolate between prebuilt vertices, copy flat-shade
-    * provoking color, and to render clipped primitives.
+   /* Render a polygon with <n> vertices whose indexes are in the <elts>
+    * array.
     */
 
+   void (*RenderClippedLine)( GLcontext *ctx, GLuint v0, GLuint v1 );
+   /* Render a line between the two vertices given by indexes v0 and v1. */
+
    points_func           PointsFunc; /* must now respect vb->elts */
    line_func             LineFunc;
    triangle_func         TriangleFunc;
@@ -420,7 +436,9 @@ struct tnl_device_driver {
    render_func          *RenderTabElts;
    /* Render whole unclipped primitives (points, lines, linestrips,
     * lineloops, etc).  The tables are indexed by the GL enum of the
-    * primitive to be rendered.
+    * primitive to be rendered.  RenderTabVerts is used for non-indexed
+    * arrays of vertices.  RenderTabElts is used for indexed arrays of
+    * vertices.
     */
 
    void (*ResetLineStipple)( GLcontext *ctx );
@@ -506,6 +524,7 @@ typedef struct {
    /* Probably need a better configuration mechanism:
     */
    GLboolean NeedProjCoords;
+   GLboolean LoopbackDListCassettes;
 
    /* Derived state and storage for _tnl_eval_vb:
     */