summaryrefslogtreecommitdiffstats
path: root/scene/resources/material.cpp
diff options
context:
space:
mode:
authorHugo Locurcio <hugo.locurcio@hugo.pro>2022-06-10 10:50:42 +0200
committerHugo Locurcio <hugo.locurcio@hugo.pro>2022-08-29 14:54:06 +0200
commit64717d64cdfa022078194537e2345602ccee354d (patch)
treef462e991dd1422faba3fbce49046a1c726d40efb /scene/resources/material.cpp
parente60086f98b07365d6174677df84c9a22bfb56d15 (diff)
downloadredot-engine-64717d64cdfa022078194537e2345602ccee354d.tar.gz
Improve documentation for BaseMaterial3D's alpha scissor threshold
Diffstat (limited to 'scene/resources/material.cpp')
-rw-r--r--scene/resources/material.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/scene/resources/material.cpp b/scene/resources/material.cpp
index bd0e470112..32ddef1693 100644
--- a/scene/resources/material.cpp
+++ b/scene/resources/material.cpp
@@ -2971,6 +2971,8 @@ BaseMaterial3D::BaseMaterial3D(bool p_orm) :
set_transparency(TRANSPARENCY_DISABLED);
set_alpha_antialiasing(ALPHA_ANTIALIASING_OFF);
+ // Alpha scissor threshold of 0.5 matches the glTF specification and Label3D default.
+ // <https://www.khronos.org/registry/glTF/specs/2.0/glTF-2.0.html#_material_alphacutoff>
set_alpha_scissor_threshold(0.5);
set_alpha_hash_scale(1.0);
set_alpha_antialiasing_edge(0.3);