diff options
author | clayjohn <claynjohn@gmail.com> | 2020-09-14 23:47:07 -0700 |
---|---|---|
committer | clayjohn <claynjohn@gmail.com> | 2020-10-18 13:15:51 -0700 |
commit | 366ee4677487223015f1f7f92bf955452a5cf83f (patch) | |
tree | b58a460a385cd3b4ec1c3fb6a6e8d2071a184b37 /servers/rendering_server.cpp | |
parent | 4467412c9f78f3ddaf7edd4627ec7d629a6234df (diff) |
Replace SAO implementation with MSSAO
Diffstat (limited to 'servers/rendering_server.cpp')
-rw-r--r-- | servers/rendering_server.cpp | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/servers/rendering_server.cpp b/servers/rendering_server.cpp index b53415ed20..f88dd07ef4 100644 --- a/servers/rendering_server.cpp +++ b/servers/rendering_server.cpp @@ -1750,7 +1750,7 @@ void RenderingServer::_bind_methods() { ClassDB::bind_method(D_METHOD("environment_set_tonemap", "env", "tone_mapper", "exposure", "white", "auto_exposure", "min_luminance", "max_luminance", "auto_exp_speed", "auto_exp_grey"), &RenderingServer::environment_set_tonemap); ClassDB::bind_method(D_METHOD("environment_set_adjustment", "env", "enable", "brightness", "contrast", "saturation", "ramp"), &RenderingServer::environment_set_adjustment); ClassDB::bind_method(D_METHOD("environment_set_ssr", "env", "enable", "max_steps", "fade_in", "fade_out", "depth_tolerance"), &RenderingServer::environment_set_ssr); - ClassDB::bind_method(D_METHOD("environment_set_ssao", "env", "enable", "radius", "intensity", "bias", "light_affect", "ao_channel_affect", "blur", "bilateral_sharpness"), &RenderingServer::environment_set_ssao); + ClassDB::bind_method(D_METHOD("environment_set_ssao", "env", "enable", "rejection_radius", "intensity", "levels", "light_affect", "ao_channel_affect"), &RenderingServer::environment_set_ssao); ClassDB::bind_method(D_METHOD("environment_set_fog", "env", "enable", "light_color", "light_energy", "sun_scatter", "density", "height", "height_density", "aerial_perspective"), &RenderingServer::environment_set_fog); ClassDB::bind_method(D_METHOD("scenario_create"), &RenderingServer::scenario_create); @@ -2110,11 +2110,7 @@ void RenderingServer::_bind_methods() { BIND_ENUM_CONSTANT(ENV_SSR_ROUGNESS_QUALITY_MEDIUM); BIND_ENUM_CONSTANT(ENV_SSR_ROUGNESS_QUALITY_HIGH); - BIND_ENUM_CONSTANT(ENV_SSAO_BLUR_DISABLED); - BIND_ENUM_CONSTANT(ENV_SSAO_BLUR_1x1); - BIND_ENUM_CONSTANT(ENV_SSAO_BLUR_2x2); - BIND_ENUM_CONSTANT(ENV_SSAO_BLUR_3x3); - + BIND_ENUM_CONSTANT(ENV_SSAO_QUALITY_VERY_LOW); BIND_ENUM_CONSTANT(ENV_SSAO_QUALITY_LOW); BIND_ENUM_CONSTANT(ENV_SSAO_QUALITY_MEDIUM); BIND_ENUM_CONSTANT(ENV_SSAO_QUALITY_HIGH); @@ -2379,9 +2375,15 @@ RenderingServer::RenderingServer() { ProjectSettings::get_singleton()->set_custom_property_info("rendering/quality/depth_of_field/depth_of_field_bokeh_quality", PropertyInfo(Variant::INT, "rendering/quality/depth_of_field/depth_of_field_bokeh_quality", PROPERTY_HINT_ENUM, "Very Low (Fastest),Low (Fast),Medium (Average),High (Slow)")); GLOBAL_DEF("rendering/quality/depth_of_field/depth_of_field_use_jitter", false); - GLOBAL_DEF("rendering/quality/ssao/quality", 1); - ProjectSettings::get_singleton()->set_custom_property_info("rendering/quality/ssao/quality", PropertyInfo(Variant::INT, "rendering/quality/ssao/quality", PROPERTY_HINT_ENUM, "Low (Fast),Medium (Average),High (Slow),Ultra (Slower)")); - GLOBAL_DEF("rendering/quality/ssao/half_size", false); + GLOBAL_DEF("rendering/ssao/quality", 1); + ProjectSettings::get_singleton()->set_custom_property_info("rendering/ssao/quality", PropertyInfo(Variant::INT, "rendering/ssao/quality", PROPERTY_HINT_ENUM, "Very Low (Fastest),Low (Fast),Medium (Average),High (Slow),Ultra (Slower)")); + GLOBAL_DEF("rendering/ssao/full_samples", false); + GLOBAL_DEF("rendering/ssao/noise_tolerance", 0.625); + ProjectSettings::get_singleton()->set_custom_property_info("rendering/ssao/noise_tolerance", PropertyInfo(Variant::FLOAT, "rendering/ssao/noise_tolerance", PROPERTY_HINT_RANGE, "0.0,1.0,0.01")); + GLOBAL_DEF("rendering/ssao/blur_tolerance", 0.43); + ProjectSettings::get_singleton()->set_custom_property_info("rendering/ssao/blur_tolerance", PropertyInfo(Variant::FLOAT, "rendering/ssao/blur_tolerance", PROPERTY_HINT_RANGE, "0.0,1.0,0.01")); + GLOBAL_DEF("rendering/ssao/upsample_tolerance", 0.45); + ProjectSettings::get_singleton()->set_custom_property_info("rendering/ssao/upsample_tolerance", PropertyInfo(Variant::FLOAT, "rendering/ssao/upsample_tolerance", PROPERTY_HINT_RANGE, "0.0,1.0,0.01")); GLOBAL_DEF("rendering/quality/screen_filters/screen_space_roughness_limiter_enabled", true); GLOBAL_DEF("rendering/quality/screen_filters/screen_space_roughness_limiter_amount", 0.25); |