summaryrefslogtreecommitdiff
path: root/modules/noise
diff options
context:
space:
mode:
authorHaoyu Qiu <timothyqiu32@gmail.com>2022-04-20 10:44:00 +0800
committerHaoyu Qiu <timothyqiu32@gmail.com>2022-04-20 10:47:28 +0800
commit0e5c41857c1246501ea8bdd0c6455dc0f1a8170b (patch)
treeee128a538f43444d017b842268e7062e52115271 /modules/noise
parent7f384886ce65fb5deead17a3604a9f0b8917a9ee (diff)
Validate input in NoiseTexture::set_seamless_blend_skirt()
Diffstat (limited to 'modules/noise')
-rw-r--r--modules/noise/noise_texture.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/noise/noise_texture.cpp b/modules/noise/noise_texture.cpp
index 276335797a..f15d825b0c 100644
--- a/modules/noise/noise_texture.cpp
+++ b/modules/noise/noise_texture.cpp
@@ -241,6 +241,8 @@ bool NoiseTexture::get_seamless() {
}
void NoiseTexture::set_seamless_blend_skirt(real_t p_blend_skirt) {
+ ERR_FAIL_COND(p_blend_skirt < 0.05 || p_blend_skirt > 1);
+
if (p_blend_skirt == seamless_blend_skirt) {
return;
}