Commit Graph

5178 Commits

Author SHA1 Message Date
Brian Paul bfb5ea307e replace fprintf() calls with _mesa_problem() 2005-07-19 18:20:04 +00:00
Brian Paul 364ae78e69 remove fprintf() 2005-07-19 18:18:49 +00:00
Brian Paul 8d7d9c22f6 include driverfuncs.h 2005-07-19 15:34:44 +00:00
Brian Paul 7e152b83cb s/clippping/clipping/ 2005-07-18 20:07:19 +00:00
Philippe Houdoin ed886336e1 Fixed warnings by using GLUTProc type instead of anonymous (void *) for
GLUT callbacks.
2005-07-18 19:27:49 +00:00
Alan Hourihane df88dfe1df Fix the FFB driver for the renderbuffer changes
Support NEW INTERFACE as well
2005-07-18 13:52:34 +00:00
Alan Hourihane c235a96a71 pass in the renderbuffer 2005-07-18 13:50:06 +00:00
Ian Romanick aa8ff1e75d Missed this on the previous commit. 2005-07-18 12:33:03 +00:00
Ian Romanick 9bdfee3a47 Wrap every place that accesses a dispatch table with a macro. A new script-
generated file, called src/mesa/glapi/dispatch.h, is added.  This file
contains three macros for each API function.  It contains a GET, a SET, and
a CALL.  Each of the macros take a pointer to the context and a pointer to
the dispatch table.

In several threads on mesa3d-dev we discussed replacing _glapi_add_entrypoint
with a new function called _glapi_add_dispatch.  For this discussion, the
important difference between the two is that the caller of _glapi_add_dispatch
does *not* know what the dispatch offset will be at compile time.  Because of
this callers need to track the dispatch offset returned by
_glapi_add_dispatch.

http://marc.theaimsgroup.com/?t=111947074700001&r=1&w=2

The downside is that driver code then has to access the dispatch table two
different ways.  It accesses it using structure tags (e.g., exec->Begin) for
functions with fixed offsets and via a remap table (e.g., exec[
remap->NewExtensionFunction ]) for functions without fixed offsets. Yuck!

Using the macros allows both types of functions to be accessed
identically.  If a driver needs to set a pointer for Begin, it does
'SET_Begin(ctx, exec, my_begin_function)'.  If it needs to set a pointer
for NewExtensionFunction, it does 'SET_NewExtensionFunction(ctx, exec,
my_NewExtensionFunction_function)'.  Furthermore, if at some point in
the future a static offset is assigned for NewExtensionFunction, only
the macros need to change (instead of every single place that accesses a
table for that function).

This code differs slightly from the originally posted patches in that the
CALL, GET, and SET marcos no longer take a context pointer as a parameter.
Brian Paul had suggested that the remap table could be stored as a global
since it would be set at CreateScreen time and would be constant for all
contexts.  This change reflects that feedback.

