summaryrefslogtreecommitdiff
path: root/glx/glxdri2.c
diff options
context:
space:
mode:
authorTomasz Lis <tomasz.lis@intel.com>2013-03-11 10:21:28 +0100
committerKeith Packard <keithp@keithp.com>2013-03-18 10:02:00 -0700
commitcf89aa53748b964f9d9eceaa12a7d6f1a076d1ee (patch)
tree46c8e4ba7b451f64d96c3a9633178c297a029214 /glx/glxdri2.c
parent679ccecd8bc6d797e99f3b707f8041b727ca7a49 (diff)
Full support of sRGB capable fbconfigs.
Changes to correctly initialize the sRGB capability attribute and transfer it between XServer and the client. Modifications include extension string, transferring visual config attribs and fbconfig attribs. Also, attribute is initialized in the modules which do not really use it (xquartz and xwin). This version advertises both ARB and EXT strings, and initializes the capability to default value of FALSE. It has corrected required GLX version and does not influence swrast. The sRGB capable attribute is attached only to those configs which do have this capability. Both ARB and EXT versions share the same GLX extension enabling bit. Signed-off-by: Tomasz Lis <tomasz.lis@intel.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'glx/glxdri2.c')
-rw-r--r--glx/glxdri2.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/glx/glxdri2.c b/glx/glxdri2.c
index b26e501dc..8fba6a87d 100644
--- a/glx/glxdri2.c
+++ b/glx/glxdri2.c
@@ -882,6 +882,13 @@ initializeExtensions(__GLXDRIscreen * screen)
"AIGLX: enabled GLX_SGI_swap_control and GLX_MESA_swap_control\n");
}
+ /* enable EXT_framebuffer_sRGB extension (even if there are no sRGB capable fbconfigs) */
+ {
+ __glXEnableExtension(screen->glx_enable_bits,
+ "GLX_EXT_framebuffer_sRGB");
+ LogMessage(X_INFO, "AIGLX: enabled GLX_EXT_framebuffer_sRGB\n");
+ }
+
for (i = 0; extensions[i]; i++) {
#ifdef __DRI_READ_DRAWABLE
if (strcmp(extensions[i]->name, __DRI_READ_DRAWABLE) == 0) {