summaryrefslogtreecommitdiffstats
path: root/src/mesa/shader/program.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2005-11-01 04:36:33 +0000
committerBrian Paul <[email protected]>2005-11-01 04:36:33 +0000
commit05051037101dfa053798cf5ad91d1975fd1aa6a7 (patch)
tree0cf21bc55a1c006a6f7fa99d7613e73428598fee /src/mesa/shader/program.c
parentffec105109f5b16bfe8282bd477d4aa32b550015 (diff)
Re-org and clean-up of vertx/fragment program limits (instructions,
temporaries, parameters, etc). glGetProgramivARB() now returns all the right things. Updated i915 and r300 code to initialize program native limits and current program's native instruction/temporary/etc counts.
Diffstat (limited to 'src/mesa/shader/program.c')
-rw-r--r--src/mesa/shader/program.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/shader/program.c b/src/mesa/shader/program.c
index 70a9ced7a66..a054567e5fc 100644
--- a/src/mesa/shader/program.c
+++ b/src/mesa/shader/program.c
@@ -1291,7 +1291,7 @@ _mesa_GetProgramRegisterfvMESA(GLenum target,
if (reg[0] == 'R') {
/* Temp register */
GLint i = _mesa_atoi(reg + 1);
- if (i >= (GLint)ctx->Const.MaxVertexProgramTemps) {
+ if (i >= (GLint)ctx->Const.VertexProgram.MaxTemps) {
_mesa_error(ctx, GL_INVALID_VALUE,
"glGetProgramRegisterfvMESA(registerName)");
return;
@@ -1301,7 +1301,7 @@ _mesa_GetProgramRegisterfvMESA(GLenum target,
else if (reg[0] == 'v' && reg[1] == '[') {
/* Vertex Input attribute */
GLuint i;
- for (i = 0; i < ctx->Const.MaxVertexProgramAttribs; i++) {
+ for (i = 0; i < ctx->Const.VertexProgram.MaxAttribs; i++) {
const char *name = _mesa_nv_vertex_input_register_name(i);
char number[10];
_mesa_sprintf(number, "%d", i);
@@ -1355,7 +1355,7 @@ _mesa_GetProgramRegisterfvMESA(GLenum target,
if (reg[0] == 'R') {
/* Temp register */
GLint i = _mesa_atoi(reg + 1);
- if (i >= (GLint)ctx->Const.MaxFragmentProgramTemps) {
+ if (i >= (GLint)ctx->Const.FragmentProgram.MaxTemps) {
_mesa_error(ctx, GL_INVALID_VALUE,
"glGetProgramRegisterfvMESA(registerName)");
return;
@@ -1365,7 +1365,7 @@ _mesa_GetProgramRegisterfvMESA(GLenum target,
else if (reg[0] == 'f' && reg[1] == '[') {
/* Fragment input attribute */
GLuint i;
- for (i = 0; i < ctx->Const.MaxFragmentProgramAttribs; i++) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxAttribs; i++) {
const char *name = _mesa_nv_fragment_input_register_name(i);
if (_mesa_strncmp(reg + 2, name, 4) == 0) {
COPY_4V(v, ctx->FragmentProgram.Machine.Inputs[i]);