[cairo-commit] glitz/src/glx glitz_glx_context.c,1.2,1.3
David Reveman
commit at pdx.freedesktop.org
Thu Mar 10 14:45:33 PST 2005
Committed by: davidr
Update of /cvs/cairo/glitz/src/glx
In directory gabe:/tmp/cvs-serv26106/glx
Modified Files:
glitz_glx_context.c
Log Message:
Fix pixel offset issue and add temporary workaround for problem with NPOT textures
Index: glitz_glx_context.c
===================================================================
RCS file: /cvs/cairo/glitz/src/glx/glitz_glx_context.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- glitz_glx_context.c 25 Jan 2005 19:50:26 -0000 1.2
+++ glitz_glx_context.c 10 Mar 2005 22:45:30 -0000 1.3
@@ -192,6 +192,8 @@
_glitz_glx_context_initialize (glitz_glx_screen_info_t *screen_info,
glitz_glx_context_t *context)
{
+ const char *version;
+
glitz_backend_init (&context->backend,
glitz_glx_get_proc_address,
(void *) screen_info);
@@ -200,6 +202,21 @@
context->max_viewport_dims);
glitz_initiate_state (&_glitz_glx_gl_proc_address);
+
+ version = context->backend.gl.get_string (GLITZ_GL_VERSION);
+ if (version)
+ {
+ /* Having trouble with TexSubImage2D to NPOT GL_TEXTURE_2D textures when
+ using nvidia's binary driver. Seems like a driver issue, but I'm not
+ sure yet. Turning of NPOT GL_TEXTURE_2D textures until this have been
+ solved. */
+ if (strstr (version, "NVIDIA 61.11") ||
+ strstr (version, "NVIDIA 66.29"))
+ {
+ context->backend.feature_mask &=
+ ~GLITZ_FEATURE_TEXTURE_NON_POWER_OF_TWO_MASK;
+ }
+ }
context->initialized = 1;
}
More information about the cairo-commit
mailing list