|
@@ -1707,9 +1707,8 @@ void Graphics::SetDepthBias(float constantBias, float slopeScaledBias)
|
|
|
if (slopeScaledBias != 0.0f)
|
|
if (slopeScaledBias != 0.0f)
|
|
|
{
|
|
{
|
|
|
// OpenGL constant bias is unreliable and dependant on depth buffer bitdepth, apply in the projection matrix instead
|
|
// OpenGL constant bias is unreliable and dependant on depth buffer bitdepth, apply in the projection matrix instead
|
|
|
- float adjustedSlopeScaledBias = slopeScaledBias + 1.0f;
|
|
|
|
|
glEnable(GL_POLYGON_OFFSET_FILL);
|
|
glEnable(GL_POLYGON_OFFSET_FILL);
|
|
|
- glPolygonOffset(adjustedSlopeScaledBias, 0.0f);
|
|
|
|
|
|
|
+ glPolygonOffset(slopeScaledBias, 0.0f);
|
|
|
}
|
|
}
|
|
|
else
|
|
else
|
|
|
glDisable(GL_POLYGON_OFFSET_FILL);
|
|
glDisable(GL_POLYGON_OFFSET_FILL);
|