mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-04 10:03:36 +00:00
Fix FrameBuffer::copyRdram(): fingerprint size must be not less than 4.
Fixed validity check for PD cloacking effect, #839
This commit is contained in:
parent
05cfca2ec6
commit
2054d9d689
|
@ -335,7 +335,7 @@ void FrameBuffer::copyRdram()
|
||||||
// This is necessary for auxilary buffers: game can restore content of RDRAM when buffer is not needed anymore
|
// This is necessary for auxilary buffers: game can restore content of RDRAM when buffer is not needed anymore
|
||||||
// Thus content of RDRAM on moment of buffer creation will be the same as when buffer becomes obsolete.
|
// Thus content of RDRAM on moment of buffer creation will be the same as when buffer becomes obsolete.
|
||||||
// Validity check will see that the RDRAM is the same and thus the buffer is valid, which is false.
|
// Validity check will see that the RDRAM is the same and thus the buffer is valid, which is false.
|
||||||
const u32 twoPercent = dataSize / 200;
|
const u32 twoPercent = max(4U, dataSize / 200);
|
||||||
u32 start = m_startAddress >> 2;
|
u32 start = m_startAddress >> 2;
|
||||||
u32 * pData = (u32*)RDRAM;
|
u32 * pData = (u32*)RDRAM;
|
||||||
for (u32 i = 0; i < twoPercent; ++i) {
|
for (u32 i = 0; i < twoPercent; ++i) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user