mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-10 14:52:01 +00:00
- apply depth bias to translucent geometry.
This is necessary to handle wall and floor sprites placed on actual walls and floors work as intended.
This commit is contained in:
parent
b93502f0d0
commit
2d0360fa55
1 changed files with 3 additions and 1 deletions
|
@ -486,6 +486,8 @@ void HWDrawInfo::RenderTranslucent(FRenderState &state)
|
|||
{
|
||||
RenderAll.Clock();
|
||||
|
||||
state.SetDepthBias(-1, -128);
|
||||
|
||||
// final pass: translucent stuff
|
||||
state.AlphaFunc(Alpha_GEqual, gl_mask_sprite_threshold);
|
||||
state.SetRenderStyle(STYLE_Translucent);
|
||||
|
@ -497,7 +499,7 @@ void HWDrawInfo::RenderTranslucent(FRenderState &state)
|
|||
drawlists[GLDL_TRANSLUCENT].DrawSorted(this, state);
|
||||
state.EnableBrightmap(false);
|
||||
|
||||
|
||||
state.ClearDepthBias();
|
||||
state.AlphaFunc(Alpha_GEqual, 0.5f);
|
||||
state.SetDepthMask(true);
|
||||
|
||||
|
|
Loading…
Reference in a new issue