mirror of
https://github.com/ZDoom/qzdoom-gpl.git
synced 2024-12-11 12:51:27 +00:00
Merge branch 'master' of https://github.com/coelckers/gzdoom
This commit is contained in:
commit
367baf39a2
1 changed files with 9 additions and 2 deletions
|
@ -76,7 +76,11 @@
|
|||
//
|
||||
//==========================================================================
|
||||
CVAR(Bool, gl_bloom, false, CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
||||
CVAR(Float, gl_bloom_amount, 1.4f, 0)
|
||||
CUSTOM_CVAR(Float, gl_bloom_amount, 1.4f, 0)
|
||||
{
|
||||
if (self < 0.1f) self = 0.1f;
|
||||
}
|
||||
|
||||
CVAR(Float, gl_exposure, 0.0f, 0)
|
||||
|
||||
CUSTOM_CVAR(Int, gl_tonemap, 0, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
||||
|
@ -145,6 +149,7 @@ void FGLRenderer::BloomScene()
|
|||
mBloomExtractShader->Bind();
|
||||
mBloomExtractShader->SceneTexture.Set(0);
|
||||
mBloomExtractShader->Exposure.Set(mCameraExposure);
|
||||
mVBO->BindVBO();
|
||||
mVBO->RenderScreenQuad();
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
|
||||
|
@ -242,6 +247,7 @@ void FGLRenderer::TonemapScene()
|
|||
mTonemapShader->Bind();
|
||||
mTonemapShader->SceneTexture.Set(0);
|
||||
mTonemapShader->Exposure.Set(mCameraExposure);
|
||||
mVBO->BindVBO();
|
||||
mVBO->RenderScreenQuad();
|
||||
|
||||
if (blendEnabled)
|
||||
|
@ -351,7 +357,8 @@ void FGLRenderer::CopyToBackbuffer(const GL_IRECT *bounds, bool applyGamma)
|
|||
mPresentShader->Brightness.Set(clamp<float>(vid_brightness, -0.8f, 0.8f));
|
||||
}
|
||||
mBuffers->BindHudTexture(0);
|
||||
mVBO->RenderScreenQuad(width / (float)mBuffers->GetWidth(), height / (float)mBuffers->GetHeight());
|
||||
mVBO->BindVBO();
|
||||
mVBO->RenderScreenQuad(mScreenViewport.width / (float)mBuffers->GetWidth(), mScreenViewport.height / (float)mBuffers->GetHeight());
|
||||
|
||||
if (blendEnabled)
|
||||
glEnable(GL_BLEND);
|
||||
|
|
Loading…
Reference in a new issue