Merge branch 'llvm-cliptest-viewport'
[mesa.git] / src / mesa / drivers / dri / mach64 / mach64_native_vb.c
index 75cf0e2ed2d41c46c1c237d161ba8ee91fb1c654..d8426ddee1c0bccce965b9aba87f192dc3153aca 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Mesa 3-D graphics library
  * Version:  3.5
@@ -35,7 +35,7 @@
 #define LOCALVARS
 #endif
 
-void TAG(translate_vertex)(GLcontext *ctx,
+void TAG(translate_vertex)(struct gl_context *ctx,
                           const VERTEX *src,
                           SWvertex *dst)
 {
@@ -103,12 +103,12 @@ void TAG(translate_vertex)(GLcontext *ctx,
 
    assert( p + 1 - (CARD32 *)src == 10 );
         
-   dst->pointSize = ctx->Point._Size;
+   dst->pointSize = ctx->Point.Size;
 }
 
 
 
-void TAG(print_vertex)( GLcontext *ctx, const VERTEX *v )
+void TAG(print_vertex)( struct gl_context *ctx, const VERTEX *v )
 {
    LOCALVARS
    GLuint format = GET_VERTEX_FORMAT();
@@ -199,7 +199,7 @@ void TAG(print_vertex)( GLcontext *ctx, const VERTEX *v )
 #define GET_COLOR(ptr, idx) ((ptr)->data[idx])
 
 
-INTERP_QUALIFIER void TAG(interp_extras)( GLcontext *ctx,
+INTERP_QUALIFIER void TAG(interp_extras)( struct gl_context *ctx,
                                          GLfloat t,
                                          GLuint dst, GLuint out, GLuint in,
                                          GLboolean force_boundary )
@@ -207,19 +207,19 @@ INTERP_QUALIFIER void TAG(interp_extras)( GLcontext *ctx,
    LOCALVARS
    struct vertex_buffer *VB = &TNL_CONTEXT(ctx)->vb;
 
-   if (VB->ColorPtr[1]) {
-      assert(VB->ColorPtr[1]->stride == 4 * sizeof(GLfloat));
+   if (VB->BackfaceColorPtr) {
+      assert(VB->BackfaceColorPtr->stride == 4 * sizeof(GLfloat));
       
       INTERP_4F( t,
-                   GET_COLOR(VB->ColorPtr[1], dst),
-                   GET_COLOR(VB->ColorPtr[1], out),
-                   GET_COLOR(VB->ColorPtr[1], in) );
+                GET_COLOR(VB->BackfaceColorPtr, dst),
+                GET_COLOR(VB->BackfaceColorPtr, out),
+                GET_COLOR(VB->BackfaceColorPtr, in) );
 
-      if (VB->SecondaryColorPtr[1]) {
+      if (VB->BackfaceSecondaryColorPtr) {
         INTERP_3F( t,
-                      GET_COLOR(VB->SecondaryColorPtr[1], dst),
-                      GET_COLOR(VB->SecondaryColorPtr[1], out),
-                      GET_COLOR(VB->SecondaryColorPtr[1], in) );
+                   GET_COLOR(VB->BackfaceSecondaryColorPtr, dst),
+                   GET_COLOR(VB->BackfaceSecondaryColorPtr, out),
+                   GET_COLOR(VB->BackfaceSecondaryColorPtr, in) );
       }
    }
 
@@ -230,19 +230,19 @@ INTERP_QUALIFIER void TAG(interp_extras)( GLcontext *ctx,
    INTERP_VERTEX(ctx, t, dst, out, in, force_boundary);
 }
 
-INTERP_QUALIFIER void TAG(copy_pv_extras)( GLcontext *ctx, 
+INTERP_QUALIFIER void TAG(copy_pv_extras)( struct gl_context *ctx, 
                                           GLuint dst, GLuint src )
 {
    LOCALVARS
       struct vertex_buffer *VB = &TNL_CONTEXT(ctx)->vb;
 
-   if (VB->ColorPtr[1]) {
-      COPY_4FV( GET_COLOR(VB->ColorPtr[1], dst), 
-               GET_COLOR(VB->ColorPtr[1], src) );
+   if (VB->BackfaceColorPtr) {
+      COPY_4FV( GET_COLOR(VB->BackfaceColorPtr, dst),
+               GET_COLOR(VB->BackfaceColorPtr, src) );
 
-      if (VB->SecondaryColorPtr[1]) {
-        COPY_4FV( GET_COLOR(VB->SecondaryColorPtr[1], dst), 
-                  GET_COLOR(VB->SecondaryColorPtr[1], src) );
+      if (VB->BackfaceSecondaryColorPtr) {
+        COPY_4FV( GET_COLOR(VB->BackfaceSecondaryColorPtr, dst),
+                  GET_COLOR(VB->BackfaceSecondaryColorPtr, src) );
       }
    }