aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/dri/common')
-rw-r--r--src/mesa/drivers/dri/common/dri_util.c7
-rw-r--r--src/mesa/drivers/dri/common/dri_util.h9
2 files changed, 11 insertions, 5 deletions
diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c
index 31a3040365a..1cff0ddb2de 100644
--- a/src/mesa/drivers/dri/common/dri_util.c
+++ b/src/mesa/drivers/dri/common/dri_util.c
@@ -306,6 +306,7 @@ driCreateContextAttribs(__DRIscreen *screen, int api,
unsigned minor_version = 0;
uint32_t flags = 0;
bool notify_reset = false;
+ unsigned priority = __DRI_CTX_PRIORITY_MEDIUM;
assert((num_attribs == 0) || (attribs != NULL));
@@ -348,6 +349,9 @@ driCreateContextAttribs(__DRIscreen *screen, int api,
notify_reset = (attribs[i * 2 + 1]
!= __DRI_CTX_RESET_NO_NOTIFICATION);
break;
+ case __DRI_CTX_ATTRIB_PRIORITY:
+ priority = attribs[i * 2 + 1];
+ break;
default:
/* We can't create a context that satisfies the requirements of an
* attribute that we don't understand. Return failure.
@@ -451,7 +455,8 @@ driCreateContextAttribs(__DRIscreen *screen, int api,
if (!screen->driver->CreateContext(mesa_api, modes, context,
major_version, minor_version,
- flags, notify_reset, error, shareCtx)) {
+ flags, notify_reset, priority,
+ error, shareCtx)) {
free(context);
return NULL;
}
diff --git a/src/mesa/drivers/dri/common/dri_util.h b/src/mesa/drivers/dri/common/dri_util.h
index 25a3ae47a23..ecc2a475073 100644
--- a/src/mesa/drivers/dri/common/dri_util.h
+++ b/src/mesa/drivers/dri/common/dri_util.h
@@ -85,11 +85,12 @@ struct __DriverAPIRec {
GLboolean (*CreateContext)(gl_api api,
const struct gl_config *glVis,
__DRIcontext *driContextPriv,
- unsigned major_version,
- unsigned minor_version,
- uint32_t flags,
+ unsigned major_version,
+ unsigned minor_version,
+ uint32_t flags,
bool notify_reset,
- unsigned *error,
+ unsigned priority,
+ unsigned *error,
void *sharedContextPrivate);
void (*DestroyContext)(__DRIcontext *driContextPriv);