diff options
author | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-10-20 17:06:59 +0200 |
---|---|---|
committer | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2022-08-01 02:00:16 +0200 |
commit | fa019f6e143e171ea730afe31888bd103bc3f080 (patch) | |
tree | 75e836a3139c7464126ca067e8c1641bb78a38c2 /scene/resources | |
parent | 14828c331c6ce44a90160fbe9892346c4970116d (diff) |
Change default material alpha scissor threshold to 0.5
This makes the default behavior consistent between SpriteBase3D,
BaseMaterial3D and imported glTF scene materials.
Alpha scissor threshold property hints now allows for more precise
adjustments as well.
Diffstat (limited to 'scene/resources')
-rw-r--r-- | scene/resources/material.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scene/resources/material.cpp b/scene/resources/material.cpp index fa3f3476e8..1d7e6f6470 100644 --- a/scene/resources/material.cpp +++ b/scene/resources/material.cpp @@ -2654,7 +2654,7 @@ void BaseMaterial3D::_bind_methods() { ADD_GROUP("Transparency", ""); ADD_PROPERTY(PropertyInfo(Variant::INT, "transparency", PROPERTY_HINT_ENUM, "Disabled,Alpha,Alpha Scissor,Alpha Hash,Depth Pre-Pass"), "set_transparency", "get_transparency"); - ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "alpha_scissor_threshold", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_alpha_scissor_threshold", "get_alpha_scissor_threshold"); + ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "alpha_scissor_threshold", PROPERTY_HINT_RANGE, "0,1,0.001"), "set_alpha_scissor_threshold", "get_alpha_scissor_threshold"); ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "alpha_hash_scale", PROPERTY_HINT_RANGE, "0,2,0.01"), "set_alpha_hash_scale", "get_alpha_hash_scale"); ADD_PROPERTY(PropertyInfo(Variant::INT, "alpha_antialiasing_mode", PROPERTY_HINT_ENUM, "Disabled,Alpha Edge Blend,Alpha Edge Clip"), "set_alpha_antialiasing", "get_alpha_antialiasing"); ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "alpha_antialiasing_edge", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_alpha_antialiasing_edge", "get_alpha_antialiasing_edge"); @@ -2986,7 +2986,7 @@ BaseMaterial3D::BaseMaterial3D(bool p_orm) : set_transparency(TRANSPARENCY_DISABLED); set_alpha_antialiasing(ALPHA_ANTIALIASING_OFF); - set_alpha_scissor_threshold(0.05); + set_alpha_scissor_threshold(0.5); set_alpha_hash_scale(1.0); set_alpha_antialiasing_edge(0.3); |