diff options
author | Brian Paul <brian.paul@tungstengraphics.com> | 2000-11-17 21:01:25 +0000 |
---|---|---|
committer | Brian Paul <brian.paul@tungstengraphics.com> | 2000-11-17 21:01:25 +0000 |
commit | 5a9026c65d260dc185e072163999f5d810015108 (patch) | |
tree | 250630676f5a7493292cb378def17f3105f046c7 /src/mesa/drivers | |
parent | 9e83e8c790d8b612a7256c630f6ff7e063faaccb (diff) |
Minor header file changes to silence warnings.
Added _mesa_enable_sw_extensions(), called by software-only drivers
to enable all s/w-supported GL extensions.
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r-- | src/mesa/drivers/beos/GLView.cpp | 10 | ||||
-rw-r--r-- | src/mesa/drivers/ggi/ggimesa.c | 3 | ||||
-rw-r--r-- | src/mesa/drivers/glide/fxdd.c | 21 | ||||
-rw-r--r-- | src/mesa/drivers/osmesa/osmesa.c | 8 | ||||
-rw-r--r-- | src/mesa/drivers/svga/svgamesa.c | 7 | ||||
-rw-r--r-- | src/mesa/drivers/windows/wmesa.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/x11/xm_api.c | 6 |
7 files changed, 26 insertions, 33 deletions
diff --git a/src/mesa/drivers/beos/GLView.cpp b/src/mesa/drivers/beos/GLView.cpp index 44e51a58db..56c1b7773b 100644 --- a/src/mesa/drivers/beos/GLView.cpp +++ b/src/mesa/drivers/beos/GLView.cpp @@ -1,4 +1,4 @@ -/* $Id: GLView.cpp,v 1.4 2000/11/14 17:51:15 brianp Exp $ */ +/* $Id: GLView.cpp,v 1.5 2000/11/17 21:01:26 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -27,6 +27,11 @@ /* * $Log: GLView.cpp,v $ + * Revision 1.5 2000/11/17 21:01:26 brianp + * Minor header file changes to silence warnings. + * Added _mesa_enable_sw_extensions(), called by software-only drivers + * to enable all s/w-supported GL extensions. + * * Revision 1.4 2000/11/14 17:51:15 brianp * more Driver.Color, Driver.Index updates * @@ -71,6 +76,7 @@ #include <stdio.h> #include <GLView.h> #include "../src/context.h" +#include "extensions.h" // BeOS component ordering for B_RGBA32 bitmap format @@ -1037,6 +1043,8 @@ BGLView::BGLView(BRect rect, char *name, const GLboolean direct = GL_TRUE; GLcontext *ctx = _mesa_create_context( visual, NULL, aux, direct ); + _mesa_enable_sw_extensions(ctx); + aux->Init(this, ctx, visual, buffer ); // Hook aux data into BGLView object diff --git a/src/mesa/drivers/ggi/ggimesa.c b/src/mesa/drivers/ggi/ggimesa.c index 764ccba803..fffbaa5f4f 100644 --- a/src/mesa/drivers/ggi/ggimesa.c +++ b/src/mesa/drivers/ggi/ggimesa.c @@ -30,6 +30,7 @@ #include <ggi/mesa/ggimesa_int.h> #include <ggi/mesa/debug.h> +#include "extensions.h" #undef VIS #undef FLIP @@ -319,6 +320,8 @@ GGIMesaContext GGIMesaCreateContext(void) if (!ctx->gl_ctx) return NULL; + _mesa_enable_sw_extensions(ctx->gl_ctx); + return ctx; } diff --git a/src/mesa/drivers/glide/fxdd.c b/src/mesa/drivers/glide/fxdd.c index 178fa192ac..6dbbec4d59 100644 --- a/src/mesa/drivers/glide/fxdd.c +++ b/src/mesa/drivers/glide/fxdd.c @@ -121,22 +121,6 @@ static void fxDDBufferSize(GLcontext *ctx, GLuint *width, GLuint *height) } -/* Set current drawing color */ -static void fxDDSetColor(GLcontext *ctx, GLubyte red, GLubyte green, - GLubyte blue, GLubyte alpha ) -{ - fxMesaContext fxMesa=(fxMesaContext)ctx->DriverCtx; - GLubyte col[4]; - ASSIGN_4V( col, red, green, blue, alpha ); - - if (MESA_VERBOSE&VERBOSE_DRIVER) { - fprintf(stderr,"fxmesa: fxDDSetColor(%d,%d,%d,%d)\n",red,green,blue,alpha); - } - - fxMesa->color=FXCOLOR4(col); -} - - /* Implements glClearColor() */ static void fxDDClearColor(GLcontext *ctx, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha ) @@ -976,11 +960,6 @@ void fxSetupDDPointers(GLcontext *ctx) ctx->Driver.ClearColor=fxDDClearColor; ctx->Driver.Clear=fxDDClear; -#if 0 - ctx->Driver.Index=NULL; - ctx->Driver.Color=fxDDSetColor; -#endif - ctx->Driver.SetDrawBuffer=fxDDSetDrawBuffer; ctx->Driver.SetReadBuffer=fxDDSetReadBuffer; ctx->Driver.GetBufferSize=fxDDBufferSize; diff --git a/src/mesa/drivers/osmesa/osmesa.c b/src/mesa/drivers/osmesa/osmesa.c index 74850556a7..9f7280564c 100644 --- a/src/mesa/drivers/osmesa/osmesa.c +++ b/src/mesa/drivers/osmesa/osmesa.c @@ -1,4 +1,4 @@ -/* $Id: osmesa.c,v 1.31 2000/11/16 21:05:38 keithw Exp $ */ +/* $Id: osmesa.c,v 1.32 2000/11/17 21:01:40 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -53,6 +53,7 @@ #include "swrast/s_depth.h" #include "swrast/s_lines.h" #include "swrast/s_triangle.h" +#include "tnl/tnl.h" #endif @@ -273,9 +274,8 @@ OSMesaCreateContextExt( GLenum format, GLint depthBits, GLint stencilBits, FREE(osmesa); return NULL; } - gl_extensions_enable(&(osmesa->gl_ctx),"GL_HP_occlusion_test"); - gl_extensions_enable(&(osmesa->gl_ctx), "GL_ARB_texture_cube_map"); - gl_extensions_enable(&(osmesa->gl_ctx), "GL_EXT_texture_env_combine"); + + _mesa_enable_sw_extensions(&(osmesa->gl_ctx)); osmesa->gl_buffer = _mesa_create_framebuffer( osmesa->gl_visual, osmesa->gl_visual->DepthBits > 0, diff --git a/src/mesa/drivers/svga/svgamesa.c b/src/mesa/drivers/svga/svgamesa.c index 5163e08ece..4a6c34b4f0 100644 --- a/src/mesa/drivers/svga/svgamesa.c +++ b/src/mesa/drivers/svga/svgamesa.c @@ -1,4 +1,4 @@ -/* $Id: svgamesa.c,v 1.8 2000/11/16 21:05:39 keithw Exp $ */ +/* $Id: svgamesa.c,v 1.9 2000/11/17 21:01:44 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -39,12 +39,13 @@ #else #include <stdio.h> #include <stdlib.h> +#include <string.h> #include <vga.h> #include "GL/svgamesa.h" #include "context.h" +#include "extensions.h" #include "matrix.h" #include "types.h" -#include <string.h> #endif #include "svgapix.h" @@ -418,6 +419,8 @@ SVGAMesaContext SVGAMesaCreateContext( GLboolean doubleBuffer ) NULL, /* share list context */ (void *) ctx, GL_TRUE ); + _mesa_enable_sw_extensions(ctx->gl_ctx); + ctx->gl_buffer = _mesa_create_framebuffer( ctx->gl_vis, ctx->gl_vis->DepthBits > 0, ctx->gl_vis->StencilBits > 0, diff --git a/src/mesa/drivers/windows/wmesa.c b/src/mesa/drivers/windows/wmesa.c index 55c5c402af..b55142e8ad 100644 --- a/src/mesa/drivers/windows/wmesa.c +++ b/src/mesa/drivers/windows/wmesa.c @@ -1,4 +1,4 @@ -/* $Id: wmesa.c,v 1.11 2000/11/14 17:40:15 brianp Exp $ */ +/* $Id: wmesa.c,v 1.12 2000/11/17 21:01:47 brianp Exp $ */ /* * Windows (Win32) device driver for Mesa 3.4 @@ -1284,6 +1284,8 @@ WMesaContext WMesaCreateContext( HWND hWnd, HPALETTE* Pal, return NULL; } + _mesa_enable_sw_extensions(c->gl_ctx); + c->gl_buffer = _mesa_create_framebuffer( c->gl_visual, c->gl_visual->DepthBits > 0, c->gl_visual->StencilBits > 0, diff --git a/src/mesa/drivers/x11/xm_api.c b/src/mesa/drivers/x11/xm_api.c index f48da3bbfe..412d1eed96 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.8 2000/11/16 21:05:40 keithw Exp $ */ +/* $Id: xm_api.c,v 1.9 2000/11/17 21:01:48 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -1638,9 +1638,7 @@ XMesaContext XMesaCreateContext( XMesaVisual v, XMesaContext share_list ) return NULL; } - gl_extensions_enable(ctx, "GL_HP_occlusion_test"); - gl_extensions_enable(ctx, "GL_ARB_texture_cube_map"); - gl_extensions_enable(ctx, "GL_EXT_texture_env_combine"); + _mesa_enable_sw_extensions(ctx); if (CHECK_BYTE_ORDER(v)) { c->swapbytes = GL_FALSE; |