1
0
mirror of https://github.com/blawar/GLideN64.git synced 2024-07-04 10:03:36 +00:00

Add check that depth image is inside RDRAM bound in DepthBufferToRDRAM::CopyToRDRAM

This commit is contained in:
Sergey Lipskiy 2015-04-01 12:33:28 +06:00
parent 81893e5520
commit 88acd219a0

View File

@ -947,6 +947,9 @@ bool DepthBufferToRDRAM::CopyToRDRAM( u32 _address) {
m_lastDList = RSP.DList;
DepthBuffer * pDepthBuffer = pBuffer->m_pDepthBuffer;
const u32 address = pDepthBuffer->m_address;
if (address + VI.width*VI.height*2 > RDRAMSize)
return false;
if (config.video.multisampling == 0)
glBindFramebuffer(GL_READ_FRAMEBUFFER, pBuffer->m_FBO);
else {