- Remove r_sprite_distance_cull

This commit is contained in:
Magnus Norddahl 2017-07-01 03:29:28 +02:00
parent 0cd575363f
commit 44546ce16a

View file

@ -72,20 +72,6 @@
EXTERN_CVAR(Bool, r_fullbrightignoresectorcolor);
EXTERN_CVAR(Bool, r_drawvoxels);
namespace { double sprite_distance_cull = 1e16; }
CUSTOM_CVAR(Float, r_sprite_distance_cull, 5000.0, CVAR_ARCHIVE | CVAR_GLOBALCONFIG)
{
if (r_sprite_distance_cull > 0.0)
{
sprite_distance_cull = r_sprite_distance_cull * r_sprite_distance_cull;
}
else
{
sprite_distance_cull = 1e16;
}
}
namespace swrenderer
{
RenderOpaquePass::RenderOpaquePass(RenderThread *thread) : renderline(thread)
@ -950,10 +936,6 @@ namespace swrenderer
if (!renderportal->CurrentPortalInSkybox && renderportal->CurrentPortal && !!P_PointOnLineSidePrecise(thing->Pos(), renderportal->CurrentPortal->dst))
return false;
double distanceSquared = (thing->Pos() - Thread->Viewport->viewpoint.Pos).LengthSquared();
if (distanceSquared > sprite_distance_cull)
return false;
return true;
}