|
@@ -471,7 +471,7 @@ bool Environment::is_ssao_blur_enabled() const {
|
|
void Environment::set_glow_enabled(bool p_enabled) {
|
|
void Environment::set_glow_enabled(bool p_enabled) {
|
|
|
|
|
|
glow_enabled = p_enabled;
|
|
glow_enabled = p_enabled;
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
_change_notify();
|
|
_change_notify();
|
|
}
|
|
}
|
|
|
|
|
|
@@ -489,7 +489,7 @@ void Environment::set_glow_level(int p_level, bool p_enabled) {
|
|
else
|
|
else
|
|
glow_levels &= ~(1 << p_level);
|
|
glow_levels &= ~(1 << p_level);
|
|
|
|
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
bool Environment::is_glow_level_enabled(int p_level) const {
|
|
bool Environment::is_glow_level_enabled(int p_level) const {
|
|
|
|
|
|
@@ -502,7 +502,7 @@ void Environment::set_glow_intensity(float p_intensity) {
|
|
|
|
|
|
glow_intensity = p_intensity;
|
|
glow_intensity = p_intensity;
|
|
|
|
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
float Environment::get_glow_intensity() const {
|
|
float Environment::get_glow_intensity() const {
|
|
|
|
|
|
@@ -512,18 +512,18 @@ float Environment::get_glow_intensity() const {
|
|
void Environment::set_glow_strength(float p_strength) {
|
|
void Environment::set_glow_strength(float p_strength) {
|
|
|
|
|
|
glow_strength = p_strength;
|
|
glow_strength = p_strength;
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
float Environment::get_glow_strength() const {
|
|
float Environment::get_glow_strength() const {
|
|
|
|
|
|
return glow_strength;
|
|
return glow_strength;
|
|
}
|
|
}
|
|
|
|
|
|
-void Environment::set_glow_bloom(float p_treshold) {
|
|
|
|
|
|
+void Environment::set_glow_bloom(float p_threshold) {
|
|
|
|
|
|
- glow_bloom = p_treshold;
|
|
|
|
|
|
+ glow_bloom = p_threshold;
|
|
|
|
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
float Environment::get_glow_bloom() const {
|
|
float Environment::get_glow_bloom() const {
|
|
|
|
|
|
@@ -534,29 +534,29 @@ void Environment::set_glow_blend_mode(GlowBlendMode p_mode) {
|
|
|
|
|
|
glow_blend_mode = p_mode;
|
|
glow_blend_mode = p_mode;
|
|
|
|
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
Environment::GlowBlendMode Environment::get_glow_blend_mode() const {
|
|
Environment::GlowBlendMode Environment::get_glow_blend_mode() const {
|
|
|
|
|
|
return glow_blend_mode;
|
|
return glow_blend_mode;
|
|
}
|
|
}
|
|
|
|
|
|
-void Environment::set_glow_hdr_bleed_treshold(float p_treshold) {
|
|
|
|
|
|
+void Environment::set_glow_hdr_bleed_threshold(float p_threshold) {
|
|
|
|
|
|
- glow_hdr_bleed_treshold = p_treshold;
|
|
|
|
|
|
+ glow_hdr_bleed_threshold = p_threshold;
|
|
|
|
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
-float Environment::get_glow_hdr_bleed_treshold() const {
|
|
|
|
|
|
+float Environment::get_glow_hdr_bleed_threshold() const {
|
|
|
|
|
|
- return glow_hdr_bleed_treshold;
|
|
|
|
|
|
+ return glow_hdr_bleed_threshold;
|
|
}
|
|
}
|
|
|
|
|
|
void Environment::set_glow_hdr_bleed_scale(float p_scale) {
|
|
void Environment::set_glow_hdr_bleed_scale(float p_scale) {
|
|
|
|
|
|
glow_hdr_bleed_scale = p_scale;
|
|
glow_hdr_bleed_scale = p_scale;
|
|
|
|
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
float Environment::get_glow_hdr_bleed_scale() const {
|
|
float Environment::get_glow_hdr_bleed_scale() const {
|
|
|
|
|
|
@@ -566,7 +566,7 @@ float Environment::get_glow_hdr_bleed_scale() const {
|
|
void Environment::set_glow_bicubic_upscale(bool p_enable) {
|
|
void Environment::set_glow_bicubic_upscale(bool p_enable) {
|
|
|
|
|
|
glow_bicubic_upscale = p_enable;
|
|
glow_bicubic_upscale = p_enable;
|
|
- VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_treshold, glow_hdr_bleed_treshold, glow_bicubic_upscale);
|
|
|
|
|
|
+ VS::get_singleton()->environment_set_glow(environment, glow_enabled, glow_levels, glow_intensity, glow_strength, glow_bloom, VS::EnvironmentGlowBlendMode(glow_blend_mode), glow_hdr_bleed_threshold, glow_hdr_bleed_threshold, glow_bicubic_upscale);
|
|
}
|
|
}
|
|
|
|
|
|
bool Environment::is_glow_bicubic_upscale_enabled() const {
|
|
bool Environment::is_glow_bicubic_upscale_enabled() const {
|
|
@@ -1064,8 +1064,8 @@ void Environment::_bind_methods() {
|
|
ClassDB::bind_method(D_METHOD("set_glow_blend_mode", "mode"), &Environment::set_glow_blend_mode);
|
|
ClassDB::bind_method(D_METHOD("set_glow_blend_mode", "mode"), &Environment::set_glow_blend_mode);
|
|
ClassDB::bind_method(D_METHOD("get_glow_blend_mode"), &Environment::get_glow_blend_mode);
|
|
ClassDB::bind_method(D_METHOD("get_glow_blend_mode"), &Environment::get_glow_blend_mode);
|
|
|
|
|
|
- ClassDB::bind_method(D_METHOD("set_glow_hdr_bleed_treshold", "treshold"), &Environment::set_glow_hdr_bleed_treshold);
|
|
|
|
- ClassDB::bind_method(D_METHOD("get_glow_hdr_bleed_treshold"), &Environment::get_glow_hdr_bleed_treshold);
|
|
|
|
|
|
+ ClassDB::bind_method(D_METHOD("set_glow_hdr_bleed_threshold", "threshold"), &Environment::set_glow_hdr_bleed_threshold);
|
|
|
|
+ ClassDB::bind_method(D_METHOD("get_glow_hdr_bleed_threshold"), &Environment::get_glow_hdr_bleed_threshold);
|
|
|
|
|
|
ClassDB::bind_method(D_METHOD("set_glow_hdr_bleed_scale", "scale"), &Environment::set_glow_hdr_bleed_scale);
|
|
ClassDB::bind_method(D_METHOD("set_glow_hdr_bleed_scale", "scale"), &Environment::set_glow_hdr_bleed_scale);
|
|
ClassDB::bind_method(D_METHOD("get_glow_hdr_bleed_scale"), &Environment::get_glow_hdr_bleed_scale);
|
|
ClassDB::bind_method(D_METHOD("get_glow_hdr_bleed_scale"), &Environment::get_glow_hdr_bleed_scale);
|
|
@@ -1087,7 +1087,7 @@ void Environment::_bind_methods() {
|
|
ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_strength", PROPERTY_HINT_RANGE, "0.0,2.0,0.01"), "set_glow_strength", "get_glow_strength");
|
|
ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_strength", PROPERTY_HINT_RANGE, "0.0,2.0,0.01"), "set_glow_strength", "get_glow_strength");
|
|
ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_bloom", PROPERTY_HINT_RANGE, "0.0,1.0,0.01"), "set_glow_bloom", "get_glow_bloom");
|
|
ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_bloom", PROPERTY_HINT_RANGE, "0.0,1.0,0.01"), "set_glow_bloom", "get_glow_bloom");
|
|
ADD_PROPERTY(PropertyInfo(Variant::INT, "glow_blend_mode", PROPERTY_HINT_ENUM, "Additive,Screen,Softlight,Replace"), "set_glow_blend_mode", "get_glow_blend_mode");
|
|
ADD_PROPERTY(PropertyInfo(Variant::INT, "glow_blend_mode", PROPERTY_HINT_ENUM, "Additive,Screen,Softlight,Replace"), "set_glow_blend_mode", "get_glow_blend_mode");
|
|
- ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_hdr_treshold", PROPERTY_HINT_RANGE, "0.0,4.0,0.01"), "set_glow_hdr_bleed_treshold", "get_glow_hdr_bleed_treshold");
|
|
|
|
|
|
+ ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_hdr_threshold", PROPERTY_HINT_RANGE, "0.0,4.0,0.01"), "set_glow_hdr_bleed_threshold", "get_glow_hdr_bleed_threshold");
|
|
ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_hdr_scale", PROPERTY_HINT_RANGE, "0.0,4.0,0.01"), "set_glow_hdr_bleed_scale", "get_glow_hdr_bleed_scale");
|
|
ADD_PROPERTY(PropertyInfo(Variant::REAL, "glow_hdr_scale", PROPERTY_HINT_RANGE, "0.0,4.0,0.01"), "set_glow_hdr_bleed_scale", "get_glow_hdr_bleed_scale");
|
|
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "glow_bicubic_upscale"), "set_glow_bicubic_upscale", "is_glow_bicubic_upscale_enabled");
|
|
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "glow_bicubic_upscale"), "set_glow_bicubic_upscale", "is_glow_bicubic_upscale_enabled");
|
|
|
|
|
|
@@ -1185,7 +1185,7 @@ Environment::Environment() {
|
|
glow_strength = 1.0;
|
|
glow_strength = 1.0;
|
|
glow_bloom = 0.0;
|
|
glow_bloom = 0.0;
|
|
glow_blend_mode = GLOW_BLEND_MODE_SOFTLIGHT;
|
|
glow_blend_mode = GLOW_BLEND_MODE_SOFTLIGHT;
|
|
- glow_hdr_bleed_treshold = 1.0;
|
|
|
|
|
|
+ glow_hdr_bleed_threshold = 1.0;
|
|
glow_hdr_bleed_scale = 2.0;
|
|
glow_hdr_bleed_scale = 2.0;
|
|
glow_bicubic_upscale = false;
|
|
glow_bicubic_upscale = false;
|
|
|
|
|