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

Fix scissor for post-processor.

Fixed buck bumble: bars on top and bottom of the screen (regression) #919
This commit is contained in:
Sergey Lipskiy 2016-03-31 17:52:01 +06:00
parent 91b48c9acd
commit a4e5d58459
2 changed files with 4 additions and 4 deletions

View File

@ -835,7 +835,6 @@ void FrameBufferList::renderBuffer(u32 _address)
dstCoord[0] += 1; // workaround for Adreno's issue with glBindFramebuffer;
#endif // GLESX
render.updateScissor(pBuffer);
PostProcessor::get().doGammaCorrection(pBuffer);
PostProcessor::get().doBlur(pBuffer);
glBindFramebuffer(GL_DRAW_FRAMEBUFFER, 0);

View File

@ -478,7 +478,7 @@ PostProcessor & PostProcessor::get()
return processor;
}
void _setGLState() {
void _setGLState(FrameBuffer * _pBuffer) {
glDisable(GL_DEPTH_TEST);
glDisable(GL_BLEND);
@ -499,13 +499,14 @@ void _setGLState() {
glDisableVertexAttribArray(SC_NUMLIGHTS);
glDisableVertexAttribArray(SC_MODIFY);
glViewport(0, 0, video().getWidth(), video().getHeight());
glScissor(0, 0, _pBuffer->m_pTexture->realWidth, _pBuffer->m_pTexture->realHeight);
gSP.changed |= CHANGED_VIEWPORT;
gDP.changed |= CHANGED_RENDERMODE;
gDP.changed |= CHANGED_RENDERMODE | CHANGED_SCISSOR;
}
void PostProcessor::_preDraw(FrameBuffer * _pBuffer)
{
_setGLState();
_setGLState(_pBuffer);
OGLVideo & ogl = video();
#ifdef GLES2