mirror of
https://github.com/Lime3DS/Lime3DS
synced 2024-12-27 09:32:30 -06:00
Shader: implement SGE, SGEI in interpreter
This commit is contained in:
parent
a9fc659809
commit
863730f6a7
1 changed files with 14 additions and 0 deletions
|
@ -278,6 +278,20 @@ void RunInterpreter(UnitState<Debug>& state) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case OpCode::Id::SGE:
|
||||||
|
case OpCode::Id::SGEI:
|
||||||
|
Record<DebugDataRecord::SRC1>(state.debug, iteration, src1);
|
||||||
|
Record<DebugDataRecord::SRC2>(state.debug, iteration, src2);
|
||||||
|
Record<DebugDataRecord::DEST_IN>(state.debug, iteration, dest);
|
||||||
|
for (int i = 0; i < 4; ++i) {
|
||||||
|
if (!swizzle.DestComponentEnabled(i))
|
||||||
|
continue;
|
||||||
|
|
||||||
|
dest[i] = (src1[i] >= src2[i]) ? float24::FromFloat32(1.0f) : float24::FromFloat32(0.0f);
|
||||||
|
}
|
||||||
|
Record<DebugDataRecord::DEST_OUT>(state.debug, iteration, dest);
|
||||||
|
break;
|
||||||
|
|
||||||
case OpCode::Id::SLT:
|
case OpCode::Id::SLT:
|
||||||
case OpCode::Id::SLTI:
|
case OpCode::Id::SLTI:
|
||||||
Record<DebugDataRecord::SRC1>(state.debug, iteration, src1);
|
Record<DebugDataRecord::SRC1>(state.debug, iteration, src1);
|
||||||
|
|
Loading…
Reference in a new issue