diff options
Diffstat (limited to 'src/mesa/program/arbprogparse.c')
-rw-r--r-- | src/mesa/program/arbprogparse.c | 64 |
1 files changed, 32 insertions, 32 deletions
diff --git a/src/mesa/program/arbprogparse.c b/src/mesa/program/arbprogparse.c index 82bdd133024..51cefe33faa 100644 --- a/src/mesa/program/arbprogparse.c +++ b/src/mesa/program/arbprogparse.c @@ -67,7 +67,7 @@ having three separate program parameter arrays. void _mesa_parse_arb_fragment_program(struct gl_context* ctx, GLenum target, const GLvoid *str, GLsizei len, - struct gl_fragment_program *program) + struct gl_program *program) { struct gl_program prog; struct asm_parser_state state; @@ -85,48 +85,48 @@ _mesa_parse_arb_fragment_program(struct gl_context* ctx, GLenum target, return; } - free(program->Base.String); + free(program->String); /* Copy the relevant contents of the arb_program struct into the * fragment_program struct. */ - program->Base.String = prog.String; - program->Base.NumInstructions = prog.NumInstructions; - program->Base.NumTemporaries = prog.NumTemporaries; - program->Base.NumParameters = prog.NumParameters; - program->Base.NumAttributes = prog.NumAttributes; - program->Base.NumAddressRegs = prog.NumAddressRegs; - program->Base.NumNativeInstructions = prog.NumNativeInstructions; - program->Base.NumNativeTemporaries = prog.NumNativeTemporaries; - program->Base.NumNativeParameters = prog.NumNativeParameters; - program->Base.NumNativeAttributes = prog.NumNativeAttributes; - program->Base.NumNativeAddressRegs = prog.NumNativeAddressRegs; - program->Base.NumAluInstructions = prog.NumAluInstructions; - program->Base.NumTexInstructions = prog.NumTexInstructions; - program->Base.NumTexIndirections = prog.NumTexIndirections; - program->Base.NumNativeAluInstructions = prog.NumAluInstructions; - program->Base.NumNativeTexInstructions = prog.NumTexInstructions; - program->Base.NumNativeTexIndirections = prog.NumTexIndirections; - program->Base.InputsRead = prog.InputsRead; - program->Base.OutputsWritten = prog.OutputsWritten; - program->Base.IndirectRegisterFiles = prog.IndirectRegisterFiles; + program->String = prog.String; + program->NumInstructions = prog.NumInstructions; + program->NumTemporaries = prog.NumTemporaries; + program->NumParameters = prog.NumParameters; + program->NumAttributes = prog.NumAttributes; + program->NumAddressRegs = prog.NumAddressRegs; + program->NumNativeInstructions = prog.NumNativeInstructions; + program->NumNativeTemporaries = prog.NumNativeTemporaries; + program->NumNativeParameters = prog.NumNativeParameters; + program->NumNativeAttributes = prog.NumNativeAttributes; + program->NumNativeAddressRegs = prog.NumNativeAddressRegs; + program->NumAluInstructions = prog.NumAluInstructions; + program->NumTexInstructions = prog.NumTexInstructions; + program->NumTexIndirections = prog.NumTexIndirections; + program->NumNativeAluInstructions = prog.NumAluInstructions; + program->NumNativeTexInstructions = prog.NumTexInstructions; + program->NumNativeTexIndirections = prog.NumTexIndirections; + program->InputsRead = prog.InputsRead; + program->OutputsWritten = prog.OutputsWritten; + program->IndirectRegisterFiles = prog.IndirectRegisterFiles; for (i = 0; i < MAX_TEXTURE_IMAGE_UNITS; i++) { - program->Base.TexturesUsed[i] = prog.TexturesUsed[i]; + program->TexturesUsed[i] = prog.TexturesUsed[i]; if (prog.TexturesUsed[i]) - program->Base.SamplersUsed |= (1 << i); + program->SamplersUsed |= (1 << i); } - program->Base.ShadowSamplers = prog.ShadowSamplers; + program->ShadowSamplers = prog.ShadowSamplers; program->OriginUpperLeft = state.option.OriginUpperLeft; program->PixelCenterInteger = state.option.PixelCenterInteger; - program->Base.info.fs.uses_discard = state.fragment.UsesKill; + program->info.fs.uses_discard = state.fragment.UsesKill; - free(program->Base.Instructions); - program->Base.Instructions = prog.Instructions; + free(program->Instructions); + program->Instructions = prog.Instructions; - if (program->Base.Parameters) - _mesa_free_parameter_list(program->Base.Parameters); - program->Base.Parameters = prog.Parameters; + if (program->Parameters) + _mesa_free_parameter_list(program->Parameters); + program->Parameters = prog.Parameters; /* Append fog instructions now if the program has "OPTION ARB_fog_exp" * or similar. We used to leave this up to drivers, but it appears @@ -145,7 +145,7 @@ _mesa_parse_arb_fragment_program(struct gl_context* ctx, GLenum target, } #if DEBUG_FP - printf("____________Fragment program %u ________\n", program->Base.Id); + printf("____________Fragment program %u ________\n", program->Id); _mesa_print_program(&program->Base); #endif } |