Commit Graph

99 Commits

Author SHA1 Message Date
Ian Romanick 25fe93f0a1 Add TLS support to libGL and, by virtue of using glthread.h and GL_CALL, all
DRI drivers.  A TLS enabled libGL can load a TLS or a non-TLS DRI driver,
but a TLS DRI driver requires a TLS enabled libGL.

This fixes bug #1822.
2005-04-13 20:59:15 +00:00
Ian Romanick a657c1aee8 Use the same dispatch.c source file for "normal" Mesa builds and DRI
libGL builds.
2005-04-07 23:58:51 +00:00
Ian Romanick c51ed8c236 Follow the GLX_SGIX_fbconfig spec and return the complete list of
available fbconfigs if attrList is NULL.  This fixes bug #2917.
2005-04-07 00:05:55 +00:00
Ian Romanick 979f35fb78 Minor vertex array support tweaks. These are in preparation for the
(eventual) addition of support for ARB_vertex_buffer_object.  Elminitate the
need for array_state_vector::large_header.  Make some very minor tweaks to
the handling of the indices pointer in emit_DrawElements_old.
2005-03-17 20:36:20 +00:00
Ian Romanick b81efaaa1a Minor vertex array support tweaks. Most of these are in preparation for the
(eventual) addition of support for ARB_vertex_buffer_object.

Move all the private vertex array data structures out of
indirect_vertex_array.c and into indirect_va_private.h.

Rename array_state_vector::enabled_array_count to
array_state_vector::enabled_client_array_count.

Make sure that both the GL extension string and the server GL version are
available when __glXInitVertexState is called.

Make sure that array_state::normalized is set correctly in the array's
gl*Pointer function.
2005-03-17 20:13:09 +00:00
Ian Romanick 3f35fbbf66 Fix the handling of zero-sized output parameters (i.e., those with type
'GLvoid *').  This fixes the GLX protocol for glGetProgramStringARB.  This
fixes bugzilla #2747.

