mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-12-02 02:33:43 +01:00
Tests say matrices apply mask to last col (kinda.)
It seems inconsistent but probably better than before. Also add an error.
This commit is contained in:
1 parent
6c479eb7ab
commit
179fccaff7
1 file changed
+11
-7
@@ -179,19 +179,23 @@ void WriteMatrix(const float *rd, MatrixSize size, int reg) {
|
||||
case M_4x4: row = (reg>>5)&2; side = 4; break;
|
||||
}
|
||||
|
||||
int transpose = (reg>>5)&1;
|
||||
int transpose = (reg>>5)&1;
|
||||
|
||||
if (currentMIPS->VfpuWriteMask() != 0) {
|
||||
ERROR_LOG(CPU, "Write mask used with vfpu matrix instruction.");
|
||||
}
|
||||
|
||||
for (int i=0; i<side; i++) {
|
||||
for (int j=0; j<side; j++) {
|
||||
// Hm, I wonder if this should affect matrices at all.
|
||||
if (!currentMIPS->VfpuWriteMask(i))
|
||||
if (j != side -1 || !currentMIPS->VfpuWriteMask(i))
|
||||
{
|
||||
int index = mtx * 4;
|
||||
int index = mtx * 4;
|
||||
if (transpose)
|
||||
index += ((row+i)&3) + ((col+j)&3)*32;
|
||||
else
|
||||
index += ((col+j)&3) + ((row+i)&3)*32;
|
||||
V(index) = rd[j*4+i];
|
||||
index += ((row+i)&3) + ((col+j)&3)*32;
|
||||
else
|
||||
index += ((col+j)&3) + ((row+i)&3)*32;
|
||||
V(index) = rd[j*4+i];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user