diff options
author | Keith Whitwell <[email protected]> | 2000-10-31 18:09:44 +0000 |
---|---|---|
committer | Keith Whitwell <[email protected]> | 2000-10-31 18:09:44 +0000 |
commit | 724abeb058ca9372c5a9b9e38ee43dde1accaa41 (patch) | |
tree | 964fba63d45d79ff38dab32f8e8614e68d46e4bc /src/mesa/drivers | |
parent | e3a051e0538a605551f4d58294c94f5eb00ed07f (diff) |
Moved the software rasterizer to a new directory.
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r-- | src/mesa/drivers/glide/fxdd.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/osmesa/osmesa.c | 35 | ||||
-rw-r--r-- | src/mesa/drivers/x11/xm_api.c | 3 | ||||
-rw-r--r-- | src/mesa/drivers/x11/xm_line.c | 41 | ||||
-rw-r--r-- | src/mesa/drivers/x11/xm_tri.c | 94 |
5 files changed, 95 insertions, 82 deletions
diff --git a/src/mesa/drivers/glide/fxdd.c b/src/mesa/drivers/glide/fxdd.c index 64b2312c8dc..4768e1a2339 100644 --- a/src/mesa/drivers/glide/fxdd.c +++ b/src/mesa/drivers/glide/fxdd.c @@ -57,7 +57,7 @@ #include "fxdrv.h" #include "enums.h" #include "extensions.h" -#include "pb.h" +#include "swrast/swrast.h" /* These lookup table are used to extract RGB values in [0,255] from * 16-bit pixel values. @@ -1061,7 +1061,7 @@ static void fxDDUpdateDDPointers(GLcontext *ctx) static void fxDDReducedPrimitiveChange(GLcontext *ctx, GLenum prim) { if (ctx->Polygon.CullFlag) { - if (ctx->PB->primitive != GL_POLYGON) { /* Lines or Points */ + if (ctx->ReducedPrimitive != GL_POLYGON) { /* Lines or Points */ FX_grCullMode(GR_CULL_DISABLE); FX_CONTEXT(ctx)->cullMode=GR_CULL_DISABLE; } diff --git a/src/mesa/drivers/osmesa/osmesa.c b/src/mesa/drivers/osmesa/osmesa.c index 871143a1c5a..d54f8f96040 100644 --- a/src/mesa/drivers/osmesa/osmesa.c +++ b/src/mesa/drivers/osmesa/osmesa.c @@ -1,4 +1,4 @@ -/* $Id: osmesa.c,v 1.24 2000/10/30 16:32:43 brianp Exp $ */ +/* $Id: osmesa.c,v 1.25 2000/10/31 18:09:46 keithw Exp $ */ /* * Mesa 3-D graphics library @@ -48,9 +48,12 @@ #include "types.h" #include "vb.h" #include "extensions.h" +#include "swrast/s_depth.h" #endif + + /* * This is the OS/Mesa context struct. * Notice how it includes a GLcontext. By doing this we're mimicking @@ -1236,9 +1239,9 @@ static void flat_rgba_line( GLcontext *ctx, #define PLOT(X,Y) { GLuint *ptr4 = PIXELADDR4(X,Y); *ptr4 = pixel; } #ifdef WIN32 -#include "..\linetemp.h" +#include "..\swrast\s_linetemp.h" #else -#include "linetemp.h" +#include "swrast/s_linetemp.h" #endif } @@ -1265,9 +1268,9 @@ static void flat_rgba_z_line( GLcontext *ctx, } #ifdef WIN32 -#include "..\linetemp.h" +#include "..\swrast\s_linetemp.h" #else -#include "linetemp.h" +#include "swrast/s_linetemp.h" #endif } @@ -1301,9 +1304,9 @@ static void flat_blend_rgba_line( GLcontext *ctx, } #ifdef WIN32 -#include "..\linetemp.h" +#include "..\swrast\s_linetemp.h" #else -#include "linetemp.h" +#include "swrast/s_linetemp.h" #endif } @@ -1340,9 +1343,9 @@ static void flat_blend_rgba_z_line( GLcontext *ctx, } #ifdef WIN32 -#include "..\linetemp.h" +#include "..\swrast\s_linetemp.h" #else -#include "linetemp.h" +#include "swrast/s_linetemp.h" #endif } @@ -1380,9 +1383,9 @@ static void flat_blend_rgba_z_line_write( GLcontext *ctx, } #ifdef WIN32 -#include "..\linetemp.h" +#include "..\swrast\s_linetemp.h" #else -#include "linetemp.h" +#include "swrast/s_linetemp.h" #endif } @@ -1512,6 +1515,7 @@ static void smooth_rgba_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, { \ GLint i, len = RIGHT-LEFT; \ GLuint *img = PIXELADDR4(LEFT,Y); \ + (void) fffog; \ for (i=0;i<len;i++,img++) { \ GLdepth z = FixedToDepth(ffz); \ if (z < zRow[i]) { \ @@ -1524,9 +1528,9 @@ static void smooth_rgba_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, } \ } #ifdef WIN32 -#include "..\tritemp.h" +#include "..\swrast\s_tritemp.h" #else -#include "tritemp.h" +#include "swrast/s_tritemp.h" #endif } @@ -1553,6 +1557,7 @@ static void flat_rgba_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, { \ GLint i, len = RIGHT-LEFT; \ GLuint *img = PIXELADDR4(LEFT,Y); \ + (void) fffog; \ for (i=0;i<len;i++,img++) { \ GLdepth z = FixedToDepth(ffz); \ if (z < zRow[i]) { \ @@ -1563,9 +1568,9 @@ static void flat_rgba_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, } \ } #ifdef WIN32 -#include "..\tritemp.h" +#include "..\swrast\s_tritemp.h" #else -#include "tritemp.h" +#include "swrast/s_tritemp.h" #endif } diff --git a/src/mesa/drivers/x11/xm_api.c b/src/mesa/drivers/x11/xm_api.c index b8ba18316a6..6e8fa3c0d70 100644 --- a/src/mesa/drivers/x11/xm_api.c +++ b/src/mesa/drivers/x11/xm_api.c @@ -1,4 +1,4 @@ -/* $Id: xm_api.c,v 1.4 2000/10/30 13:32:03 keithw Exp $ */ +/* $Id: xm_api.c,v 1.5 2000/10/31 18:09:46 keithw Exp $ */ /* * Mesa 3-D graphics library @@ -76,6 +76,7 @@ #include "conf.h" #endif #include "macros.h" +#include "swrast/swrast.h" #ifndef GLX_NONE_EXT #define GLX_NONE_EXT 0x8000 diff --git a/src/mesa/drivers/x11/xm_line.c b/src/mesa/drivers/x11/xm_line.c index 7a519482125..ac8713f416a 100644 --- a/src/mesa/drivers/x11/xm_line.c +++ b/src/mesa/drivers/x11/xm_line.c @@ -1,4 +1,4 @@ -/* $Id: xm_line.c,v 1.4 2000/09/28 22:44:32 brianp Exp $ */ +/* $Id: xm_line.c,v 1.5 2000/10/31 18:09:46 keithw Exp $ */ /* * Mesa 3-D graphics library @@ -39,6 +39,9 @@ #include "types.h" #include "xmesaP.h" +/* Internal swrast includes: + */ +#include "swrast/s_depth.h" /**********************************************************************/ @@ -167,7 +170,7 @@ static void flat_TRUECOLOR_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) XMesaPutPixel( img, X, FLIP(xmesa->xm_buffer, Y), pixel ); -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -188,7 +191,7 @@ static void flat_8A8B8G8R_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) *pixelPtr = pixel; -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -208,7 +211,7 @@ static void flat_8R8G8B_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) *pixelPtr = pixel; -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -231,7 +234,7 @@ static void flat_8R8G8B24_line( GLcontext *ctx, pixelPtr->b = color[BCOMP]; \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -251,7 +254,7 @@ static void flat_5R6G5B_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) *pixelPtr = pixel; -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -270,7 +273,7 @@ static void flat_DITHER_5R6G5B_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) PACK_TRUEDITHER( *pixelPtr, X, Y, color[0], color[1], color[2] ); -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -293,7 +296,7 @@ static void flat_DITHER8_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) *pixelPtr = DITHER(X,Y,r,g,b); -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -315,7 +318,7 @@ static void flat_LOOKUP8_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) *pixelPtr = pixel; -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -336,7 +339,7 @@ static void flat_HPCR_line( GLcontext *ctx, #define CLIP_HACK 1 #define PLOT(X,Y) *pixelPtr = (GLubyte) DITHER_HPCR(X,Y,r,g,b); -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -363,7 +366,7 @@ static void flat_TRUECOLOR_z_line( GLcontext *ctx, XMesaPutPixel( img, X, FLIP(xmesa->xm_buffer, Y), pixel ); \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -389,7 +392,7 @@ static void flat_8A8B8G8R_z_line( GLcontext *ctx, *pixelPtr = pixel; \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -415,7 +418,7 @@ static void flat_8R8G8B_z_line( GLcontext *ctx, *pixelPtr = pixel; \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -442,7 +445,7 @@ static void flat_8R8G8B24_z_line( GLcontext *ctx, pixelPtr->b = color[BCOMP]; \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -467,7 +470,7 @@ static void flat_5R6G5B_z_line( GLcontext *ctx, *zPtr = Z; \ *pixelPtr = pixel; \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -491,7 +494,7 @@ static void flat_DITHER_5R6G5B_z_line( GLcontext *ctx, *zPtr = Z; \ PACK_TRUEDITHER(*pixelPtr, X, Y, color[0], color[1], color[2]); \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -518,7 +521,7 @@ static void flat_DITHER8_z_line( GLcontext *ctx, *zPtr = Z; \ *pixelPtr = (GLubyte) DITHER( X, Y, r, g, b); \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -546,7 +549,7 @@ static void flat_LOOKUP8_z_line( GLcontext *ctx, *pixelPtr = pixel; \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } @@ -573,7 +576,7 @@ static void flat_HPCR_z_line( GLcontext *ctx, *pixelPtr = (GLubyte) DITHER_HPCR( X, Y, r, g, b); \ } -#include "linetemp.h" +#include "swrast/s_linetemp.h" } diff --git a/src/mesa/drivers/x11/xm_tri.c b/src/mesa/drivers/x11/xm_tri.c index b0d134a259d..6d60e31a72d 100644 --- a/src/mesa/drivers/x11/xm_tri.c +++ b/src/mesa/drivers/x11/xm_tri.c @@ -1,4 +1,4 @@ -/* $Id: xm_tri.c,v 1.5 2000/10/30 13:32:03 keithw Exp $ */ +/* $Id: xm_tri.c,v 1.6 2000/10/31 18:09:47 keithw Exp $ */ /* * Mesa 3-D graphics library @@ -39,6 +39,10 @@ #include "types.h" #include "xmesaP.h" +/* Internal swrast includes: + */ +#include "swrast/s_depth.h" + @@ -119,7 +123,7 @@ static void smooth_TRUECOLOR_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -154,7 +158,7 @@ static void smooth_8A8B8G8R_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -188,7 +192,7 @@ static void smooth_8R8G8B_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -224,7 +228,7 @@ static void smooth_8R8G8B24_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -258,7 +262,7 @@ static void smooth_TRUEDITHER_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -292,7 +296,7 @@ static void smooth_5R6G5B_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -326,7 +330,7 @@ static void smooth_DITHER_5R6G5B_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -361,7 +365,7 @@ static void smooth_DITHER8_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -398,7 +402,7 @@ static void smooth_DITHER_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -432,7 +436,7 @@ static void smooth_LOOKUP8_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -466,7 +470,7 @@ static void smooth_HPCR_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -498,7 +502,7 @@ static void flat_TRUECOLOR_z_triangle( GLcontext *ctx, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -530,7 +534,7 @@ static void flat_8A8B8G8R_z_triangle( GLcontext *ctx, GLuint v0, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -562,7 +566,7 @@ static void flat_8R8G8B_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -595,7 +599,7 @@ static void flat_8R8G8B24_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -625,7 +629,7 @@ static void flat_TRUEDITHER_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -657,7 +661,7 @@ static void flat_5R6G5B_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -688,7 +692,7 @@ static void flat_DITHER_5R6G5B_z_triangle( GLcontext *ctx, GLuint v0, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -721,7 +725,7 @@ static void flat_DITHER8_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -753,7 +757,7 @@ static void flat_DITHER_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -786,7 +790,7 @@ static void flat_HPCR_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -821,7 +825,7 @@ static void flat_LOOKUP8_z_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffz += fdzdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -846,7 +850,7 @@ static void smooth_TRUECOLOR_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -872,7 +876,7 @@ static void smooth_8A8B8G8R_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -898,7 +902,7 @@ static void smooth_8R8G8B_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -926,7 +930,7 @@ static void smooth_8R8G8B24_triangle( GLcontext *ctx, GLuint v0, GLuint v1, pixel++; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -951,7 +955,7 @@ static void smooth_TRUEDITHER_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -977,7 +981,7 @@ static void smooth_5R6G5B_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1003,7 +1007,7 @@ static void smooth_DITHER_5R6G5B_triangle( GLcontext *ctx, GLuint v0, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1030,7 +1034,7 @@ static void smooth_DITHER8_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1055,7 +1059,7 @@ static void smooth_DITHER_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1082,7 +1086,7 @@ static void smooth_LOOKUP8_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1109,7 +1113,7 @@ static void smooth_HPCR_triangle( GLcontext *ctx, GLuint v0, GLuint v1, ffr += fdrdx; ffg += fdgdx; ffb += fdbdx; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1132,7 +1136,7 @@ static void flat_TRUECOLOR_triangle( GLcontext *ctx, GLuint v0, XMesaPutPixel( img, xx, yy, pixel ); \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1157,7 +1161,7 @@ static void flat_8A8B8G8R_triangle( GLcontext *ctx, GLuint v0, *pixel = (PIXEL_TYPE) p; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1182,7 +1186,7 @@ static void flat_8R8G8B_triangle( GLcontext *ctx, GLuint v0, GLuint v1, *pixel = (PIXEL_TYPE) p; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1208,7 +1212,7 @@ static void flat_8R8G8B24_triangle( GLcontext *ctx, GLuint v0, GLuint v1, pixel++; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } /* @@ -1229,7 +1233,7 @@ static void flat_TRUEDITHER_triangle( GLcontext *ctx, GLuint v0, GLuint v1, XMesaPutPixel( img, xx, yy, p ); \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1255,7 +1259,7 @@ static void flat_5R6G5B_triangle( GLcontext *ctx, GLuint v0, GLuint v1, *pixel = (PIXEL_TYPE) p; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1279,7 +1283,7 @@ static void flat_DITHER_5R6G5B_triangle( GLcontext *ctx, GLuint v0, GLuint v1, color[GCOMP], color[BCOMP]); \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1305,7 +1309,7 @@ static void flat_DITHER8_triangle( GLcontext *ctx, GLuint v0, GLuint v1, *pixel = (PIXEL_TYPE) FLAT_DITHER(xx); \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1329,7 +1333,7 @@ static void flat_DITHER_triangle( GLcontext *ctx, GLuint v0, GLuint v1, XMesaPutPixel( img, xx, yy, p ); \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1355,7 +1359,7 @@ static void flat_HPCR_triangle( GLcontext *ctx, GLuint v0, GLuint v1, *pixel = (PIXEL_TYPE) DITHER_HPCR( xx, yy, r, g, b ); \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } @@ -1383,7 +1387,7 @@ static void flat_LOOKUP8_triangle( GLcontext *ctx, GLuint v0, GLuint v1, *pixel = p; \ } \ } -#include "tritemp.h" +#include "swrast/s_tritemp.h" } |