Marek Olšák
01c481335a
glthread: skip glMultMatrixf if it's identity
...
This is common with viewperf and it helps.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18828 >
2022-09-26 22:58:16 +00:00
Marek Olšák
cd30f044ae
glthread: use GLenum16 for enums, but clamp it to 0xffff to get correct errors
...
0xffff is an invalid enum.
This was initially implemented without clamping and then reverted because
of the concern that we would randomly get correct enums and not report
errors if we just dropped the high bits.
This packs calls better in glthread_batch.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18828 >
2022-09-26 22:58:16 +00:00
Marek Olšák
b7ba29cbf6
mesa: rename GL dispatch initialization functions to make the intent clear
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18828 >
2022-09-26 22:58:16 +00:00
Marek Olšák
34356c009c
api_hw_select_init_h.py: simplify the code
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18828 >
2022-09-26 22:58:16 +00:00
Marek Olšák
3c621f8a2a
glapi: rename 'vtxfmt' to 'beginend' to make it clear
...
These are really just the functions that execute between Begin/End.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18828 >
2022-09-26 22:58:16 +00:00
Marek Olšák
684dae9e64
mesa: initialize OutsideBeginEnd directly instead of through Exec
...
Exec is just a mutable pointer to one of the dispatch tables.
OutsideBeginEnd is what we are actually initializing here. This makes
the original intention clear.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18828 >
2022-09-26 22:58:16 +00:00
Marek Olšák
4ff207b47b
glthread: execute glSignalSemaphoreEXT synchronously
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18223 >
2022-09-21 14:54:50 +00:00
Marek Olšák
7c1f8b63ad
glthread: work around GL_INVALID_OPERATION with OpenGL ES 1.x draws
...
GLES1 only has (Multi)Draw{Array,Elements}, but glthread converts them
to the more complicated versions and then calls them through the dispatch,
which generated GL_INVALID_OPERATION.
Luckily, we can export them with the Internal prefix, so they are unlikely
to be used by apps by accident.
Acked-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18223 >
2022-09-21 14:54:50 +00:00
Marek Olšák
97891087b5
glthread: always sync for glShaderSource because invalid params can crash
...
If an invalid parameter is received along with an invalid pointer and we
ignore the invalid parameter and dereference the pointer, we crash.
Since we can't fully validate all parameters (such as whether "shader"
is a valid object ID), remove the custom code.
Acked-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18223 >
2022-09-21 14:54:49 +00:00
Marek Olšák
6b6f862170
glthread: generate errors for glGet functions between glBegin/End
...
Acked-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18223 >
2022-09-21 14:54:49 +00:00
Marek Olšák
355d575820
mesa: fix glDrawRangeElementsBaseVertex should be compiled into display list
...
It's defined in terms of glDrawRangeElements, which is compiled into display
lists.
Cc: stable
Acked-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18223 >
2022-09-21 14:54:49 +00:00
Jesse Natalie
d0a1c1a37d
mesa: Expose GL_NV_ES1_1_compatibility
...
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com >
Reviewed-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18217 >
2022-08-25 10:17:10 -07:00
Yonggang Luo
7981936e46
mapi: Improve comment about _glapi_tls_Dispatch and _glapi_tls_Context
...
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Acked-by: Jose Fonseca <jfonseca@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17814 >
2022-08-22 21:32:09 +00:00
Yonggang Luo
78ba0eb633
mapi: Access _glapi_tls_Dispatch directly without need of macro
...
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Acked-by: Jose Fonseca <jfonseca@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17814 >
2022-08-22 21:32:09 +00:00
Yonggang Luo
8e8a231a07
mapi: Move shared stub into u_current.c
...
These stub are:
_glapi_Dispatch
_glapi_Context
_glapi_destroy_multithread
_glapi_check_multithread
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Acked-by: Jose Fonseca <jfonseca@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17814 >
2022-08-22 21:32:09 +00:00
Yonggang Luo
7f49abbdc0
mapi: Move shared _glapi_set_context and _glapi_set_dispatch into u_current.c
...
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Acked-by: Jose Fonseca <jfonseca@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17814 >
2022-08-22 21:32:09 +00:00
Yonggang Luo
01d6ae536b
mapi: Remove reference to unused _gl_DispatchTSD
...
The last usage of _gl_DispatchTSD is at commit:
df98423f24 ("mapi: Prefix functions in u_current.h by u_current.")
Wow it's 12 years ago
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Acked-by: Jose Fonseca <jfonseca@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17814 >
2022-08-22 21:32:09 +00:00
Yonggang Luo
a5b463742c
mapi: Remove unused ENTRY_CURRENT_TABLE_GET
...
The last commit that use ENTRY_CURRENT_TABLE_GET is:
62a68481fa ("mapi: Remove usage of USE_ELF_TLS")
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Acked-by: Jose Fonseca <jfonseca@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17814 >
2022-08-22 21:32:09 +00:00
Marek Olšák
983684d763
glthread: track glBindFramebufferEXT, not just glBindFramebuffer
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17976 >
2022-08-12 06:06:48 +00:00
Marek Olšák
f9b0dc9377
glthread: track GL_READ_FRAMEBUFFER bindings too
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17976 >
2022-08-12 06:06:48 +00:00
Marek Olšák
28e351673e
glthread: call _mesa_glthread_DeleteBuffers unconditionally
...
Deleted buffers were not unbound in glthread.
Fixes: 4fa24747b9 - glthread: call _mesa_glthread_BindBuffer unconditionally
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17976 >
2022-08-12 06:06:48 +00:00
Marek Olšák
eb4036ea5b
glthread: unbind framebuffers in glDeleteFramebuffers
...
Tests:
dEQP-GLES2.functional.lifetime.delete_bound.framebuffer
dEQP-GLES2.functional.state_query.integers.framebuffer_binding_getinteger
Fixes: e48f676835 - glthread: don't sync for more glGetIntegerv enums for glretrace
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17976 >
2022-08-12 06:06:48 +00:00
Yonggang Luo
62a68481fa
mapi: Remove usage of USE_ELF_TLS
...
After commit c47fd3dc00 ("windows: Use TLS context/dispatch with shared-glapi")
USE_ELF_TLS are always defined by
pre_args += '-DUSE_ELF_TLS'
So we can remove it safety
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17213 >
2022-07-29 23:59:11 +00:00
Yonggang Luo
6bde428c0a
mapi: Trim trailing spaces in stub.c and u_current.c
...
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17213 >
2022-07-29 23:59:11 +00:00
Jesse Natalie
ddbbe96c88
Fix static glapi on Windows
...
On Linux, the static glapi path sees libGL.so implementing the static
glapi, and the drivers (libgallium_dri.so) updating/reading the TLS
vars.
On Windows, to allow libgallium_wgl.dll to be a full ICD, it's
responsible for implementing the actual static glapi. However, before
this change, OpenGL32.dll was also implementing the static glapi,
meaning that GL API calls from OpenGL32.dll didn't route to the driver
correctly because the TLS vars were never actually set - the driver set
its copy, and OpenGL32.dll read its own copy.
Now, always build a bridge and static version of glapi when not using
shared. The bridge version is linked into OpenGL32.dll, and the static
version is linked into the driver on Windows. GLES only builds with
shared glapi - but after this, shared glapi is not really needed on
Windows for GLES, since the driver has all of the data.
Fixes: f36921ef ("wgl: Refactor drivers to a libgallium_wgl.dll")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6560
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Dylan Baker <dylan@pnwbakers.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16713 >
2022-07-14 20:01:22 +00:00
Jesse Natalie
8f11c0553c
mapi: Add more EXT_external_objects_win32 functions/enums
...
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Acked-by: Marek Olák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17446 >
2022-07-14 03:45:16 +00:00
Adam Jackson
81b0862642
mesa: Stub out GL_APPLE_object_purgeable
...
There's slots in the glapi static dispatch table (which is still
arguably ABI) which we need to preserve, but we can stop exposing the
extension string or doing anything in the added functions.
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Acked-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17425 >
2022-07-11 16:37:34 -04:00
Yonggang Luo
1173c0f33a
meson: Using get_argument_syntax as the --compiler_id option for gen_vs_module_defs.py
...
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Dylan Baker <dylan@pnwbakers.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17065 >
2022-06-16 19:59:58 +00:00
Yonggang Luo
b2ddec4e98
c11: Implement c11/time.h with c11/impl/time.c
...
Create c11/time.h instead of put timespec_get in `c11/threads.h`
Creating impl folder is used to avoid `#include <time.h>` point the c11/time.h file
Detecting if `struct timespec` present with meson
Define TIME_UTC in `c11/time.h` instead `c11/threads.h`
Define `struct timespec` in `c11/time.h` when not present.
Implement timespec_get in c11/impl/time.c instead threads.h
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15497 >
2022-06-09 17:23:34 +00:00
Qiang Yu
90b34c9184
mapi: add api setup header for hw select mode
...
Used by GL_SELECT mode dispatch table setup.
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Signed-off-by: Qiang Yu <yuq825@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15765 >
2022-06-06 18:23:49 +00:00
Erik Faye-Lund
75f3373b34
mapi: remove needless c99_compat.h includes
...
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com >
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16812 >
2022-06-02 13:09:16 +00:00
Sidney Just
e1f6273763
mapi: added EXT_external_objects_win32 definitions
...
Includes implementation stubs
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15504 >
2022-05-15 19:56:49 +00:00
Yonggang Luo
a3a43e5fa8
win32: Do not use BUILD_GL32, we use def file to export win32 dll symbols.
...
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14041 >
2022-04-19 19:38:47 +00:00
Yonggang Luo
4ead2f6579
win32: Fixes 32 bits visual studio module definition files by add script gen_vs_module_defs.py
...
Getting opengl32*.def consistence with Windows SDK.
Getting osmesa.mingw.def's gl* functions consistence with Windows SDK.
stw_* functions are cdecl, not stdcall, so there is no need mangling the symbol.
Fixes egl.def for x86
d3d10sw: Move the place of d3d10_sw.def to d3d10_sw.def.in
Fixes vulkan_lvp.def for x86
Fixes #5552
Remove stdcall-fixup
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14041 >
2022-04-19 19:38:47 +00:00
Chia-I Wu
4fa24747b9
glthread: call _mesa_glthread_BindBuffer unconditionally
...
_mesa_marshal_GetIntegerv expects those states to be tracked. I am not
sure if this covers all states that _mesa_marshal_GetIntegerv needs, but
this fixes Civ5 for virgl at least.
Fixes: e48f676835 ("glthread: don't sync for more glGetIntegerv enums for glretrace")
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14659 >
2022-02-01 06:11:22 +00:00
Dave Airlie
ad2902cbbe
mapi: generate correct dispatch for EXT_draw_instanced
...
These APIs can be exposed in GLES2.0 via EXT_draw_instanced,
they were incorrectly being stuck on GLES 3.0 only.
Fixes piglit ext_draw_instanced-drawarrays
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14338 >
2022-01-03 21:37:34 +00:00
Qiang Yu
e1cecd8964
mesa: add ARB_sparse_texture extension
...
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Signed-off-by: Qiang Yu <yuq825@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14223 >
2021-12-30 16:11:19 +08:00
Qiang Yu
bcaf9704ad
glapi: should not add alias function to static_data.py
...
Alias function should not be assigned an offset, otherwise new added
function will get error:
Exception: entries are not ordered by slots
Fixes: 757bc6d37a ("mesa: Add support for EXT_clear_texture")
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Signed-off-by: Qiang Yu <yuq825@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14223 >
2021-12-30 16:11:19 +08:00
Marek Olšák
ae4065f0b2
mesa: use nop dispatch for ColorTable/Convolution/Histogram
...
The nop dispatch generates GL_INVALID_OPERATION too.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:29:00 -05:00
Marek Olšák
4c91c6162b
glapi: add missing no_error settings for implemented functions
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:28:49 -05:00
Marek Olšák
7b123ad16a
glthread: set marshal functions in dispatch only if they exist in the API
...
We now have proper nop dispatch for the unset functions.
The autogenerated code looks like this:
if ((ctx->API == API_OPENGLES2 && ctx->Version >= 31)) {
if (_gloffset_DepthRangeArrayfvOES >= 0)
((_glapi_proc *)(ctx->MarshalExec))[_gloffset_DepthRangeArrayfvOES] = (_glapi_proc)_mesa_marshal_DepthRangeArrayfvOES;
if (_gloffset_DepthRangeIndexedfOES >= 0)
((_glapi_proc *)(ctx->MarshalExec))[_gloffset_DepthRangeIndexedfOES] = (_glapi_proc)_mesa_marshal_DepthRangeIndexedfOES;
}
if (_mesa_is_desktop_gl(ctx)) {
if (_gloffset_AlphaToCoverageDitherControlNV >= 0)
((_glapi_proc *)(ctx->MarshalExec))[_gloffset_AlphaToCoverageDitherControlNV] = (_glapi_proc)_mesa_marshal_AlphaToCoverageDitherControlNV;
if (_gloffset_AttachObjectARB >= 0)
((_glapi_proc *)(ctx->MarshalExec))[_gloffset_AttachObjectARB] = (_glapi_proc)_mesa_marshal_AttachObjectARB;
if (_gloffset_BeginQueryIndexed >= 0)
((_glapi_proc *)(ctx->MarshalExec))[_gloffset_BeginQueryIndexed] = (_glapi_proc)_mesa_marshal_BeginQueryIndexed;
if (_gloffset_BindBufferOffsetEXT >= 0)
((_glapi_proc *)(ctx->MarshalExec))[_gloffset_BindBufferOffsetEXT] = (_glapi_proc)_mesa_marshal_BindBufferOffsetEXT;
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:42 -05:00
Marek Olšák
e93a9b422c
glthread: add nop dispatch
...
so that glthread behaves the same as the main dispatch.
Also fix the SetError function for GLES 1.0.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:40 -05:00
Marek Olšák
bade2407fa
mesa: remove GLvertexformat
...
Function pointers were first set in GLvertexformat, and then
GLvertexformat was copied to the dispatch.
This just sets the function pointers in the dispatch directly,
skipping the intermediate GLvertexformat structure.
The code with SET_* calls is autogenerated by api_vtxfmt_init_h.py.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:35 -05:00
Marek Olšák
a87e5d437e
glapi: autogenerate install_vtxfmt with python
...
This is a prerequisite for the GLvertexformat removal.
The autogenerated file looks like this:
if (_mesa_is_desktop_gl(ctx) || (ctx->API == API_OPENGLES2 && ctx->Version >= 30)) {
SET_VertexAttribI4iEXT(tab, NAME(VertexAttribI4iEXT));
SET_VertexAttribI4ivEXT(tab, NAME(VertexAttribI4ivEXT));
SET_VertexAttribI4uiEXT(tab, NAME(VertexAttribI4uiEXT));
SET_VertexAttribI4uivEXT(tab, NAME(VertexAttribI4uivEXT));
}
if (ctx->API == API_OPENGLES2) {
SET_VertexAttrib1fARB(tab, NAME_ES(VertexAttrib1fARB));
SET_VertexAttrib1fvARB(tab, NAME_ES(VertexAttrib1fvARB));
SET_VertexAttrib2fARB(tab, NAME_ES(VertexAttrib2fARB));
SET_VertexAttrib2fvARB(tab, NAME_ES(VertexAttrib2fvARB));
SET_VertexAttrib3fARB(tab, NAME_ES(VertexAttrib3fARB));
SET_VertexAttrib3fvARB(tab, NAME_ES(VertexAttrib3fvARB));
SET_VertexAttrib4fARB(tab, NAME_ES(VertexAttrib4fARB));
SET_VertexAttrib4fvARB(tab, NAME_ES(VertexAttrib4fvARB));
}
if (ctx->API == API_OPENGL_COMPAT) {
SET_ArrayElement(tab, NAME_AE(ArrayElement));
SET_Begin(tab, NAME(Begin));
SET_CallList(tab, NAME_CALLLIST(CallList));
SET_CallLists(tab, NAME_CALLLIST(CallLists));
SET_Color3b(tab, NAME(Color3b));
SET_Color3bv(tab, NAME(Color3bv));
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:29 -05:00
Marek Olšák
1f33948733
glapi: autogenerate all _mesa_* forward declarations in api_exec_decl.h
...
We could remove them from other header files now.
This purposefully omits "_exec" in _mesa_exec such as _mesa_exec_Begin
to make it pretty. Later commits will remove _exec from names, e.g. it
will become _mesa_Begin. The only other variants are really just
save_Begin (dlist) and _save_Begin (vbo).
The autogenerated file looks like this:
void GLAPIENTRY _mesa_NewList(GLuint list, GLenum mode);
void GLAPIENTRY _mesa_EndList(void);
void GLAPIENTRY _mesa_CallList(GLuint list);
void GLAPIENTRY _mesa_CallLists(GLsizei n, GLenum type, const GLvoid * lists);
void GLAPIENTRY _mesa_DeleteLists(GLuint list, GLsizei range);
GLuint GLAPIENTRY _mesa_GenLists(GLsizei range);
void GLAPIENTRY _mesa_ListBase(GLuint base);
void GLAPIENTRY _mesa_Begin(GLenum mode);
void GLAPIENTRY _mesa_Bitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte * bitmap);
void GLAPIENTRY _mesa_Color3b(GLbyte red, GLbyte green, GLbyte blue);
void GLAPIENTRY _mesa_Color3bv(const GLbyte * v);
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:25 -05:00
Marek Olšák
5603d3e42c
mesa: remove api_exec.h and move its contents into context.h
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:24 -05:00
Marek Olšák
898649c145
glapi: autogenerate api_save.h with save_* function declarations
...
This is planned to be used by glthread for its own dispatch mechanism.
The autogenerated file looks like this:
void GLAPIENTRY save_NewList(GLuint list, GLenum mode);
void GLAPIENTRY save_ListBase(GLuint base);
void GLAPIENTRY save_Bitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte * bitmap);
void GLAPIENTRY save_RasterPos2d(GLdouble x, GLdouble y);
void GLAPIENTRY save_RasterPos2dv(const GLdouble * v);
void GLAPIENTRY save_RasterPos2f(GLfloat x, GLfloat y);
void GLAPIENTRY save_RasterPos2fv(const GLfloat * v);
void GLAPIENTRY save_RasterPos2i(GLint x, GLint y);
void GLAPIENTRY save_RasterPos2iv(const GLint * v);
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:20 -05:00
Marek Olšák
df3447c331
glapi: autogenerate _mesa_initialize_save_table with python
...
The generated file looks like this:
SET_NewList(table, save_NewList);
SET_ListBase(table, save_ListBase);
SET_Bitmap(table, save_Bitmap);
SET_RasterPos2d(table, save_RasterPos2d);
SET_RasterPos2dv(table, save_RasterPos2dv);
SET_RasterPos2f(table, save_RasterPos2f);
SET_RasterPos2fv(table, save_RasterPos2fv);
SET_RasterPos2i(table, save_RasterPos2i);
SET_RasterPos2iv(table, save_RasterPos2iv);
SET_RasterPos2s(table, save_RasterPos2s);
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:19 -05:00
Marek Olšák
d7c5161242
glapi: move reusable glapi printing code to apiexec.py
...
This will be used by all new scripts.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:18 -05:00
Marek Olšák
77c2a7c2e4
glapi: replace dispatch.h inline functions with macros for faster compilation
...
A change in dispatch.h now takes 11.7% less user+sys time to compile.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14000 >
2021-12-14 12:00:11 -05:00