Remove the 'ignore="true"' from glVertexAttrib4bvARB.  This fixes bugzilla
#2746.
2005-03-17 01:48:11 +00:00
Ian Romanick 9eae0b9f19 Hard-code the client-side maximum GL version. It turns out that there are
some flaws in the calculation code when the highest version listed in
known_gl_extensions is supported.  This code would also have some problems
with some of the new features (that don't have an associated extension) on
GL 2.0.
2005-03-17 01:36:24 +00:00
Ian Romanick 91c219d906 Add support for ARB_draw_buffers and ARB_occlusion_query. The GLX protocol
for these extensions (as well as ARB_vertex_program and ARB_matrix_palette)
was just approved by the ARB on 8-Mar-2005.  Now the only extension missing
for 1.5 support is ARB_vertex_buffer_object.

The opcodes for ARB_matrix_palette were also added to gl_API.xml.  Since
this extension isn't supported by Mesa, no code is generated for it.  Some
tabs were also converted to spaces in the comment for
GetCompressedTexImageARB.
2005-03-11 20:55:03 +00:00
Ian Romanick 0bd5373d94 Actually *use* the count_scale value associated with a parameter. 2005-03-06 08:55:39 +00:00
Dave Airlie 1bb14ad90c fix for solo to set the mode, and make solo gcc2 friendly...
From: Stephane Marchesin
2005-03-05 04:00:09 +00:00
Ian Romanick b47731f24d Import fixes from X.org tree (Søren Sandmann <sandmann@redhat.com>). 2005-03-04 17:53:24 +00:00
Ian Romanick fdb5a87f91 Fix some errors in the parameter descriptions in serveral vertex / fragment
program related functions.
2005-03-03 21:22:46 +00:00
Ian Romanick 03dc437363 Clean-up some warnings caused by the addition of vertex / fragment program
protocol support (reported by Adam Jackson).  Added code to validate the
'type' parameter to the draw element functions.
2005-02-28 19:37:10 +00:00
Ian Romanick 4e262cfb07 Accidentally committed wrong version with the previous commit set. 2005-02-25 23:02:33 +00:00
Ian Romanick 40af76bbaa Add GLX protocol support for ARB_fragement_program,
ARB_fragment_program_shadow, ARB_vertex_program, NV_fragment_program,
NV_fragment_program_option, NV_fragment_program2, NV_vertex_program,
NV_vertex_program1_1, NV_vertex_program2, NV_vertex_program2_option,
NV_vertex_program3, and ATI_text_fragment_shader.
2005-02-25 22:46:30 +00:00
Ian Romanick 1fd3bbc42e Convert the static functions read_pixel_reply, read_reply,
setup_single_request, and setup_vendor_request to the global functions
__glXReadPixelReply, __glXReadReply, __glXSetupSingleRequest, and
__glXSetupVendorRequest.  This will make it easier to add handcoded Single /
VendorPrivate / VendorPrivteWithReply functions.
2005-02-25 01:48:25 +00:00
Ian Romanick 365a0a7c15 Missed the commit of glxext.c yesterday.
Fixed a flow control problem in glGet*v that could result in the display
not being unlocked.  This also resulted in refactoring a lot more code
out of the glGet*v routines into get_array_data, which was renamed to
get_client_data.
2005-02-23 20:06:52 +00:00
Ian Romanick 6614766f3e Corrected the value for X_GLrop_SecondaryColor3svEXT. 2005-02-23 00:47:11 +00:00
Ian Romanick 57b5e8538e Missed the Makefile with the previous commit. 2005-02-23 00:24:18 +00:00
Ian Romanick fdb07636f2 Added __glExtensionBiIsEnabled and __GLXcontext::gl_extension_bits. This
enables libGL to query which extension are exported to applications.

Refactored array-query functionality (from glGet*v) in src/glx/x11/single2.c.

Massive re-write of indirect vertex array support.  The most noticable
effect is that glDrawElements now generates DrawArrays protocol.  The
side-effects (and the main reasons for the re-work) are that it is much
easier to add support for new arrays (e.g., GL_VERTEX_ATTRIB_ARRAY,
GL_WEIGHT_ARRAY_ARB, etc.) and it is much easier to add support for the new
DrawArrays protocol (required to support ARB_vertex_buffer_object).

These changes were primarilly tested with progs/demos/isosurf.
2005-02-22 22:36:31 +00:00
Dave Airlie dee1c795c2 add more functionality to miniglx for glitz 2005-02-20 10:46:34 +00:00
Dave Airlie 09298228c6 add EnableExtension so r200 enables all its extensions, add mesa memory
extension entry points
2005-02-15 08:40:24 +00:00
Ian Romanick d863424032 Generate GLX protocol for pixel single commands. 2005-02-09 03:11:23 +00:00
Ian Romanick a02b83115a Fix some mixed spaces / tabs issues in generated code. Commit generated
files that have been trivially changed by other recent commits.
2005-02-05 00:59:57 +00:00
Ian Romanick 0a755ade51 Enable client-side GLX support for texture compression extensions. 2005-02-04 19:29:30 +00:00
Ian Romanick 94a20cbadf Added a bunch of extensions that were previously supported but weren't
in the gl_API.xml database.  Add "official" support for SGI_color_matrix
and SGI_texture_color_table.  These were previously supported only by
way of ARB_imaging.
2005-02-03 00:38:40 +00:00
Ian Romanick 16c3c74018 Refactor the code to emit multiple-inclusion protection to
FilterGLAPISpecBase.  Since the size_h mode of glX_proto_size.py will be
used to generate multiple header files, add an option to specify the define
that is used for multiple-inclusion protection.

The changes to the header files in this commit are just a side-effect of the
changes to the Python scripts.
2005-01-28 19:00:54 +00:00
Ian Romanick 20b8d9c1b9 Fix some get / set errors with COLOR_TABLE_*. SCALE and BIAS can be
parameters to GetColorTableParameter[if]v.  FORMAT, WIDTH, and the SIZE
enums cannot be parameters to ColorTableParameter[if]v.
2005-01-28 17:58:58 +00:00
Ian Romanick 6398a97aff Mark a couple more function parameters as counters. 2005-01-27 19:50:59 +00:00
Ian Romanick 82e22f50f1 Add numerous 'get'-type functions to most of the enums supported by the
server-side GLX implementation.

Correct the protocol for EXT_convolution.  Several functions were
incorrectly listed as 'sop' that should have been 'vendorpriv'.

Remove TexParameter[if]v from the list of functions associated with
TEXTURE_RESIDENT.  The state associated with this enum is read-only.

Sort the enums by value for each particular size.  This ensures that the
signature is the same no matter what the ordering is of the enums in the XML
file.  The side effect is that there are some extra changes in
indirect_size.c.
2005-01-27 19:39:16 +00:00
Adam Jackson 999534216d HAVE_ALIAS was never defined anywhere, add some logic to turn it on
automagically.
2005-01-23 03:54:38 +00:00
Keith Whitwell 520e56f232 Depend tweaks 2005-01-19 11:10:27 +00:00
Ian Romanick 591b72b6a9 Added a couple missing proxy types. 2005-01-11 23:50:01 +00:00
Ian Romanick d24e49f301 Put quotes around the CC and CXX variables passed to mklib. This make
them work with multi-work compiler names (e.g., "ccache gcc").
2005-01-11 22:43:45 +00:00
Adam Jackson 1074eae704 Enable libGL to be built with DRI_NEW_INTERFACE_ONLY (but don't do it yet). 2005-01-08 03:54:38 +00:00
Ian Romanick 70d2f152f8 Refactor the code that converts a transpose-matrix enum to a
regular-matrix enum.
2005-01-07 02:53:04 +00:00
Ian Romanick 5f1f229f8d Pixel oriented render functions are now generated by the
glX_proto_send.py script.  This eliminates ~600 lines of non-generated
code.  With proper compiler optimization settings, it also decreases the
size of libGL.so by about 3KB.
2005-01-07 02:39:09 +00:00
Ian Romanick 3385d7cec3 The generic_*_byte functions did not rount the command size to a
multiple of 4 correctly in some cases.
2005-01-07 02:29:42 +00:00
Alan Hourihane 1e21673ea1 support 720x480 and 960x540 modes 2005-01-05 22:40:34 +00:00
Ian Romanick 3276c192b7 The opcode and command length fields of RenderLarge commands were
mistakenly emitted in the wrong order.
2005-01-03 21:03:03 +00:00
Ian Romanick 83fcf49647 Fixed two problems with the handling of GLX protocol replies. The logic
for determining when extra data needed to be read after a reply (to ensure
4-byte alignment) and the logic to determine whether or not to read reply
data after the SingleReply packet were both slightly wrong.
2004-12-27 08:29:54 +00:00
Ian Romanick 990dec7ea0 Used GCC's __builtin_expect when available. Change the way code is
generated for commands that can use RenderLarge packets.  Tweak the code for
__glXFlushRenderBuffer slightly.
2004-12-21 23:06:02 +00:00
Ian Romanick 0d84c68313 Use GLX protocol code generated by glX_proto_send.py. 2004-12-20 04:53:00 +00:00
Adam Jackson 4890f2605e Mark the XF86DRI client-side extension API as PUBLIC. 2004-12-15 23:07:55 +00:00
Adam Jackson 489ccef398 Fix up glx/x11 to work when built with -fvisibility=hidden. 2004-12-15 17:18:06 +00:00
Keith Whitwell fc23672327 Improve the behaviour of the build system wrt depend files.
- Remove the -Y option for makedepend, so that the standard
	  directories are searched
	- No longer pipe the multiple errors that the -Y option caused
	  into /dev/null -- we want to know about these failures.
	- Fix up a few other misc makedepend failures.
2004-12-08 15:16:36 +00:00
Dave Airlie 23b033ad28 From: Stephane Marchesin <marchesin@icps.u-strasbg.fr>
Attached is a patch that adds pci init code for mesa solo on radeon. It's been
tested on an itanium 2 with a radeon 7000 and it works here.
The patch adds a new field in the miniglx.conf config file, to choose between
pci and agp.
2004-12-08 06:15:01 +00:00
Ian Romanick 00d153eb72 Corrected a problem with the sizes of the MAP[12]_* enums. 2004-12-01 23:53:43 +00:00
Ian Romanick 77e297c368 Refactor ExtractDir and OpenDriver to be a bit more clear. 2004-12-01 09:41:14 +00:00
Ian Romanick 9bba1cfc39 Use indirect_size.c and indirect_size.h generated by using
src/mesa/glapi/glX_proto_send.py with the '-m size_c' and '-m size_h'
options.
2004-12-01 09:11:04 +00:00