diff options
author | Eric Anholt <[email protected]> | 2014-12-15 11:19:58 -0800 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2014-12-15 14:33:00 -0800 |
commit | 2142fd1f6f36ef9a384ef298fec02111dc826308 (patch) | |
tree | edb792a5d627d87da3a0638ca7657c4709f1003a /src/gallium/drivers/vc4/vc4_qir.h | |
parent | 214a169b3268bed63785d3e5953b24022f1beccb (diff) |
vc4: Add support for 8-bit unnormalized vertex attrs.
Diffstat (limited to 'src/gallium/drivers/vc4/vc4_qir.h')
-rw-r--r-- | src/gallium/drivers/vc4/vc4_qir.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc4/vc4_qir.h b/src/gallium/drivers/vc4/vc4_qir.h index c612b283b90..9da120ab912 100644 --- a/src/gallium/drivers/vc4/vc4_qir.h +++ b/src/gallium/drivers/vc4/vc4_qir.h @@ -114,6 +114,11 @@ enum qop { QOP_UNPACK_8C_F, QOP_UNPACK_8D_F, + QOP_UNPACK_8A_I, + QOP_UNPACK_8B_I, + QOP_UNPACK_8C_I, + QOP_UNPACK_8D_I, + /** Texture x coordinate parameter write */ QOP_TEX_S, /** Texture y coordinate parameter write */ @@ -497,6 +502,14 @@ qir_UNPACK_8_F(struct vc4_compile *c, struct qreg src, int i) } static inline struct qreg +qir_UNPACK_8_I(struct vc4_compile *c, struct qreg src, int i) +{ + struct qreg t = qir_get_temp(c); + qir_emit(c, qir_inst(QOP_UNPACK_8A_I + i, t, src, c->undef)); + return t; +} + +static inline struct qreg qir_POW(struct vc4_compile *c, struct qreg x, struct qreg y) { return qir_EXP2(c, qir_FMUL(c, |