[Mesa-dev] [PATCH 7/9] Support of RENDER_TYPE property [7/7] Require proper drawableType in init_fbconfig_for_chooser.

Tomasz Lis listom at gmail.com
Tue Jul 16 11:56:31 PDT 2013


glx: Require proper drawableType in init_fbconfig_for_chooser.

This patch makes sure that init_fbconfig_for_chooser sets correct
value of drawableType for visual configs and fbconfigs.
---
 src/glx/glxcmds.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/glx/glxcmds.c b/src/glx/glxcmds.c
index 502295f..42ca776 100644
--- a/src/glx/glxcmds.c
+++ b/src/glx/glxcmds.c
@@ -901,12 +901,17 @@ init_fbconfig_for_chooser(struct glx_config * config,
    config->visualID = (XID) GLX_DONT_CARE;
    config->visualType = GLX_DONT_CARE;
 
-   /* glXChooseFBConfig specifies different defaults for these two than
+   /* glXChooseFBConfig specifies different defaults for these properties than
     * glXChooseVisual.
     */
    if (fbconfig_style_tags) {
       config->rgbMode = GL_TRUE;
       config->doubleBufferMode = GLX_DONT_CARE;
+      /* allow any kind of drawable, including those for off-screen buffers */
+      config->drawableType = 0;
+   } else {
+       /* allow configs which support on-screen drawing */
+       config->drawableType = GLX_WINDOW_BIT;
    }
 
    config->visualRating = GLX_DONT_CARE;
-- 
1.7.9.5



More information about the mesa-dev mailing list