diff options
Diffstat (limited to 'src/mesa/drivers/dri/intel/intel_screen.c')
-rw-r--r-- | src/mesa/drivers/dri/intel/intel_screen.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri/intel/intel_screen.c index e1ec2eb013..f3592af621 100644 --- a/src/mesa/drivers/dri/intel/intel_screen.c +++ b/src/mesa/drivers/dri/intel/intel_screen.c @@ -714,6 +714,23 @@ intelCreateContext(gl_api api, struct intel_screen *intelScreen = sPriv->driverPrivate; bool success = false; + switch (api) { + case API_OPENGL: + case API_OPENGLES: + break; + case API_OPENGLES2: +#ifdef I915 + if (!IS_9XX(intelScreen->deviceID)) { + *error = __DRI_CTX_ERROR_BAD_API; + return false; + } +#endif + break; + case API_OPENGL_CORE: + *error = __DRI_CTX_ERROR_BAD_API; + return GL_FALSE; + } + #ifdef I915 if (IS_9XX(intelScreen->deviceID)) { if (!IS_965(intelScreen->deviceID)) { |