summaryrefslogtreecommitdiffstats
path: root/src/mapi/glapi/glapi.h
Commit message (Collapse)AuthorAgeFilesLines
* glapi: Build glapi_gentable.c only on DarwinAndreas Boll2016-01-211-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Removes the public symbol _glapi_create_table_from_handle from libGL.so.1.2.0 on all platforms except Darwin. Since the symbol is not used on other platforms it makes sense to build glapi_gentable.c only on Darwin. As a side effect it accelerates the build a bit and reduces the size of libGL.so.1.2.0 as follows: size lib/libGL.so.1.2.0 on my system shows text data bss dec hex filename 469211 21848 2720 493779 788d3 lib/libGL.so.1.2.0 before 420988 11240 2720 434948 6a304 lib/libGL.so.1.2.0 after A little bit of history: _glapi_create_table_from_handle was introduced in commit 85937f4c0d4a78d3a11e3c1fa6148640f2a9ad7b Author: Jeremy Huddleston <[email protected]> Date: Thu Jun 9 16:59:49 2011 -0700 glapi: Add API that can create a _glapi_table from a dlfcn handle Example usage: void *handle = dlopen(opengl_library_path, RTLD_LOCAL); struct _glapi_table *disp = _glapi_create_table_from_handle(handle, "gl"); Signed-off-by: Jeremy Huddleston <[email protected]> and the only user in mesa was added in commit f35913b96e743c5014e99220b1a1c5532a894d69 Author: Jeremy Huddleston <[email protected]> Date: Thu Jun 9 17:29:51 2011 -0700 apple: Use _glapi_create_table_from_handle to initialize our dispatch table Signed-off-by: Jeremy Huddleston <[email protected]> gl_gentable.py was also used for XQuartz in xserver 1.11 - 1.14. v2: Fix typos in commit message Add missing XORG_GLAPI_OUTPUTS += \ into src/mapi/glapi/gen/Makefile.am Add glapi_gentable.c to EXTRA_DIST for inclusion in the release tarball v3: Fix commit message: s/gl_gentable.c/glapi_gentable.c/ Reported-by: Arlie Davis <[email protected]> Cc: Jeremy Huddleston <[email protected]> Signed-off-by: Andreas Boll <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* Remove Sun CC specific code.Jose Fonseca2015-12-021-1/+1
| | | | | Reviewed-by: Matt Turner <[email protected]> Acked-by: Alan Coopersmith <[email protected]>
* mapi: add new _glapi_new_nop_table() and _glapi_set_nop_handler()Brian Paul2015-03-181-0/+11
| | | | | | | | | | | | | | | | _glapi_new_nop_table() creates a new dispatch table populated with pointers to no-op functions. _glapi_set_nop_handler() is used to register a callback function which will be called from each of the no-op functions. Now we always generate a separate no-op function for each GL entrypoint. This allows us to do proper stack clean-up for Windows __stdcall and lets us report the actual function name in error messages. Before this change, for non-Windows release builds we used a single no-op function for all entrypoints. Reviewed-by: Jose Fonseca <[email protected]>
* mapi: remove u_thread.hBrian Paul2015-03-051-1/+0
| | | | | | | Just use c11 threads directly. Reviewed-by: Matt Turner <[email protected]> Reviewed-by: José Fonseca <[email protected]>
* mapi: THREADS was always defined, remove itBrian Paul2015-03-051-11/+2
| | | | | | | | THREADS was defined if HAVE_PTHREADS or _WIN32 was defined. That's always the case. The build would die in c11/threads.h otherwise. Reviewed-by: Matt Turner <[email protected]> Reviewed-by: José Fonseca <[email protected]>
* mapi: remove u_compiler.hBrian Paul2015-03-041-0/+1
| | | | | | Just include c99_compat.h or util/macros.h where needed. Reviewed-by: Jose Fonseca <[email protected]>
* glapi: restore _glthread_GetID() functionBrian Paul2014-03-141-0/+5
| | | | | | | This partially reverts patch 02cb04c68f. This fixes an unresolved symbol error when using older builds of libGL. Tested-by: Chia-I Wu <[email protected]>
* mesa: remove remaining uses of _glthread_GetID()Brian Paul2014-03-051-4/+0
| | | | | | | | | | | | | | | It was really only used in the radeon driver for a debug printf. And evidently, libGL.so referenced it just to work around some sort of linker issue. This patch removes the two calls to the function and the function itself. Fixes undefined _glthread_GetID symbol in libGL reported by 'nm'. Though, the missing symbol doesn't cause any issues on my system but it does cause glxinfo to fail on one of our test systems. Reviewed-by: Jose Fonseca <[email protected]>
* mesa: remove empty glthread.h fileBrian Paul2014-03-031-1/+1
| | | | Reviewed-by: José Fonseca <[email protected]>
* mesa: remove outdated version lines in commentsRico Schüller2013-06-051-1/+0
| | | | Signed-off-by: Brian Paul <[email protected]>
* mesa: Restore 78-column wrapping of license text in C-style comments.Kenneth Graunke2013-04-231-3/+4
| | | | | | | | | | | | | | The previous commit introduced extra words, breaking the formatting. This text transformation was done automatically via the following shell command: $ git grep 'THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY' | sed 's/:.*$//' | xargs -I {} sh -c 'vim -e -s {} < vimscript where 'vimscript' is a file containing: /THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY/;/\*\// !fmt -w 78 -p ' * ' :wq Reviewed-by: Brian Paul <[email protected]>
* mesa: Add "OR COPYRIGHT HOLDERS" to license text disclaiming liability.Kenneth Graunke2013-04-231-1/+1
| | | | | | | | | | | | | | | This brings the license text in line with the MIT License as published on the Open Source Initiative website: http://opensource.org/licenses/mit-license.php Generated automatically be the following shell command: $ git grep 'THE AUTHORS BE LIABLE' | sed 's/:.*$//g' | xargs -I '{}' \ sed -i 's/THE AUTHORS/THE AUTHORS OR COPYRIGHT HOLDERS/' {} This introduces some wrapping issues, to be fixed in the next commit. Reviewed-by: Brian Paul <[email protected]>
* mesa: Change "BRIAN PAUL" to "THE AUTHORS" in license text.Kenneth Graunke2013-04-231-1/+1
| | | | | | | | | | | | | | | | Generated automatically be the following shell command: $ git grep 'BRIAN PAUL BE LIABLE' | sed 's/:.*$//g' | xargs -I '{}' \ sed -i 's/BRIAN PAUL/THE AUTHORS/' {} The intention here is to protect all authors, not just Brian Paul. I believe that was already the sensible interpretation, but spelling it out is probably better. More practically, it also prevents people from accidentally copy & pasting the license into a new file which says Brian is not liable when he isn't even one of the authors. Reviewed-by: Brian Paul <[email protected]>
* mesa,glsl,mapi: Put extern "C" { ... } where appropriate.José Fonseca2011-11-091-2/+5
| | | | | Probably a several places missing, but enough to cover all headers (in)directly included by uniform_query.cpp, and fix the MSVC build.
* glapi: Enclose glapi.h in an extern "C" block when included by C++.Kenneth Graunke2011-10-041-0/+6
| | | | | | | | Fixes a build failure introduced in commit b7fa0d0727a3a9e1f64d3cfc7a0f157b35dec09e. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-and-tested-by: Paul Berry <[email protected]>
* glapi: Add API that can create a _glapi_table from a dlfcn handleJeremy Huddleston2011-06-111-0/+4
| | | | | | | | | Example usage: void *handle = dlopen(opengl_library_path, RTLD_LOCAL); struct _glapi_table *disp = _glapi_create_table_from_handle(handle, "gl"); Signed-off-by: Jeremy Huddleston <[email protected]>
* scons: Add support for GLES.Chia-I Wu2011-01-221-5/+0
| | | | | | | | | | | | | | | | | | GLES can be enabled by running scons with $ scons gles=yes When gles=yes is given, the build is changed in three ways. First, libmesa.a will be built with FEATURE_ES1 and FEATURE_ES2. This makes DRI drivers and libEGL support and advertise GLES support. Second, GLES libraries will be created. They are libGLESv1_CM, libGLESv2, and libglapi. Last, libGL or opengl32 will link to libglapi. This change is required as _glapi_* will be declared as __declspec(dllimport) in libmesa.a on windows. libmesa.a expects those symbols to be defined in another DLL. Due to this change to GL, GLES support is marked experimental. Note that GLES requires libxml2-python to generate some of its sources.
* Drop GLcontext typedef and use struct gl_context insteadKristian Høgsberg2010-10-131-3/+3
|
* Revert "glapi: Implement optional dispatch logging"Kristian Høgsberg2010-09-091-7/+1
| | | | | | This reverts commit b9abc6139a310677a37754ea7172d976dbf56979 and the follow on fixes (7aae704 and 6fe1b47). It's changing the glapi/driver ABI and causes a number of problems for debug/non-debug builds.
* glapi: Implement optional dispatch loggingKristian Høgsberg2010-09-091-1/+7
| | | | | | | There's a useful feature buried in glapi to log all API calls to stderr. Unfortunately it requires editing the code and then it's enabled unconditionally for that build. This patch builds in API logging for debug builds and makes it run-time switchable by setting MESA_DEBUG=dispatch.
* glapi: Clean up header inclusions.Chia-I Wu2010-08-231-1/+20
| | | | | Do not rely on PUBLIC being defined in glapi.h. Do not include core mesa headers.
* glapi: Move public function/variable declarations to glapi.h.Chia-I Wu2010-08-211-12/+87
| | | | | | | glapi defines an interface that is used by DRI drivers. It must not be changed in an ABI incompatible way. This commit moves all functions/variables belong to the interface to glapi.h. Instead of including u_current.h from glapi.h, u_current.h now includes glapi.h.
* mapi: Add mapi and share the code with glapi.Chia-I Wu2010-05-071-98/+14
| | | | | | | | | | Specifically, move all or most of glapi/glapi.c to mapi/u_current.c, glapi/glapi_execmem.c to mapi/u_execmem.c, glapi/glthread.[ch] to mapi/u_thread.[ch] and remove their dependencies on core Mesa headers.
* glapi: Move to src/mapi/.Chia-I Wu2010-05-071-0/+172
Move glapi to src/mapi/{glapi,es1api,es2api}.