HLSL: phase 2d: minor cleanup, & allow operator[] on non-rw textures
Improve comments. A few tweaked lines allow [] on non-rw tx. Add test case for this. Improve VectorTimesScalar handling.
This commit is contained in:
parent
0de16da2c0
commit
07830e805b
8 changed files with 923 additions and 92 deletions
|
|
@ -2046,8 +2046,9 @@ bool TIntermBinary::promote()
|
|||
break;
|
||||
|
||||
case EOpVectorTimesScalarAssign:
|
||||
if (left->isVector() && right->isScalar())
|
||||
return true;
|
||||
if (!left->isVector() || !right->isScalar())
|
||||
return false;
|
||||
break;
|
||||
|
||||
default:
|
||||
return false;
|
||||
|
|
@ -2069,6 +2070,7 @@ bool TIntermBinary::promote()
|
|||
case EOpExclusiveOrAssign:
|
||||
case EOpLeftShiftAssign:
|
||||
case EOpRightShiftAssign:
|
||||
case EOpVectorTimesScalarAssign:
|
||||
if (getType() != left->getType())
|
||||
return false;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue