gi stuff, static batching toggle
This commit is contained in:
@@ -282,6 +282,96 @@ namespace Game
|
||||
}
|
||||
}
|
||||
|
||||
[ConsoleVariable("r_gi_bounce")]
|
||||
public static string GlobalIlluminationBounce
|
||||
{
|
||||
get
|
||||
{
|
||||
return Graphics.PostProcessSettings.GlobalIllumination.BounceIntensity.ToString();
|
||||
}
|
||||
set
|
||||
{
|
||||
if (float.TryParse(value, out float valueFloat))
|
||||
{
|
||||
valueFloat = Mathf.Clamp(valueFloat, 0.0f, 999.0f);
|
||||
|
||||
PostProcessSettings postProcessSettings = Graphics.PostProcessSettings;
|
||||
|
||||
GlobalIlluminationSettings giSettings = postProcessSettings.GlobalIllumination;
|
||||
giSettings.BounceIntensity = valueFloat;
|
||||
postProcessSettings.GlobalIllumination = giSettings;
|
||||
|
||||
Graphics.PostProcessSettings = postProcessSettings;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[ConsoleVariable("r_gi_spacing")]
|
||||
public static string GlobalIlluminationProbeSpacing
|
||||
{
|
||||
get
|
||||
{
|
||||
return Graphics.GIProbesSpacing.ToString();
|
||||
}
|
||||
set
|
||||
{
|
||||
if (float.TryParse(value, out float valueFloat))
|
||||
{
|
||||
valueFloat = Mathf.Clamp(valueFloat, 0.0f, 999.0f);
|
||||
|
||||
Graphics.GIProbesSpacing = valueFloat;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[ConsoleVariable("r_gi_time")]
|
||||
public static string GlobalIlluminationTime
|
||||
{
|
||||
get
|
||||
{
|
||||
return Graphics.PostProcessSettings.GlobalIllumination.TemporalResponse.ToString();
|
||||
}
|
||||
set
|
||||
{
|
||||
if (float.TryParse(value, out float valueFloat))
|
||||
{
|
||||
valueFloat = Mathf.Clamp(valueFloat, 0.0f, 10.0f);
|
||||
|
||||
PostProcessSettings postProcessSettings = Graphics.PostProcessSettings;
|
||||
|
||||
GlobalIlluminationSettings giSettings = postProcessSettings.GlobalIllumination;
|
||||
giSettings.TemporalResponse = valueFloat;
|
||||
postProcessSettings.GlobalIllumination = giSettings;
|
||||
|
||||
Graphics.PostProcessSettings = postProcessSettings;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[ConsoleVariable("r_gi_distance")]
|
||||
public static string GlobalIlluminationDistance
|
||||
{
|
||||
get
|
||||
{
|
||||
return Graphics.PostProcessSettings.GlobalIllumination.Distance.ToString();
|
||||
}
|
||||
set
|
||||
{
|
||||
if (float.TryParse(value, out float valueFloat))
|
||||
{
|
||||
valueFloat = Mathf.Clamp(valueFloat, 0.0f, 10000000.0f);
|
||||
|
||||
PostProcessSettings postProcessSettings = Graphics.PostProcessSettings;
|
||||
|
||||
GlobalIlluminationSettings giSettings = postProcessSettings.GlobalIllumination;
|
||||
giSettings.Distance = valueFloat;
|
||||
postProcessSettings.GlobalIllumination = giSettings;
|
||||
|
||||
Graphics.PostProcessSettings = postProcessSettings;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[ConsoleVariable("r_shadows")]
|
||||
public static string SceneShadows
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user