summaryrefslogtreecommitdiff
path: root/src/mesa/glapi
AgeCommit message (Collapse)Author
2006-08-24Add a new offset mode to the GL API XML. This mode, called "assign,"Ian Romanick
tells the scripts to assign an available offset to the function. The important changes are in src/mesa/glapi/gl_XML.py and src/mesa/glapi/*.xml. Since the DRI drivers only depend on functions required by the ABI (e.g., GL 1.2 + ARB_multitexture) having fixed offsets, all functions not in the ABI use "assign" mode. This has caused the offset of basically every function outside the ABI to change. I have verified that a libGL with this patch works with a DRI driver without the patch. Futher, several function were removed from the dispatch tables altogether. These are the functions for the following extensions: GL_SGIS_texture_filter4 GL_SGIS_texture4D GL_SGIS_detail_texture GL_SGIS_sharpen_texture GL_SGIX_sprite GL_SGIX_instruments GL_SGIX_framezoom GL_SGIX_tag_sample_buffer GL_SGIX_reference_plane GL_SGIX_flush_raster GL_SGIX_list_priority GL_SGIX_fragment_lighting GL_PGI_misc_hints GL_EXT_index_material GL_EXT_index_func GL_3DFX_tbuffer This removes 50 functions from the dispatch table.
2006-08-24Fix some problems with the generation of the size tables. EnableIan Romanick
generation of protocol tables for Render.
2006-08-23New script and API description file to enable generate of GLX protocolIan Romanick
decode tables in the server.
2006-08-22Correct the name of the GL_NV_texture_expand_normal extension.Ian Romanick
2006-08-22The TLS dispatch functions for x86-64 are fixed-size, just like onIan Romanick
x86. This means that the position of each dispatch function can be calculated as (dispatch_offset * size_of_function) + glNewList. This allows us to not store the function pointers in glprocs_table_t. This same optimization has been done for quite some time on x86. We could probably also do this for some cases of the SPARC dispatch as well.
2006-08-22Add new attribute called static_dispatch to the <function> element. ThisIan Romanick
boolean attribute, which defaults to true, determines whether or not a static dispatch function is available in libGL for applications to link against. Ideally, any new functions that are not part of the ABI should not have directly accessable dispatch functions. This forces applications to use glXGetProcAddress to access these functions. By doing this we can gracefully remove functions from libGL without breaking the linkage of applications. Note that the static dispatch functions are still generated. However, they are given names like gl_dispatch_stub_820 and are marked with the "hidden" linker attribute. All extension functions added since the previous Mesa release (6.5) have been marked as 'static_dispatch="false"'.
2006-08-15Add support for GL_EXT_gpu_program_parameters. Any driver that enablesIan Romanick
either GL_ARB_vertex_program or GL_ARB_fragment_program should enable this extension as well.
2006-08-11Fix long standing bug that prevented newer drivers from working withIan Romanick
older libGL. The data in extension_helper.h erroneous instructed drivers to expect all functions with establised offsets, even those not in the ABI, to have a specific offset allocated. This is just wrong. A function is either in the ABI and has a set offset or a function is not in the ABI and has a re-map offset.
2006-07-30Add support for GL_MESA_shader_debug.Michal Krol
2006-06-27Remove the extraneous GL_ prefix from the enums for GL_EXT_timer_query andIan Romanick
GL_EXT_framebuffer_blit. Enumerants in the XML schema get the GL_ prefix added to them automatically. This resulted in things like "GL_GL_TIME_ELAPSED_EXT" in enums.c.
2006-06-16Thread safety for Win32. SourceForge bug #1507315.Brian Paul
2006-06-12Add support for GL_APPLE_vertex_array_object. Several test programsIan Romanick
and demos are also added. Adding basic support to drivers should be as easy as just enabling the extension, though thorough test would also be required.
2006-04-17Add .note.GNU-stack section to assembler files to avoid the default behaviorKristian Høgsberg
of requesting executable stacks.
2006-04-13added 'const' (Dan Schikore)Brian Paul
2006-04-07regenerate SPARC assembly dispatch (bug 6484)Brian Paul
2006-03-29Fixes to silence warnings in code generated by glapi scripts.Kristian Høgsberg
2006-03-15assorted code clean-ups, comments, etc.Brian Paul
2006-03-15remove invalid assertion in _glapi_get_dispatch(), fixes additional thread ↵Brian Paul
safety problem
2006-03-15Need to include glthread.h in glapi.h, not glapi.c so that GET_CURRENT_CONTEXTBrian Paul
is properly defined. Fixes long-standing, but unnoticed thread safety failure. Also, updated comments.
2006-03-14Set always_array=true for glGenProgramsNV (Dave Reveman)Brian Paul
2006-03-06Later versions of Python handle formats like '% 5u' differently. ForIan Romanick
whatever reason, a space is always inserted. That is not the desired behavior.
2006-03-06Generate server-side GLX protocol decode functions using the 'make server'Ian Romanick
target. The environment variable XORG_BASE must be set to point to the base of the X.org server sources where the files are to be placed. The 7.0.0 server release already contains files generated by these scripts. The scripts should have been committed months ago. Sorry for the lag. :(
2006-03-01New comments. Use tuples () instead of lists [] in a few places.Brian Paul
2006-03-01Added glBlitFramebufferEXT function.Brian Paul
2006-02-10commit to fixup MGL namespacing for XGLDave Airlie
2006-01-25added wglGetExtensionsStringARBBrian Paul
2005-12-07Updates for GL_EXT_timer_query:Brian Paul
New GLint64EXT and GLuint64EXT types (use C99's long long types). New glGetQueryObject[u]i64vEXT() functions.
2005-12-02Fix build issues on x86-64 due to missing include path inIan Romanick
glapi_x86-64.S. Bug: #5602
2005-11-04remove unneeded HIDDEN definition (bug 4956)Brian Paul
2005-11-02implement USE_MGL_NAMESPACE for x86-64 dispatch code (Mark Bolstad)Brian Paul
2005-10-20restore FASTCALL stuffBrian Paul
2005-10-20Disable the FASTCALL optimization because it still breaks server-side GLX.Brian Paul
2005-10-11ifdef out some code to make glapi.c linkable in libglx.so (on theIan Romanick
server). This isn't strictly needed yet, but it doesn't hurt anything either. However, the patches for fd.o bug #2996 require this to build.
2005-10-10Add 'get' data for glGetFramebufferAttachmentParameterivEXT enums.Ian Romanick
Remove an extra closing parenthesis in the Linux version of the SWAP_32 macro.
2005-10-03Change the 'count' for COMPRESSED_TEXTURE_FORMATS from "?" to "-1". ThisIan Romanick
signals to the script (glX_proto_size.py) that generates the server-side size functions that a handcoded query is needed to determine the data size. Also do s/FOG_COORD_SOURCE/FOG_COORD_SRC/. When initializing the count in glx_enum::__init__, cast the local property to int. Thanks to Python's dynamic typing, if this isn't done the type of stored count will be a string instead of an int.
2005-10-03Remove the non-existant --get-alias-set option from the help text.Ian Romanick
Update printPixelFunction (which is only used to generate code for the server-side) to use the correct method for obtaining the dimensions of the image parameter to a function. Only use byteswap.h when building generated code on Linux. Elsewhere use the (horrible!) macros from X11/misc.h. Make sure that enums associated with the generic "Get" function get applied to GetIntegerv, GetBooleanv, GetFloatv, and GetDoublev.
2005-09-23 Committing in .Jouk Jansen
1) change compilation on VMS to use IEEE floating points 2) one more problem with _mesa_sprintf solved Modified Files: Mesa/docs/README.VMS Mesa/progs/demos/descrip.mms Mesa/progs/tests/descrip.mms Mesa/progs/util/descrip.mms Mesa/progs/xdemos/descrip.mms Mesa/src/glu/mesa/descrip.mms Mesa/src/glu/sgi/descrip.mms Mesa/src/glut/glx/descrip.mms Mesa/src/mesa/array_cache/descrip.mms Mesa/src/mesa/drivers/common/descrip.mms Mesa/src/mesa/drivers/osmesa/descrip.mms Mesa/src/mesa/drivers/x11/descrip.mms Mesa/src/mesa/glapi/descrip.mms Mesa/src/mesa/main/descrip.mms Mesa/src/mesa/main/texobj.c Mesa/src/mesa/math/descrip.mms Mesa/src/mesa/shader/descrip.mms Mesa/src/mesa/shader/grammar/descrip.mms Mesa/src/mesa/shader/slang/descrip.mms Mesa/src/mesa/swrast/descrip.mms Mesa/src/mesa/swrast_setup/descrip.mms Mesa/src/mesa/tnl/descrip.mms ----------------------------------------------------------------------
2005-09-05remove _swrast_DrawBufferKarl Schultz
2005-08-26/dri/msgAdam Jackson
2005-08-26Fix the scripts for the cygwin & mingw changesAlan Hourihane
2005-08-11Remove the logic that determines at compile time whether or not HAVE_ALIASIan Romanick
should be defined. It was flawed on some platforms (e.g., Darwin & mingw). Instead, rely on the build system to define it on the compiler command line. This also reverts ajax's hand-edit to indirect_size.c. I'll fix that on the X.org side of things later today.
2005-08-10Remove _glapi_check_multithread from the interface exported by the loader toIan Romanick
the driver. The loader now takes care of this for the driver. Remove _glapi_DispatchTSD and give _glapi_Dispatch its semantic (i.e., having a NULL value means that the application is multithreaded and _glapi_get_dispatch must be called). Gut all of the dispatch override code. This removes _glapi_RealDispatch, _glapi_tls_RealDispatch, _glapi_begin_dispatch_override, _glapi_end_dispatch_override, and _glapi_get_override_dispatch. Remove _glapi_get_proc_address, _glapi_get_proc_name, _glapi_get_version, and _glapi_check_table from the loader / driver interface. Reviewed by: Brian Paul
2005-08-09Add rules and target to build src/mesa/x86-64/glapi_x86-64.S.Ian Romanick
2005-08-08s/Disaptch/Dispatch/ (bug 3918)Brian Paul
2005-08-05Fix recent problems with display lists and other parts of the code.Ian Romanick
CALL_by_offset, SET_by_offset, and GET_by_offset all had various problems. The core issue is that parts of the device-independent code in Mesa assumes that all functions have slots in the dispatch table. This is especially true in the display list code. It will merrilly try to set dispatch pointers for glVertexAttrib1fARB even if GL_ARB_vertex_program is not supported. When the GET/SET/CALL macros are invoked, they would read a 0 from the remap table. The problem is that 0 is the dispatch offset for glNewList! One change is that the remap table is now initialized to be full of -1 values. In addtion, all of the *_by_offset marcos misbehave in an obvious way if the specified offset is -1. SET_by_offset will do nothing, GET_by_offset will return NULL, and CALL_by_offset, since it uses GET_by_offset, will segfault. I also had to add GL_EXT_blend_func_separate to the list of default extensions in all_mesa_extensions (src/mesa/drivers/dri/common/utils.c). Even though many drivers do not export this extension, glBlendFunc is internally implemented by calling glBlendFuncSeparate. Without this addition, glBlendFunc stopped working on drivers (such as mga) that do not export GL_EXT_blend_func_separate. There are still a few assertions / crashes in GL_ARB_vertex_program tests, but I don't think that these are related to any of my changes.
2005-08-03Convert all instances of XTHREADS to USE_XTHREADS. This fixes one ofIan Romanick
serveral things that are broken when building on a system with X.org 7.0rc0 installed.
2005-07-28Major rip-up of internal function insertion interface. The oldIan Romanick
_glapi_add_entrypoint has been replaced by a new routine called _glapi_add_dispatch. This new routine dynamically assignes dispatch offsets to functions added. This allows IHVs to add support for extension functions that do not have assigned dispatch offsets. It also means that a driver has no idea what offset will be assigned to a function. The vast majority of the changes in this commit account for that. An additional table, driDispatchRemapTable, is added. Functions not in the Linux OpenGL ABI (i.e., anything not in GL 1.2 + ARB_multitexture) has a fixed offset in this new table. The entry in this table specifies the offset in of the function in the real dispatch table. The internal interface was also bumped from version 20050725 to 20050727. This has been tested with various programs in progs/demos on: radeon (Radeon Mobility M6) r128 (Rage 128 Pro) mga (G400)
2005-07-28Fix SPARC assembly for 64-bitIan Romanick
- The test for whether or not we're building for 64-bit is '#ifdef __arch64__'. This appears to be correct on both Linux and Solaris. - The test for Solaris is now '#if defined(SVR4) || defined(__SVR4) || defined(__svr4__)'. GCC 3.4.0 has all three defined on Solaris 9. - Enables assembly language clip routines. - Fixes to make GLSL code build on Solaris. - Update gl_SPARC_asm.py.
2005-07-18Missed this on the previous commit.Ian Romanick
2005-07-18Wrap every place that accesses a dispatch table with a macro. A new script-Ian Romanick
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