summaryrefslogtreecommitdiff
path: root/scene/3d
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-01-04 15:28:06 +0100
committerGitHub <noreply@github.com>2022-01-04 15:28:06 +0100
commit851fb16350644c710390e08aa521fac771db39fe (patch)
tree10afd703018cb7df1e035a286ccff07b537c9e70 /scene/3d
parentff211c8e5a91d35088e78a977e3dcc3de96e5278 (diff)
parentdf09bc38cb02d34946f07f9f3d48a60a3c87a1b9 (diff)
Merge pull request #56305 from Calinou/rename-lod-threshold
Diffstat (limited to 'scene/3d')
-rw-r--r--scene/3d/reflection_probe.cpp16
-rw-r--r--scene/3d/reflection_probe.h6
2 files changed, 11 insertions, 11 deletions
diff --git a/scene/3d/reflection_probe.cpp b/scene/3d/reflection_probe.cpp
index 9843729d84..be655e71db 100644
--- a/scene/3d/reflection_probe.cpp
+++ b/scene/3d/reflection_probe.cpp
@@ -76,13 +76,13 @@ float ReflectionProbe::get_max_distance() const {
return max_distance;
}
-void ReflectionProbe::set_lod_threshold(float p_pixels) {
- lod_threshold = p_pixels;
- RS::get_singleton()->reflection_probe_set_lod_threshold(probe, p_pixels);
+void ReflectionProbe::set_mesh_lod_threshold(float p_pixels) {
+ mesh_lod_threshold = p_pixels;
+ RS::get_singleton()->reflection_probe_set_mesh_lod_threshold(probe, p_pixels);
}
-float ReflectionProbe::get_lod_threshold() const {
- return lod_threshold;
+float ReflectionProbe::get_mesh_lod_threshold() const {
+ return mesh_lod_threshold;
}
void ReflectionProbe::set_extents(const Vector3 &p_extents) {
@@ -207,8 +207,8 @@ void ReflectionProbe::_bind_methods() {
ClassDB::bind_method(D_METHOD("set_max_distance", "max_distance"), &ReflectionProbe::set_max_distance);
ClassDB::bind_method(D_METHOD("get_max_distance"), &ReflectionProbe::get_max_distance);
- ClassDB::bind_method(D_METHOD("set_lod_threshold", "ratio"), &ReflectionProbe::set_lod_threshold);
- ClassDB::bind_method(D_METHOD("get_lod_threshold"), &ReflectionProbe::get_lod_threshold);
+ ClassDB::bind_method(D_METHOD("set_mesh_lod_threshold", "ratio"), &ReflectionProbe::set_mesh_lod_threshold);
+ ClassDB::bind_method(D_METHOD("get_mesh_lod_threshold"), &ReflectionProbe::get_mesh_lod_threshold);
ClassDB::bind_method(D_METHOD("set_extents", "extents"), &ReflectionProbe::set_extents);
ClassDB::bind_method(D_METHOD("get_extents"), &ReflectionProbe::get_extents);
@@ -240,7 +240,7 @@ void ReflectionProbe::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "interior"), "set_as_interior", "is_set_as_interior");
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "enable_shadows"), "set_enable_shadows", "are_shadows_enabled");
ADD_PROPERTY(PropertyInfo(Variant::INT, "cull_mask", PROPERTY_HINT_LAYERS_3D_RENDER), "set_cull_mask", "get_cull_mask");
- ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "lod_threshold", PROPERTY_HINT_RANGE, "0,1024,0.1"), "set_lod_threshold", "get_lod_threshold");
+ ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "mesh_lod_threshold", PROPERTY_HINT_RANGE, "0,1024,0.1"), "set_mesh_lod_threshold", "get_mesh_lod_threshold");
ADD_GROUP("Ambient", "ambient_");
ADD_PROPERTY(PropertyInfo(Variant::INT, "ambient_mode", PROPERTY_HINT_ENUM, "Disabled,Environment,Constant Color"), "set_ambient_mode", "get_ambient_mode");
diff --git a/scene/3d/reflection_probe.h b/scene/3d/reflection_probe.h
index 4b512e29d5..d0643496a4 100644
--- a/scene/3d/reflection_probe.h
+++ b/scene/3d/reflection_probe.h
@@ -60,7 +60,7 @@ private:
AmbientMode ambient_mode = AMBIENT_ENVIRONMENT;
Color ambient_color = Color(0, 0, 0);
float ambient_color_energy = 1.0;
- float lod_threshold = 1.0;
+ float mesh_lod_threshold = 1.0;
uint32_t cull_mask = (1 << 20) - 1;
UpdateMode update_mode = UPDATE_ONCE;
@@ -88,8 +88,8 @@ public:
void set_max_distance(float p_distance);
float get_max_distance() const;
- void set_lod_threshold(float p_pixels);
- float get_lod_threshold() const;
+ void set_mesh_lod_threshold(float p_pixels);
+ float get_mesh_lod_threshold() const;
void set_extents(const Vector3 &p_extents);
Vector3 get_extents() const;