mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 19:30:11 +01:00
intel/blorp: Apply source offset in the TEX case
Previously the offset was only applied in the TXF case. Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Suggested-by: Jason Ekstrand <jason.ekstrand@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
This commit is contained in:
parent
990f2be139
commit
cbb941cdec
1 changed files with 3 additions and 0 deletions
|
|
@ -202,6 +202,9 @@ static nir_ssa_def *
|
|||
blorp_nir_tex(nir_builder *b, struct brw_blorp_blit_vars *v,
|
||||
const struct brw_blorp_blit_prog_key *key, nir_ssa_def *pos)
|
||||
{
|
||||
if (key->need_src_offset)
|
||||
pos = nir_fadd(b, pos, nir_i2f32(b, nir_load_var(b, v->v_src_offset)));
|
||||
|
||||
/* If the sampler requires normalized coordinates, we need to compensate. */
|
||||
if (key->src_coords_normalized)
|
||||
pos = nir_fmul(b, pos, nir_load_var(b, v->v_src_inv_size));
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue