summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorTopi Pohjolainen <[email protected]>2013-11-29 13:27:58 +0200
committerTopi Pohjolainen <[email protected]>2014-01-23 08:45:49 +0200
commit44524cb42f9a2ce6571b8ca344cd5a7c6afd5702 (patch)
tree10195cd716e289e67555552a99886127208d0928 /src/mesa
parentf9d875926e47e30c8c57ee3e0491f5d720789d6c (diff)
i965/blorp: wrap FRC (/brw_FRC(&func, /emit_frc(/)
Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Paul Berry <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/i965/brw_blorp_blit.cpp8
-rw-r--r--src/mesa/drivers/dri/i965/brw_blorp_blit_eu.h6
2 files changed, 10 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp b/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp
index 2b9224bdb55..4d0b882f347 100644
--- a/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp
+++ b/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp
@@ -1413,8 +1413,8 @@ brw_blorp_blit_program::translate_dst_to_src()
/* Store the fractional parts to be used as bilinear interpolation
* coefficients.
*/
- brw_FRC(&func, x_frac, X_f);
- brw_FRC(&func, y_frac, Y_f);
+ emit_frc(x_frac, X_f);
+ emit_frc(y_frac, Y_f);
/* Round the float coordinates down to nearest integer */
brw_RNDD(&func, Xp_f, X_f);
@@ -1664,8 +1664,8 @@ brw_blorp_blit_program::manual_blend_bilinear(unsigned num_samples)
* | 6 | 7 | | 7 | 1 |
* --------- ---------
*/
- brw_FRC(&func, vec16(t1_f), x_sample_coords);
- brw_FRC(&func, vec16(t2_f), y_sample_coords);
+ emit_frc(vec16(t1_f), x_sample_coords);
+ emit_frc(vec16(t2_f), y_sample_coords);
emit_mul(vec16(t1_f), t1_f, brw_imm_f(key->x_scale));
emit_mul(vec16(t2_f), t2_f, brw_imm_f(key->x_scale * key->y_scale));
emit_add(vec16(t1_f), t1_f, t2_f);
diff --git a/src/mesa/drivers/dri/i965/brw_blorp_blit_eu.h b/src/mesa/drivers/dri/i965/brw_blorp_blit_eu.h
index c083ad8c9ff..f22207ddf83 100644
--- a/src/mesa/drivers/dri/i965/brw_blorp_blit_eu.h
+++ b/src/mesa/drivers/dri/i965/brw_blorp_blit_eu.h
@@ -137,6 +137,12 @@ protected:
brw_OR(&func, dst, src1, src2);
}
+ inline void emit_frc(const struct brw_reg& dst,
+ const struct brw_reg& src)
+ {
+ brw_FRC(&func, dst, src);
+ }
+
void *mem_ctx;
struct brw_compile func;
};