It seems the commit below will always report an user error when
glxinfo -l is called.
And indeed I always get the following :
$ glxinfo -l
...
GL_VERTEX_PROGRAM_ARB:
...
Mesa: User error: GL_INVALID_ENUM in glGetProgramivARB(pname)
Mesa: User error: GL_INVALID_ENUM in glGetProgramivARB(pname)
Mesa: User error: GL_INVALID_ENUM in glGetProgramivARB(pname)
Mesa: User error: GL_INVALID_ENUM in glGetProgramivARB(pname)
Mesa: User error: GL_INVALID_ENUM in glGetProgramivARB(pname)
Mesa: User error: GL_INVALID_ENUM in glGetProgramivARB(pname)
Should glxinfo be fixed to avoid this error ?
We could just put the fragment program only parameter in its own list,
and not use them when target is vertex program.
commit 4bccd693a72a0b42dffc849034263a68e779ca91
Author: Ian Romanick <[email protected]>
Date: Mon Aug 24 12:48:01 2009 -0700
ARB prog: Set error instead of falling through with incorrect value
If a fragment program only parameter was queried of a vertex program
(e.g., GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB) no error would be set and
a random value would be returned. This caused 'glxinfo -l' to show
the same values for GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB,
GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB, GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB,
GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB,
GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB,
GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB as for
GL_MAX_PROGRAM_ENV_PARAMETERS_ARB. This is confusing and incorrect.
diff --git a/src/mesa/shader/arbprogram.c b/src/mesa/shader/arbprogram.c
index 39136ef..4d8cff0 100644
--- a/src/mesa/shader/arbprogram.c
+++ b/src/mesa/shader/arbprogram.c
@@ -1001,6 +1001,9 @@ _mesa_GetProgramivARB(GLenum target, GLenum
pname, GLint *params)
_mesa_error(ctx, GL_INVALID_ENUM, "glGetProgramivARB(pname)");
return;
}
+ } else {
+ _mesa_error(ctx, GL_INVALID_ENUM, "glGetProgramivARB(pname)");
+ return;
}
}
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Mesa3d-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev