From: <me...@bi...> - 2000-08-02 16:04:25
|
Here are the rest of the changes I made to get 3.3 to compile under windows. I don't have a 3dfx card, so I just modified the GDI (src/Windows) renderer. With these changes you should be able to build the mesa32 target. Files changed: win32/rules/lib.mesa.core src/glheader.h src/windows/wmesa.c src/windows/wgl.c Diffs: X:\work\Mesa3D_PC_CVS\Mesa\WIN32\RULES>cvs diff lib.mesa.core Index: lib.mesa.core =================================================================== RCS file: /cvsroot/mesa3d/Mesa/WIN32/RULES/lib.mesa.core,v retrieving revision 1.3 diff -r1.3 lib.mesa.core 6,14c6,17 < MESA_CORE = accum.c alpha.c alphabuf.c api1.c api2.c apiext.c\ < attrib.c bbox.c bitmap.c blend.c buffers.c clip.c colortab.c config.c conte xt.c\ < copypix.c cva.c depth.c dlist.c drawpix.c enable.c enums.c eval.c\ < extensions.c feedback.c fog.c get.c hash.c hint.c image.c light.c\ < lines.c logic.c masking.c matrix.c mmath.c mthreads.c pb.c pipeline.c\ < pixel.c pointers.c points.c polygon.c quads.c rastpos.c readpix.c\ < rect.c scissor.c shade.c span.c stages.c state.c stencil.c teximage.c texob j.c texstate.c\ < texture.c translate.c triangle.c varray.c vb.c vbcull.c vbfill.c\ < vbindirect.c vbrender.c vbxform.c vector.c vertices.c winpos.c xform.c zoom .c --- > MESA_CORE = aatriangle.c hash.c pixeltex.c texture.c\ > accum.c debug_xform.c highpc.c points.c texutil.c alpha.c depth.c\ > hint.c polygon.c translate.c alphabuf.c dispatch.c image.c quads.c\ > triangle.c attrib.c dlist.c imaging.c rastpos.c varray.c bbox.c\ > drawpix.c light.c readpix.c vb.c bitmap.c enable.c lines.c rect.c\ > vbcull.c blend.c enums.c logic.c scissor.c vbfill.c buffers.c\ > eval.c lowpc.c shade.c vbindirect.c clip.c extensions.c masking.c\ > span.c vbrender.c colortab.c feedback.c matrix.c stages.c vbxform.c\ > config.c fog.c mem.c state.c vector.c context.c get.c mmath.c\ > stencil.c vertices.c convolve.c glapi.c pb.c teximage.c winpos.c\ > copypix.c glapinoop.c pipeline.c texobj.c xform.c cva.c glthread.c\ > pixel.c texstate.c zoom.c X:\work\Mesa3D_PC_CVS\Mesa\src>cvs diff glheader.h Index: glheader.h =================================================================== RCS file: /cvsroot/mesa3d/Mesa/src/glheader.h,v retrieving revision 1.11 diff -r1.11 glheader.h 132a133,134 > #include <windef.h> > /* 139a142 > */ 141d143 < 156a159,160 > /* mesa_wgl includes gl.h which includes glext.h */ > #define GL_GLEXT_PROTOTYPES 159,160d162 < < X:\work\Mesa3D_PC_CVS\Mesa\src\Windows>cvs diff wmesa.c Index: wmesa.c =================================================================== RCS file: /cvsroot/mesa3d/Mesa/src/Windows/wmesa.c,v retrieving revision 1.3 diff -r1.3 wmesa.c 87c87 < #pragma warning ( disable : 4133 4761 ) --- > #pragma warning ( disable : 4100 4133 4761 ) 433,435c433,436 < // TODO: I modified this function to match the prototype in dd.h. (swansma@geo cities.com) < // dd.h does not explain what the return type is so I could not set this to the proper < // value. --- > > // TODO: I modified this function to match the prototype in > // dd.h. (sw...@ge...) > 445a447,449 > GLbitfield colorBits = > (DD_FRONT_LEFT_BIT | DD_FRONT_RIGHT_BIT | > DD_BACK_LEFT_BIT | DD_BACK_RIGHT_BIT); 448a453,454 > if (mask & colorBits) > { 529a536 > } 530a538 > ENDPROFILE(clear) 532,535c540 < ENDPROFILE(clear) < < return mask; // TODO: I doubt this is correct. dd.h doesn't explain what this should < // be... --- > return mask & ~colorBits; // return which buffers "software" must clear 602c607,622 < static GLboolean set_buffer( GLcontext* ctx, GLenum mode ) --- > static GLboolean set_draw_buffer( GLcontext* ctx, GLenum mode ) > { > STARTPROFILE > /* TODO: this could be better */ > if (mode==GL_FRONT_LEFT || mode==GL_BACK_LEFT) { > return GL_TRUE; > } > else { > return GL_FALSE; > } > ENDPROFILE(set_draw_buffer) > } > > > static void set_read_buffer( GLcontext* ctx, GLframebuffer *colorBuffer, > GLenum mode ) 605a626 > /* 612c633,634 < ENDPROFILE(set_buffer) --- > */ > ENDPROFILE(set_read_buffer) 1179c1201,1202 < ctx->Driver.SetBuffer = set_buffer; --- > ctx->Driver.SetDrawBuffer = set_draw_buffer; > ctx->Driver.SetReadBuffer = set_read_buffer; 1367c1390,1394 < c->gl_buffer = gl_create_framebuffer( c->gl_visual ); --- > c->gl_buffer = gl_create_framebuffer( c->gl_visual, > c->gl_visual->DepthBits > 0, > c->gl_visual->StencilBits > 0, > c->gl_visual->AccumRedBits > 0, > c->gl_visual->AlphaBits > 0 ); 2155a2183 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2197a2226 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2239a2269 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2278a2309 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2318a2350 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2358a2391 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2611a2645 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2650a2685 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2691a2727 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2725a2762 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2761a2799 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE 2801a2840 > #define DEPTH_TYPE DEFAULT_SOFTWARE_DEPTH_TYPE X:\work\Mesa3D_PC_CVS\Mesa\src\Windows>cvs diff wgl.c Index: wgl.c =================================================================== RCS file: /cvsroot/mesa3d/Mesa/src/Windows/wgl.c,v retrieving revision 1.2 diff -r1.2 wgl.c 33a34 > #define GL_GLEXT_PROTOTYPES 34a36 > #include <GL/glext.h> 47,48d48 < #define MAX_MESA_ATTRS 20 < 93c93 < { (PROC)glBlendFuncSeparateINGR, "glBlendFuncSeparateINGR" }, --- > { (PROC)glBlendFuncSeparateEXT, "glBlendFuncSeparateEXT" }, |