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

Correct RDRAMtoFrameBuffer::CopyFromRDRAM.

Need to set FBO of found buffer as current draw buffer, otherwise rendering can go
into wrong buffer.
This commit is contained in:
Sergey Lipskiy 2015-03-01 18:13:07 +06:00
parent 88e751b13b
commit 8a4db59a29

View File

@ -1118,8 +1118,10 @@ void RDRAMtoFrameBuffer::CopyFromRDRAM( u32 _address, bool _bUseAlpha)
gDPTile * pTile0 = gSP.textureTile[0];
gSP.textureTile[0] = &tile0;
glBindFramebuffer(GL_DRAW_FRAMEBUFFER, pBuffer->m_FBO);
OGLRender::TexturedRectParams params(0.0f, 0.0f, (float)width, (float)height, 0.0f, 0.0f, width - 1.0f, height - 1.0f, false);
video().getRender().drawTexturedRect(params);
glBindFramebuffer(GL_DRAW_FRAMEBUFFER, frameBufferList().getCurrent()->m_FBO);
gSP.textureTile[0] = pTile0;