glx: Implement GLX_EXT_fbconfig_packed_float

The tokens for this are already defined by GLX_ARB_fbconfig_float, which
we already support, so just add the extension to the list and let the
driver provide those configs if it wants.

Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Adam Jackson <ajax@redhat.com>
(cherry picked from commit ef3005da3d)
This commit is contained in:
Adam Jackson 2016-01-21 12:47:57 -05:00
parent b9f7edda06
commit 3e480c6f51
4 changed files with 9 additions and 0 deletions

View File

@ -82,6 +82,7 @@ static const struct extension_info known_glx_extensions[] = {
{ GLX(EXT_create_context_es_profile), VER(0,0), N, },
{ GLX(EXT_create_context_es2_profile), VER(0,0), N, },
{ GLX(EXT_fbconfig_packed_float), VER(0,0), N, },
{ GLX(EXT_framebuffer_sRGB), VER(0,0), N, },
{ GLX(EXT_import_context), VER(0,0), Y, },
{ GLX(EXT_stereo_tree), VER(0,0), N, },

View File

@ -45,6 +45,7 @@ enum {
ARB_multisample_bit,
EXT_create_context_es_profile_bit,
EXT_create_context_es2_profile_bit,
EXT_fbconfig_packed_float_bit,
EXT_import_context_bit,
EXT_stereo_tree_bit,
EXT_texture_from_pixmap_bit,

View File

@ -895,6 +895,12 @@ initializeExtensions(__GLXDRIscreen * screen)
LogMessage(X_INFO, "AIGLX: enabled GLX_ARB_fbconfig_float\n");
}
/* enable EXT_fbconfig_packed_float (even if there are no packed float fbconfigs) */
{
__glXEnableExtension(screen->glx_enable_bits, "GLX_EXT_fbconfig_packed_float");
LogMessage(X_INFO, "AIGLX: enabled GLX_EXT_fbconfig_packed_float\n");
}
for (i = 0; extensions[i]; i++) {
if (strcmp(extensions[i]->name, __DRI_READ_DRAWABLE) == 0) {
__glXEnableExtension(screen->glx_enable_bits,

View File

@ -413,6 +413,7 @@ initializeExtensions(__GLXDRIscreen * screen)
/* these are harmless to enable unconditionally */
__glXEnableExtension(screen->glx_enable_bits, "GLX_EXT_framebuffer_sRGB");
__glXEnableExtension(screen->glx_enable_bits, "GLX_ARB_fbconfig_float");
__glXEnableExtension(screen->glx_enable_bits, "GLX_EXT_fbconfig_packed_float");
__glXEnableExtension(screen->glx_enable_bits, "GLX_SGI_make_current_read");
extensions = screen->core->getExtensions(screen->driScreen);