Skip to content

Commit

Permalink
Testing RCP(0) = 0 instead of clamp
Browse files Browse the repository at this point in the history
If that works we may need the same for rsq and log ?

Signed-off-by: Axel Davy <davyaxel0@gmail.com>
  • Loading branch information
axeldavy committed Mar 9, 2019
1 parent ce8bb0c commit 8c351cc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/gallium/state_trackers/nine/nine_shader.c
Original file line number Diff line number Diff line change
Expand Up @@ -2425,8 +2425,9 @@ DECL_SPECIAL(RCP)
struct ureg_dst tmp = tx->mul_zero_wins ? dst : tx_scratch(tx);
ureg_RCP(ureg, tmp, src);
if (!tx->mul_zero_wins) {
ureg_MIN(ureg, tmp, ureg_imm1f(ureg, FLT_MAX), ureg_src(tmp));
ureg_MAX(ureg, dst, ureg_imm1f(ureg, -FLT_MAX), ureg_src(tmp));
ureg_CMP(ureg, dst, ureg_negate(ureg_abs(src)), ureg_src(tmp), ureg_imm1f(ureg, 0.f));
//ureg_MIN(ureg, tmp, ureg_imm1f(ureg, FLT_MAX), ureg_src(tmp));
//ureg_MAX(ureg, dst, ureg_imm1f(ureg, -FLT_MAX), ureg_src(tmp));
}
return D3D_OK;
}
Expand Down

0 comments on commit 8c351cc

Please sign in to comment.