mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-03-12 06:50:32 +01:00
glx: Make #undef GLX_INDIRECT_RENDERING do something
Not that meson lets you reach this state yet, but if you did, you'd still build all of the indirect code but the linker would gc most of it. Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Reviewed-by: Eric Engestrom <eric@igalia.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33623>
This commit is contained in:
parent
259b73a3ae
commit
09bbf71e68
3 changed files with 8 additions and 0 deletions
|
|
@ -108,9 +108,11 @@ glXCreateContextAttribsARB(Display *dpy, GLXFBConfig config,
|
|||
(const uint32_t *) attrib_list,
|
||||
&error);
|
||||
} else if (!direct) {
|
||||
#ifdef GLX_INDIRECT_RENDERING
|
||||
gc = indirect_create_context_attribs(psc, cfg, share, num_attribs,
|
||||
(const uint32_t *) attrib_list,
|
||||
&error);
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -321,8 +321,10 @@ CreateContext(Display *dpy, int generic_id, struct glx_config *config,
|
|||
#else
|
||||
if (allowDirect && psc->vtable->create_context)
|
||||
gc = psc->vtable->create_context(psc, config, shareList, renderType);
|
||||
#ifdef GLX_INDIRECT_RENDERING
|
||||
if (!gc)
|
||||
gc = indirect_create_context(psc, config, shareList, renderType);
|
||||
#endif
|
||||
#endif
|
||||
if (!gc)
|
||||
return NULL;
|
||||
|
|
@ -1318,7 +1320,9 @@ glXImportContextEXT(Display *dpy, GLXContextID contextID)
|
|||
if (mode == NULL)
|
||||
return NULL;
|
||||
|
||||
#ifdef GLX_INDIRECT_RENDERING
|
||||
ctx = indirect_create_context(psc, mode, NULL, renderType);
|
||||
#endif
|
||||
if (ctx == NULL)
|
||||
return NULL;
|
||||
|
||||
|
|
|
|||
|
|
@ -916,7 +916,9 @@ AllocAndFetchScreenConfigs(Display * dpy, struct glx_display * priv, enum glx_dr
|
|||
#else
|
||||
if (psc == NULL && !zink)
|
||||
{
|
||||
#ifdef GLX_INDIRECT_RENDERING
|
||||
psc = indirect_create_screen(i, priv);
|
||||
#endif
|
||||
indirect = true;
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue