mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-23 19:10:21 +01:00
ir_to_mesa: When emitting a pixel kill, flag that we did so.
Both i965 and swrast rely on UsesKill to determine whether to do early depth writes. Fixes glsl-fs-discard-02. Bug #29835.
This commit is contained in:
parent
e38d2f7163
commit
9b075cb9fa
1 changed files with 3 additions and 0 deletions
|
|
@ -2041,9 +2041,12 @@ ir_to_mesa_visitor::visit(ir_return *ir)
|
|||
void
|
||||
ir_to_mesa_visitor::visit(ir_discard *ir)
|
||||
{
|
||||
struct gl_fragment_program *fp = (struct gl_fragment_program *)this->prog;
|
||||
|
||||
assert(ir->condition == NULL); /* FINISHME */
|
||||
|
||||
ir_to_mesa_emit_op0(ir, OPCODE_KIL_NV);
|
||||
fp->UsesKill = GL_TRUE;
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue