mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-04 16:18:06 +02:00
changes to get DDX/DDY working again
This commit is contained in:
parent
62da6a1b3e
commit
60d136f63c
3 changed files with 10 additions and 0 deletions
|
|
@ -113,6 +113,10 @@ init_machine(GLcontext *ctx, struct gl_program_machine *machine,
|
|||
/* Setup pointer to input attributes */
|
||||
machine->Attribs = span->array->attribs;
|
||||
|
||||
machine->DerivX = (GLfloat (*)[4]) span->attrStepX;
|
||||
machine->DerivY = (GLfloat (*)[4]) span->attrStepY;
|
||||
machine->NumDeriv = FRAG_ATTRIB_MAX;
|
||||
|
||||
if (ctx->Shader.CurrentProgram) {
|
||||
/* Store front/back facing value in register FOGC.Y */
|
||||
machine->Attribs[FRAG_ATTRIB_FOGC][col][1] = (GLfloat) ctx->_Facing;
|
||||
|
|
|
|||
|
|
@ -1357,7 +1357,11 @@ shade_texture_span(GLcontext *ctx, SWspan *span)
|
|||
if ((inputsRead >= FRAG_BIT_VAR0) && (span->interpMask & SPAN_VARYING))
|
||||
interpolate_varying(ctx, span);
|
||||
|
||||
#if 0
|
||||
if (inputsRead & FRAG_BIT_WPOS)
|
||||
#else
|
||||
/* XXX always interpolate wpos so that DDX/DDY work */
|
||||
#endif
|
||||
interpolate_wpos(ctx, span);
|
||||
|
||||
/* Run fragment program/shader now */
|
||||
|
|
|
|||
|
|
@ -126,6 +126,8 @@ init_machine(GLcontext *ctx, struct gl_program_machine *machine)
|
|||
}
|
||||
}
|
||||
|
||||
machine->NumDeriv = 0;
|
||||
|
||||
/* init condition codes */
|
||||
machine->CondCodes[0] = COND_EQ;
|
||||
machine->CondCodes[1] = COND_EQ;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue