Lines Matching defs:curProg

60 new_ati_fs(struct gl_context *ctx, struct ati_fragment_shader *curProg)
66 _mesa_init_gl_program(prog, MESA_SHADER_FRAGMENT, curProg->Id, true);
67 prog->ati_fs = curProg;
91 static void match_pair_inst(struct ati_fragment_shader *curProg, GLuint optype)
93 if (optype == curProg->last_optype) {
94 curProg->last_optype = ATI_FRAGMENT_SHADER_ALPHA_OP;
235 struct ati_fragment_shader *curProg = ctx->ATIFragmentShader.Current;
245 if (curProg->Id == id) {
250 if (curProg->Id != 0) {
251 curProg->RefCount--;
252 if (curProg->RefCount <= 0) {
378 struct ati_fragment_shader *curProg = ctx->ATIFragmentShader.Current;
387 if (curProg->interpinp1 && (ctx->ATIFragmentShader.Current->cur_pass > 1)) {
392 match_pair_inst(curProg, 0);
409 GLuint op = curProg->SetupInst[j][i].Opcode;
411 GLuint src = curProg->SetupInst[j][i].src;
412 GLuint swizzle = curProg->SetupInst[j][i].swizzle;
416 for (i = 0; i < curProg->numArithInstr[j]; i++) {
417 GLuint op0 = curProg->Instructions[j][i].Opcode[0];
418 GLuint op1 = curProg->Instructions[j][i].Opcode[1];
421 GLuint count0 = curProg->Instructions[j][i].ArgCount[0];
422 GLuint count1 = curProg->Instructions[j][i].ArgCount[1];
437 curProg->Program)) {
449 struct ati_fragment_shader *curProg = ctx->ATIFragmentShader.Current;
451 GLubyte new_pass = curProg->cur_pass;
458 if (curProg->cur_pass == 1)
461 ((1 << (dst - GL_REG_0_ATI)) & curProg->regsAssigned[new_pass >> 1])) {
490 if ((((curProg->swizzlerq >> (tmp * 2)) & 3) != 0) &&
491 (((swizzle & 1) + 1) != ((curProg->swizzlerq >> (tmp * 2)) & 3))) {
495 curProg->swizzlerq |= (((swizzle & 1) + 1) << (tmp * 2));
499 if (curProg->cur_pass == 1)
500 match_pair_inst(curProg, 0);
501 curProg->cur_pass = new_pass;
502 curProg->regsAssigned[curProg->cur_pass >> 1] |= 1 << (dst - GL_REG_0_ATI);
505 curI = &curProg->SetupInst[curProg->cur_pass >> 1][dst - GL_REG_0_ATI];
522 struct ati_fragment_shader *curProg = ctx->ATIFragmentShader.Current;
524 GLubyte new_pass = curProg->cur_pass;
531 if (curProg->cur_pass == 1)
534 ((1 << (dst - GL_REG_0_ATI)) & curProg->regsAssigned[new_pass >> 1])) {
564 if ((((curProg->swizzlerq >> (tmp * 2)) & 3) != 0) &&
565 (((swizzle & 1) + 1) != ((curProg->swizzlerq >> (tmp * 2)) & 3))) {
569 curProg->swizzlerq |= (((swizzle & 1) + 1) << (tmp * 2));
573 if (curProg->cur_pass == 1)
574 match_pair_inst(curProg, 0);
575 curProg->cur_pass = new_pass;
576 curProg->regsAssigned[curProg->cur_pass >> 1] |= 1 << (dst - GL_REG_0_ATI);
579 curI = &curProg->SetupInst[curProg->cur_pass >> 1][dst - GL_REG_0_ATI];
600 struct ati_fragment_shader *curProg = ctx->ATIFragmentShader.Current;
604 GLubyte new_pass = curProg->cur_pass;
612 if (curProg->cur_pass == 0)
614 else if (curProg->cur_pass == 2)
617 numArithInstr = curProg->numArithInstr[new_pass >> 1];
624 curProg->last_optype == optype ||
625 curProg->numArithInstr[new_pass >> 1] == 0) {
626 if (curProg->numArithInstr[new_pass >> 1] > 7) {
633 curI = &curProg->Instructions[new_pass >> 1][ci];
697 curProg->interpinp1 |= check_arg_color(new_pass, arg1);
699 curProg->interpinp1 |= check_arg_color(new_pass, arg2);
701 curProg->interpinp1 |= check_arg_color(new_pass, arg3);
703 curProg->numArithInstr[new_pass >> 1] = numArithInstr;
704 curProg->last_optype = optype;
705 curProg->cur_pass = new_pass;
825 struct ati_fragment_shader *curProg = ctx->ATIFragmentShader.Current;
826 COPY_4V(curProg->Constants[dstindex], value);
827 curProg->LocalConstDef |= 1 << dstindex;