summaryrefslogtreecommitdiffstats
path: root/src/mapi/glapi
Commit message (Collapse)AuthorAgeFilesLines
* Revert "Revert "mapi: export all GLES 3.2 functions in libGLESv2.so""Francisco Jerez2016-10-241-0/+12
| | | | | | | | | | This reverts commit 85e9bbc14d93fa7166c9ae075ee7ae29a8313e3f. The previous commit should help with the scons build failure caused by the original commit. Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Dylan Baker <dylan@pnwbakers.com> (cherry picked from commit 811eb7f178b8b85ac299121ac09a3180b9b55da2)
* glapi: Move PrimitiveBoundingBox and BlendBarrier definitions into ES3.2 ↵Francisco Jerez2016-10-241-13/+17
| | | | | | | | | | | | | | | | | | category. These two GLES 3.2 entry points were being defined in the category of the ARB_ES3_2_compatibility and KHR_blend_equation_advanced extensions respectively instead of in the ES3.2 category. Defining them in the ES3.2 category makes sure that the gl_procs.py generator emits declarations in the glprocs.h header file for the unsuffixed GLES-only entry points that PrimitiveBoundingBoxARB and BlendBarrierKHR respectively alias. This should avoid a compilation failure during scons builds in combination with "mapi: export all GLES 3.2 functions in libGLESv2.so". Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Dylan Baker <dylan@pnwbakers.com> (cherry picked from commit 15a084a03998c5c86206137fdaf6f43b5f98485a)
* glapi: add entry points for GL_ARB_compute_variable_group_sizeSamuel Pitoiset2016-10-073-1/+29
| | | | | | | | | v2: - correctly sort that new extension (Ian) - fix up the comment (Ian) Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
* mapi/glapi: remove unused _glapi_check_table()Emil Velikov2016-10-062-68/+0
| | | | | | | | | Similar to earlier commit - symbol was never part of the public API so we're safe to remove it. Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
* mapi/glapi: remove unused _glapi_check_table_not_nullEmil Velikov2016-10-062-24/+0
| | | | | | | | Function was never part of the API/ABI and the final user was removed with commit a73c6540d9a7f6e26d8568ba2fc522cb865f0a6c, back in 2010. Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
* Revert "mapi: export all GLES 3.2 functions in libGLESv2.so"Dylan Baker2016-09-231-12/+0
| | | | | | | | | | | This reverts commit e66a2b879b73bf48800fec7353dafe8fc693ecdb. Which breaks the scons build in an interesting way, particularly when BlendBarrier and PrimitiveBoundingBox are added to static_data.py's functions list. This seems to be related to the fact that the unsuffixed names are only in GLES3.2, but Desktop GL only has suffixed versions. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
* mesa: add new entrypoints for GL_OES_viewport_arrayIlia Mirkin2016-09-222-6/+56
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
* mapi: export all GLES 3.2 functions in libGLESv2.soDylan Baker2016-09-221-0/+12
| | | | | | | | | See commit 5921f372c89a68fac6ddefc009442721d9df4db2 for the rational of this commit. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
* mapi: sort static_data.py functionsDylan Baker2016-09-221-2/+2
| | | | | | | | | | | Sorted by vim's builtin "sort i" (keeping the sorting case insensitive) v2: - uses case insensitive sorting (Ken) Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Acked-by: Ilia Mirkin <imirkin@alum.mit.edu> (v1) Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
* mapi: retab static_data.py to be consistentDylan Baker2016-09-221-1285/+1285
| | | | | | | | | | | | | This file currently uses a mixture of 3 and 4 space indent. I have changed it all to 4 space indent, matching the settings in $ROOT/.editorconfig. This was generated with sed: sed -i -e 's@^ "@ "@g' Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Acked-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
* direct-to-native-GL for GLX clients on Cygwin ("Windows-DRI")Jon Turney2016-09-152-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Structurally, this is very similar to the existing Apple-DRI code, except I have chosen to implement this using the __GLXDRIdisplay, etc. vtables (as suggested originally in [1]), rather than a maze of ifdefs. This also means that LIBGL_ALWAYS_SOFTWARE and LIBGL_ALWAYS_INDIRECT work as expected. [1] https://lists.freedesktop.org/archives/mesa-dev/2010-May/000756.html This adds: * the Windows-DRI extension protocol headers and the windowsdriproto.pc file, for use in building the Windows-DRI extension for the X server * a Windows-DRI extension helper client library * a Windows-specific DRI implementation for GLX clients The server is queried for Windows-DRI extension support on the screen before using it (to detect the case where WGL is disabled or can't be activated). The server is queried for fbconfigID to pixelformatindex mapping, which is used to augment glx_config. The server is queried for a native handle for the drawable (which is of a different type for windows, pixmaps and pbuffers), which is used to augment __GLXDRIdrawable. Various GLX extensions are enabled depending on if the equivalent WGL extension is available.
* mesa: introduce glPrimitiveBoundingBoxARB entrypointIlia Mirkin2016-09-132-19/+37
| | | | | | | | | This requires a bit of rejiggering, since normally ES entrypoints alias core ones, not vice-versa. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
* mapi: don't forget to expose GetPointerv in GL ES 3.2Ilia Mirkin2016-09-031-1/+1
| | | | | | | | I left this out of my previous commit that went around enabling all of the other ES 3.2 entrypoints. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* mesa: add scaffolding for OES/EXT_primitive_bounding_boxIlia Mirkin2016-08-302-0/+50
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* Update Khronos-supplied headers to r33100Ilia Mirkin2016-08-281-185/+1779
| | | | | | | | As retrieved from opengl.org and khronos.org. Maintained the APPLE hack in GL/glext.h manually. Added gl32.h. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Acked-by: Dave Airlie <airlied@redhat.com>
* mesa: Allow GL_EXT_geometry_shader and GL_EXT_geometry_point_sizeIan Romanick2016-08-261-0/+10
| | | | | | Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
* glapi: add KHR_blend_equation_advanced dispatchIlia Mirkin2016-08-251-0/+24
| | | | | | | | | | v2 (Ken): Fix enum values, drop _mesa_BlendBarrierKHR stub as Curro has already implemented it. v3 (Ken): Rework for _mesa_BlendBarrierKHR -> _mesa_BlendBarrier rename. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Francisco Jerez <currojerez@riseup.net>
* mesa: Rename "texturebarrier" source files to "barrier".Francisco Jerez2016-08-241-1/+1
| | | | | | | In preparation for collecting all pipeline barrier GL entry points into a single source file. Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
* glapi: Add XML for GL_EXT_shader_framebuffer_fetch.Francisco Jerez2016-08-241-0/+5
| | | | Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
* mesa: Document that _mesa_enum_to_string() returns non-null (v2)Chad Versace2016-08-121-1/+6
| | | | | | | | It always returns non-null, even if the number is an invalid enum. Cc: Haixia Shi <hshi@chromium.org> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Change-Id: I26e8843c96130be972e66f48a49e362442e1bf97
* mapi: Add PatchParameteriOES and PatchParameteriEXT.Kenneth Graunke2016-08-081-0/+10
| | | | | | | | | The OES_tessellation_shader and EXT_tessellation_shader specifications have suffixed names. These are identical to the core function, so just alias them. Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* mapi: Export all GLES 3.1 functions in libGLESv2.soIan Romanick2016-06-291-0/+51
| | | | | | | | | | | | | | | | | Khronos recommends that the GLES 3.1 library also be called libGLESv2. It also requires that functions be statically linkable from that library. NOTE: Mesa has supported the EGL_KHR_get_all_proc_addresses extension since at least Mesa 10.5, so applications targeting Linux should use eglGetProcAddress to avoid problems running binaries on systems with older, non-GLES 3.1 libGLESv2 libraries. Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Cc: "11.2 12.0" <mesa-stable@lists.freedesktop.org> Cc: Mike Gorchak <mike.gorchak.qnx@gmail.com> Reported-by: Mike Gorchak <mike.gorchak.qnx@gmail.com> Acked-by: Chad Versace <chad.versace@intel.com>
* glapi: add GL_EXT_window_rectangles entrypointsIlia Mirkin2016-06-183-0/+32
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Brian Paul <brianp@vmware.com>
* glapi: remap_helper.py: remove MESA_alt_functionsEmil Velikov2016-06-131-42/+0
| | | | | | | The final user was nuked with last commit. Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* mesa: add drawbuffer argument to ClearNamedFramebufferfiIlia Mirkin2016-06-101-0/+1
| | | | | | | | | | | This was fixed in revision 47 of the ARB_dsa spec in Oct 22, 2015. Since it's horrible to have differing APIs across library versions, we should attempt to minimize the impact by backporting it as far as possible and hope no one notices. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com> Cc: "11.2 12.0" <mesa-stable@lists.freedesktop.org>
* glapi/glx: Add overflow checks to the client-side indirect codeAdam Jackson2016-06-081-0/+9
| | | | | | | | | | | | | Coverity complains that the computed sizes can lead to negative lengths passed to memcpy. If that happens we've been handed invalid arguments anyway, so just bomb out. The funky "0%s" is because the size string for the variable-length part of the request is of the form "+ safe_pad() ...", and a unary + would coerce the result to always be positive, defeating the overflow check. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Matt Turner <mattst88@gmail.com>
* mapi: expose new functions in GL ES 3.2Ilia Mirkin2016-05-269-38/+38
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
* i965: Enable GL_KHR_robustnessKristian Høgsberg Kristensen2016-05-255-0/+136
| | | | | | | | | | | | | | | GL_KHR_robustness adds the GL_CONTEXT_LOST error and five new entry points that we already implement. This patch adds a new dispatch table that returns GL_CONTEXT_LOST from all entry points and implements the GL_LOSE_CONTEXT_ON_RESET strategy by setting that table when we learn that we've lost the context. With the GL_CONTEXT_LOST reporting in place and dispatch for the new entry points we can turn on GL_KHR_robustness. Signed-off-by: Kristian Høgsberg Kristensen <krh@bitplanet.net> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
* mesa: Implement glGet*(GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED).Kenneth Graunke2016-05-231-0/+1
| | | | | | | | | | | | | | | | | | | | | Technically, this was introduced with GL 4.4. However, I believe it was intended to be retroactive. As far as I know, AMD has never supported primitive restart with patches, while NVidia and Intel do. This necessitated the need for a query which would allow applications to figure out whether this was usable or not. I decided to expose it everywhere ARB_tessellation_shader is exposed. (It's also in both OES and EXT_tessellation_shader.) Enable this for i965 and Gallium drivers which expose the capability. v2: Fix a bug in the state_tracker code (caught by Ilia Mirkin). Bugzilla: https://cvs.khronos.org/bugzilla/show_bug.cgi?id=10364 Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* glapi/gen: Copy some GL 1.0 enum details into ARB_viewport_arrayAdam Jackson2016-05-171-4/+12
| | | | | | | | Otherwise the instances in the extension XML override the core definitions, and we stop knowing their sizes in indirect_size_get.c Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
* glapi: Define PURE for Sun Studio as wellAdam Jackson2016-05-171-1/+1
| | | | | Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
* glapi/glx: Mark byteswap functions as _X_UNUSED (v2)Adam Jackson2016-05-171-6/+6
| | | | | | | | | | Squashes the one remaining warning in the xserver build. v2: Also clean up some non-standard whitespace (Ian Romanick) Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
* glapi: Harden GLX request size processing (v2)Adam Jackson2016-05-175-19/+13
| | | | | | | v2: Use == not is for equality testing (Dylan Baker) Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
* glapi: Add the safe_{add,mul,pad} functions from xserverAdam Jackson2016-05-171-0/+24
| | | | | | | | We're about to update the generator scripts to use these, easier not to vary between client and server. Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
* glapi: Fix whitespace droppings when printing the license headerAdam Jackson2016-05-171-1/+1
| | | | | Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
* glapi: Add GL_ARB_cull_distanceTobias Klausmann2016-05-141-1/+6
| | | | | | | Signed-off-by: Tobias Klausmann <tobias.johannes.klausmann@mni.thm.de> Reviewed-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Reviewed-by: Kristian Høgsberg <krh@bitplanet.net> Signed-off-by: Dave Airlie <airlied@redhat.com>
* glapi: fix parameter type for GetSamplerParameterIuivEXT() in es_EXT.xmlBrian Paul2016-05-041-2/+2
| | | | | | | | | | The function returns GLuint, not GLfloat values. v2: also fix the OES function Cc: "11.2" <mesa-stable@lists.freedesktop.org> Reviewed-by: Charmaine Lee <charmainel@vmware.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
* glapi: Update dispatch XML files for OES_texture_compression_astc.xmlAnuj Phogat2016-05-033-0/+64
| | | | | Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com>
* mapi/glapi: Fix dup word typo in glapi_getproc.cEdward O'Callaghan2016-05-011-1/+1
| | | | | Signed-off-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* scons: Whenever possible decide what to do based on platform and not compiler.Jose Fonseca2016-04-261-2/+1
| | | | | | | | | | Because compilers like GCC and Clang are effectively available everywhere so their presence/absence is seldom conclusive. Furthermore, all compilers we use now have stdint.h. Reviewed-by: Roland Scheidegger <sroland@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com>
* glapi: fix _glapi_get_proc_address() for mangled function namesFrederic Devernay2016-04-251-12/+6
| | | | | | | | | | | In the dispatch table, all functions are stored without the "m" prefix. Modify code so that OSMesaGetProcAddress works both with gl and mgl prefixes. Similar to https://lists.freedesktop.org/archives/mesa-dev/2015-September/095251.html Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94994 Cc: "11.1 11.2" <mesa-stable@lists.freedesktop.org> Reviewed-by: Brian Paul <brianp@vmware.com>
* mesa: expose EXT_base_instance in ES3 contextsIlia Mirkin2016-04-031-0/+34
| | | | | | | | This extension is identical to ARB_base_instance. Reuse the same entrypoints. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Dave Airlie <airlied@redhat.com>
* mesa: expose EXT_polygon_offset_clamp in ES contextsIlia Mirkin2016-04-031-1/+1
| | | | | | | | The extension spec was extended to also support ES. This functionality is provided all the way back to ES 1.0. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Dave Airlie <airlied@redhat.com>
* mesa: add GL_OES/EXT_draw_buffers_indexed supportIlia Mirkin2016-03-311-0/+106
| | | | | | | | This is the same ext as ARB_draw_buffers_blend (plus some core functionality that already exists). Add the alias entrypoints. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Dave Airlie <airlied@redhat.com>
* mesa: add GL_EXT_copy_image supportIlia Mirkin2016-03-301-0/+22
| | | | | | | | The extension is identical to GL_OES_copy_image. But dEQP has tests that want the EXT variant. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Dave Airlie <airlied@redhat.com>
* mesa: add GL_OES_copy_image supportIlia Mirkin2016-03-301-0/+22
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Dave Airlie <airlied@redhat.com>
* mesa: add GL_OES_sample_shading supportIlia Mirkin2016-03-301-0/+6
| | | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Dave Airlie <airlied@redhat.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* glapi/glx: Mark the indirect swapped dispatch functions _X_COLDAdam Jackson2016-03-291-3/+3
| | | | | | | | | | | A modest size savings: text data bss dec hex filename 264143 15608 232 279983 445af libglx.so.before 254303 15608 232 270143 41f3f libglx.so.after Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
* glapi/glx: Sync some additional error checking from xserverAdam Jackson2016-03-291-0/+4
| | | | | Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
* mesa: add OES_texture_buffer and EXT_texture_buffer supportIlia Mirkin2016-03-282-2/+38
| | | | | | | | Allow ES 3.1 contexts to access the texture buffer functionality. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>