mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-28 11:49:06 +00:00
A simple z-buffer fix for the GL plugin, we were setting the nearz as negative nearz, which messed up the fzero stage in Melee at a certain point. Also redundent code moved about
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@685 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
3b346a7d47
commit
015e43340a
2 changed files with 13 additions and 16 deletions
|
@ -324,7 +324,7 @@ void VertexShaderMngr::SetConstants(VERTEXSHADER& vs)
|
|||
INFO_LOG("view: topleft=(%f,%f), wh=(%f,%f), z=(%f,%f)\n",rawViewport[3]-rawViewport[0]-342,rawViewport[4]+rawViewport[1]-342,
|
||||
2 * rawViewport[0], 2 * rawViewport[1], (rawViewport[5]-rawViewport[2])/16777215.0f, rawViewport[5]/16777215.0f);
|
||||
glViewport((int)(rawViewport[3]-rawViewport[0]-342) * MValueX,Renderer::GetTargetHeight()-((int)(rawViewport[4]-rawViewport[1]-342)) * MValueY, abs((int)(2 * rawViewport[0])) * MValueX, abs((int)(2 * rawViewport[1])) * MValueY);
|
||||
glDepthRange((rawViewport[5]-rawViewport[2])/16777215.0f, rawViewport[5]/16777215.0f);
|
||||
glDepthRange((rawViewport[5]-rawViewport[2])/-16777215.0f, rawViewport[5]/16777215.0f);
|
||||
}
|
||||
|
||||
if (bProjectionChanged) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue