diff options
author | Chia-I Wu <[email protected]> | 2011-10-23 18:52:38 +0800 |
---|---|---|
committer | Chia-I Wu <[email protected]> | 2011-11-03 15:09:45 +0800 |
commit | 0c87f16817ff0bf1f05e0d634944fd47b097faee (patch) | |
tree | 35549c03e8f4c41b90a31abf50b068271deff4a2 /src/mesa/main/get.c | |
parent | 79463f18ac91b2b0f1ed6dcdb26f84b942543d80 (diff) |
mesa: add support for GL_OES_EGL_image_external
This is an OpenGL ES specific extension. External textures are textures that
may be sampled from, but not be updated (no glTexSubImage* and etc.). The
image data are taken from an EGLImage.
Reviewed-by: Brian Paul <[email protected]>
Acked-by: Jakob Bornecrantz <[email protected]>
Diffstat (limited to 'src/mesa/main/get.c')
-rw-r--r-- | src/mesa/main/get.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mesa/main/get.c b/src/mesa/main/get.c index 8925b75ebee..d8a063876d8 100644 --- a/src/mesa/main/get.c +++ b/src/mesa/main/get.c @@ -332,6 +332,7 @@ EXTRA_EXT(ARB_color_buffer_float); EXTRA_EXT(ARB_copy_buffer); EXTRA_EXT(EXT_framebuffer_sRGB); EXTRA_EXT(ARB_texture_buffer_object); +EXTRA_EXT(OES_EGL_image_external); static const int extra_ARB_vertex_program_ARB_fragment_program_NV_vertex_program[] = { @@ -762,6 +763,12 @@ static const struct value_desc values[] = { { GL_SHADER_BINARY_FORMATS, CONST(0), NO_EXTRA }, #endif /* FEATURE_ES2 */ + /* GL_OES_EGL_image_external */ + { GL_TEXTURE_BINDING_EXTERNAL_OES, LOC_CUSTOM, + TYPE_INT, TEXTURE_EXTERNAL_INDEX, extra_OES_EGL_image_external }, + { GL_TEXTURE_EXTERNAL_OES, LOC_CUSTOM, + TYPE_BOOLEAN, 0, extra_OES_EGL_image_external }, + #if FEATURE_GL /* Remaining enums are only in OpenGL */ { 0, 0, TYPE_API_MASK, API_OPENGL_BIT, NO_EXTRA }, @@ -1419,6 +1426,7 @@ find_custom_value(struct gl_context *ctx, const struct value_desc *d, union valu case GL_TEXTURE_2D_ARRAY_EXT: case GL_TEXTURE_CUBE_MAP_ARB: case GL_TEXTURE_RECTANGLE_NV: + case GL_TEXTURE_EXTERNAL_OES: v->value_bool = _mesa_IsEnabled(d->pname); break; @@ -1596,6 +1604,7 @@ find_custom_value(struct gl_context *ctx, const struct value_desc *d, union valu case GL_TEXTURE_BINDING_2D_ARRAY_EXT: case GL_TEXTURE_BINDING_CUBE_MAP_ARB: case GL_TEXTURE_BINDING_RECTANGLE_NV: + case GL_TEXTURE_BINDING_EXTERNAL_OES: unit = ctx->Texture.CurrentUnit; v->value_int = ctx->Texture.Unit[unit].CurrentTex[d->offset]->Name; |