mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-26 23:10:38 +00:00
Invert gstate.getClearModeColorMask().
It makes more sense matching gstate.getColorMask().
This commit is contained in:
parent
5817684e28
commit
21deaef35a
@ -232,7 +232,7 @@ struct GPUgstate
|
||||
bool isClearModeColorMask() const { return (clearmode&0x100) != 0; }
|
||||
bool isClearModeAlphaMask() const { return (clearmode&0x200) != 0; }
|
||||
bool isClearModeDepthMask() const { return (clearmode&0x400) != 0; }
|
||||
u32 getClearModeColorMask() const { return ((clearmode&0x100) ? 0xFFFFFF : 0) | ((clearmode&0x200) ? 0xFF000000 : 0); } // TODO: Different convention than getColorMask, confusing!
|
||||
u32 getClearModeColorMask() const { return ((clearmode&0x100) ? 0 : 0xFFFFFF) | ((clearmode&0x200) ? 0 : 0xFF000000); }
|
||||
|
||||
// Blend
|
||||
GEBlendSrcFactor getBlendFuncA() const { return (GEBlendSrcFactor)(blend & 0xF); }
|
||||
|
@ -983,7 +983,7 @@ void DrawTriangle(const VertexData& v0, const VertexData& v1, const VertexData&
|
||||
}
|
||||
|
||||
if (gstate.isModeClear()) {
|
||||
new_color = (new_color & gstate.getClearModeColorMask()) | (old_color & ~gstate.getClearModeColorMask());
|
||||
new_color = (new_color & ~gstate.getClearModeColorMask()) | (old_color & gstate.getClearModeColorMask());
|
||||
} else {
|
||||
new_color = (new_color & ~gstate.getColorMask()) | (old_color & gstate.getColorMask());
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user