[Mesa-dev] [PATCH 08/39] st/nine: PositionT and Tessfactor are forbidden as PS input
Axel Davy
axel.davy at ens.fr
Sun May 15 10:45:22 UTC 2016
According to wine tests, they are forbidden as PS input,
which makes sense.
Signed-off-by: Axel Davy <axel.davy at ens.fr>
---
src/gallium/state_trackers/nine/nine_shader.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/src/gallium/state_trackers/nine/nine_shader.c b/src/gallium/state_trackers/nine/nine_shader.c
index 3045356..7c372dc 100644
--- a/src/gallium/state_trackers/nine/nine_shader.c
+++ b/src/gallium/state_trackers/nine/nine_shader.c
@@ -2052,11 +2052,13 @@ DECL_SPECIAL(DCL)
unsigned interp_location = 0;
/* SM3 only, SM2 input semantic determined by file */
assert(sem.reg.idx < Elements(tx->regs.v));
+ /* PositionT and tessfactor forbidden */
+ if (sem.usage == D3DDECLUSAGE_POSITIONT || sem.usage == D3DDECLUSAGE_TESSFACTOR)
+ return D3DERR_INVALIDCALL;
if (tgsi.Name == TGSI_SEMANTIC_POSITION) {
- /* Position0/PositionT0 are forbidden (likely because vPos already does that) */
- if (sem.usage == D3DDECLUSAGE_POSITION ||
- sem.usage == D3DDECLUSAGE_POSITIONT)
+ /* Position0 is forbidden (likely because vPos already does that) */
+ if (sem.usage == D3DDECLUSAGE_POSITION)
return D3DERR_INVALIDCALL;
/* Following code is for depth */
tx->regs.v[sem.reg.idx] = nine_get_position_input(tx);
--
2.8.2
More information about the mesa-dev
mailing list