mirror of
https://github.com/ZDoom/qzdoom.git
synced 2025-01-17 23:01:04 +00:00
Grab tanHalfFovy from the projection matrix
This commit is contained in:
parent
e025f6e54b
commit
11725c435e
1 changed files with 1 additions and 1 deletions
|
@ -158,7 +158,7 @@ void FGLRenderer::AmbientOccludeScene()
|
||||||
bool multisample = gl_multisample > 1;
|
bool multisample = gl_multisample > 1;
|
||||||
|
|
||||||
//float tanHalfFovy = tan(fovy * (M_PI / 360.0f));
|
//float tanHalfFovy = tan(fovy * (M_PI / 360.0f));
|
||||||
float tanHalfFovy = 1.0f / 1.33333302f; // 1.0f / gl_RenderState.mProjectionMatrix.get()[5];
|
float tanHalfFovy = 1.0f / gl_RenderState.mProjectionMatrix.get()[5];
|
||||||
float invFocalLenX = tanHalfFovy * (mBuffers->GetSceneWidth() / (float)mBuffers->GetSceneHeight());
|
float invFocalLenX = tanHalfFovy * (mBuffers->GetSceneWidth() / (float)mBuffers->GetSceneHeight());
|
||||||
float invFocalLenY = tanHalfFovy;
|
float invFocalLenY = tanHalfFovy;
|
||||||
float nDotVBias = clamp(bias, 0.0f, 1.0f);
|
float nDotVBias = clamp(bias, 0.0f, 1.0f);
|
||||||
|
|
Loading…
Reference in a new issue