http://marc.theaimsgroup.com/?t=112087194700001&r=1&w=2
2005-07-18 12:31:24 +00:00
Adam Jackson e0e993c5ff XMesaResizeBuffers needs separate paths for client and server builds 2005-07-16 04:02:05 +00:00
Adam Jackson c529f6bf70 strip out vestigial #ifdef HAVE_CONFIG_H stanzas, they're confusing the
modular X build
2005-07-16 00:56:20 +00:00
Brian Paul 8d3aca655e disable call to via_sse_memcpy() until it's fixed 2005-07-15 23:13:46 +00:00
Brian Paul 1f88391747 need to flush vertices for GL_OCCLUSION_TEST_RESULT_HP query 2005-07-15 23:08:06 +00:00
Brian Paul d39760d718 Check for null program->Parameters pointer in validate_vertex_program().
GL_NV_vertex_program programs can't directly reference GL state so this
pointer is always NULL.
2005-07-15 22:48:09 +00:00
Brian Paul df0350b7ec added comments 2005-07-15 22:47:00 +00:00
Brian Paul b0489d4f82 remove duplicate "User disable" string 2005-07-15 20:17:02 +00:00
Brian Paul 4c72778251 replace gcc with $(CC) (Egbert Eich) 2005-07-15 13:55:20 +00:00
Brian Paul c62c24c72f added a few more fallbackStrings (Andreas Stenglein) 2005-07-14 23:10:21 +00:00
Keith Whitwell b127cfeb7a Use the LDEXPF wrapper macro. 2005-07-13 17:49:22 +00:00
Keith Whitwell 3f7cb794ea Add a LDEXPF wrapper macro. 2005-07-13 17:47:40 +00:00
Keith Whitwell c472dcdac0 Wrap RESTORE_FPU/RND_NEG_FPU declarations with check for USE_SSE_ASM. 2005-07-13 13:50:31 +00:00
Keith Whitwell ce721143b4 Cache texenv programs to avoid repeated compilation (Ben Skeggs) 2005-07-11 10:10:38 +00:00
Keith Whitwell 9311bc253e Add runtime compiled x87 implementations for most of the remaining
opcodes.  When enabled via environment vars, gears runs and almost
looks right but other apps are still quite buggy.
2005-07-10 11:23:10 +00:00
Keith Whitwell 0cfbd849ec Add lots of x87 fpu instructions. 2005-07-10 11:14:00 +00:00
Roland Scheidegger f3186e5789 Re-enable r200InitSpanFuncs, which was ifdefed out (probably by mistake?),
so r200SetBuffer, r200SpanRenderStart and r200SpanRenderFinish get called again.
Bugzilla #3705, #3706.
2005-07-06 12:49:46 +00:00
Brian Paul 4cf6718725 The old MESA_PBUFFER_ALLOC() function allocated memory on 512-byte boundaries.
Restore that behavior with new _mesa_alloc_texmemory() function.
Should fix via_sse_memcpy() problem in found with flightgear.
2005-07-05 14:13:42 +00:00
Ian Romanick f0ff50d4ed Add support for assembly (static) dispatch functions on x86-64. This
is basically patch #2939 from X.org bugzilla #3379.  This does *not*
fix the bug as it does not dynamically generate stubs at run-time.  It
just gets things one step closer.
2005-07-02 08:29:57 +00:00
Vladimir Dergachev c1c684b0f3 Expose the fact that we do not do either selection of feedback buffers - either with software or hardware rendering. 2005-07-02 01:09:10 +00:00
Jerome Glisse 666dcaaf05 Adding RV350_NJ ID. 2005-07-01 21:26:43 +00:00
Jerome Glisse 7b12220256 Adapt extension string to new GL dispatch schema proposed
by Idr. This  patch is based on Idr patch to radeon driver.
Change #if 1 to #if 0 (r300_context.c:l69) for old dispatch
tab.
2005-07-01 21:22:05 +00:00
Karl Schultz eac7688231 Don't #define __FUNCTION__ on a Microsoft C compiler new enough to have it. 2005-07-01 20:11:46 +00:00
Keith Whitwell 219f3c4489 Set fp->Opcode for OP_TEX_KILL case, fix from Ben Skeggs. 2005-07-01 17:12:29 +00:00
Karl Schultz 7fe8696d01 Use frexp on Windows; frexpf is not available. 2005-07-01 15:58:02 +00:00
Karl Schultz 9b56781986 Fix a prototype 2005-07-01 15:56:14 +00:00
Roland Scheidegger 758f334717 convert sis and radeon driver to use spantmp2 instead of spantmp template. Remove old (pre-renderbuffer) span code instead of converting that too. Remove this old code from mach64 (the dead code was not fully converted to spantmp2 previously) too. 2005-07-01 11:28:14 +00:00
Brian Paul 8e8fa63cb4 comment-out some unused code to silence warnings 2005-07-01 02:03:33 +00:00
Brian Paul 559c494fc8 replace some free() calls with _mesa_free() 2005-07-01 02:03:00 +00:00
Brian Paul 6d3284efd4 fix dependencies 2005-07-01 01:54:38 +00:00
Brian Paul 0d34c0158d fix typo in assertions 2005-07-01 01:30:03 +00:00
Brian Paul f4f1c29597 Move the PYTHON2 and PYTHON_FLAGS assignments to configs/current, and
include $(TOP)/configs/current in glapi/Makefile so those vars can be
easily overridden by any system config, if needed.
2005-07-01 01:27:00 +00:00
Brian Paul bb5c84fcbc Remove NEW_RENDERBUFFER stuff.
Now, OLD_RENDERBUFFER marks code that needs to eventually be removed when
all the drivers are updated to no longer need the SetBuffer() function.
2005-07-01 01:22:25 +00:00
Brian Paul 446e258940 remove OLD_RENDERBUFFER code 2005-07-01 01:10:36 +00:00
Brian Paul 54fb9226e4 remove OLD_RENDERBUFFER stuff 2005-07-01 01:08:29 +00:00
Roland Scheidegger cf5b2f7419 remove common macros used in the span functions of most drivers from the individual drivers and put them in common code. It is still possible for a driver to define its own macros if it has special needs. This affects CLIPPIXEL, CLIPSPAN, HW_CLIPLOOP, HW_ENDCLIPLOOP, and for drivers using the spantmp2 template also GET_SRC_PTR and GET_DST_PTR. 2005-07-01 00:08:46 +00:00
Ian Romanick c212abf99a Replace add_newer_entrypoints (src/mesa/main/context.c) with
device-specific code.  A new Python script
(src/mesa/glapi/extension_helper.py) generates a list of all
entry-points for all known extensions.  Each driver the selects only
the extensions that it needs and enables the via either
driInitExtensions or driInitSingleExtension.

This code has been compile-tested on a drivers, but has only been
run-tested on mga and i915 (on i830 hardware).

These changes were discussed at length on the mesa3d-dev mailing list.

http://marc.theaimsgroup.com/?t=111947074700001&r=1&w=2
2005-06-30 16:00:48 +00:00
Brian Paul 1ac8ae446a remove \n from warning message string 2005-06-30 14:24:44 +00:00
Brian Paul aa70253cbb added newline at end of file 2005-06-30 14:23:40 +00:00
Brian Paul 049e320f46 Add a set of predicate functions for testing matrices instead of directly
testing the flags field.
Move definition of all the MAT_FLAGs into the m_matrix.c file since they're
now private.
2005-06-30 14:22:23 +00:00
Brian Paul f138b977d0 Redo all the GL_LINEAR interpolation code in terms of LERP macros/functions.
This cleans up and simplifies the arithmetic quite a bit.
2005-06-30 13:42:10 +00:00
Roland Scheidegger 4d652b7855 Fix crashes with pixel readback when using the optimized assembly functions.
Pixel count can be negative (this could be fixed elsewhere), so adapt the
functions to work with such inputs correctly (same behaviour as non-optimized
functions).
Bugzilla #2317
Submitted by idr
2005-06-30 11:42:56 +00:00