st/mesa: translate st_api robustness flags to gl_context flags
authorMarek Olšák <marek.olsak@amd.com>
Wed, 29 Apr 2015 15:54:26 +0000 (17:54 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Tue, 12 May 2015 17:38:45 +0000 (19:38 +0200)
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/state_tracker/st_manager.c

index 840f76a1307bddfe3e1e0b9fcb8cd10863ea2b37..0376954f74260fb75792853f3ff3d667e40ca1e5 100644 (file)
@@ -680,6 +680,10 @@ st_api_create_context(struct st_api *stapi, struct st_manager *smapi,
 
    if (attribs->flags & ST_CONTEXT_FLAG_FORWARD_COMPATIBLE)
       st->ctx->Const.ContextFlags |= GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT;
+   if (attribs->flags & ST_CONTEXT_FLAG_ROBUST_ACCESS)
+      st->ctx->Const.ContextFlags |= GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT_ARB;
+   if (attribs->flags & ST_CONTEXT_FLAG_RESET_NOTIFICATION_ENABLED)
+      st->ctx->Const.ResetStrategy = GL_LOSE_CONTEXT_ON_RESET_ARB;
 
    /* need to perform version check */
    if (attribs->major > 1 || attribs->minor > 0) {