Home | History | Annotate | Download | only in program

Lines Matching refs:Program

27  * NVIDIA fragment program parser.
44 #include "program.h"
140 * Remember, we can't modify the target program object until we've
141 * _successfully_ parsed the program text.
145 const GLubyte *start; /* start of program string */
148 struct gl_fragment_program *program; /* current program */
180 if (parseState->ctx->Program.ErrorString[0] == 0) {
757 * Parse a program local parameter register "p[##]"
771 /* a numbered program parameter register */
774 RETURN_ERROR1("Invalid constant program number");
1276 struct prog_instruction program[])
1279 struct prog_instruction *inst = program + parseState->numInst;
1459 RETURN_ERROR1("Program too long");
1468 * Parse/compile the 'str' returning the compiled 'program'.
1469 * ctx->Program.ErrorPos will be -1 if successful. Otherwise, ErrorPos
1475 struct gl_fragment_program *program)
1483 /* Make a null-terminated copy of the program string */
1496 parseState.program = program;
1504 /* check the program header */
1510 /* fragment / register combiner program - not supported */
1511 _mesa_set_program_error(ctx, 0, "Invalid fragment program header");
1517 _mesa_set_program_error(ctx, 0, "Invalid fragment program header");
1537 "Invalid fragment program - no outputs written.");
1550 /* install the program */
1551 program->Base.Target = target;
1552 if (program->Base.String) {
1553 FREE(program->Base.String);
1555 program->Base.String = programString;
1556 program->Base.Format = GL_PROGRAM_FORMAT_ASCII_ARB;
1557 if (program->Base.Instructions) {
1558 free(program->Base.Instructions);
1560 program->Base.Instructions = newInst;
1561 program->Base.NumInstructions = parseState.numInst;
1562 program->Base.InputsRead = parseState.inputsRead;
1563 program->Base.OutputsWritten = parseState.outputsWritten;
1565 program->Base.TexturesUsed[u] = parseState.texturesUsed[u];
1567 /* save program parameters */
1568 program->Base.Parameters = parseState.parameters;
1570 /* allocate registers for declared program parameters */
1572 _mesa_assign_program_registers(&(program->SymbolTable));
1576 printf("--- glLoadProgramNV(%d) result ---\n", program->Base.Id);
1577 _mesa_fprint_program_opt(stdout, &program->Base, PROG_PRINT_NV, 0);