1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00

Add warnings for unsupported features in mobile and gl_compatibility backends

This commit is contained in:
clayjohn
2023-02-25 16:24:41 -08:00
parent 84a80721c5
commit c69b14e96e
23 changed files with 170 additions and 48 deletions

View File

@@ -1914,12 +1914,6 @@ void BaseMaterial3D::_validate_feature(const String &text, Feature feature, Prop
}
}
void BaseMaterial3D::_validate_high_end(const String &text, PropertyInfo &property) const {
if (property.name.begins_with(text)) {
property.usage |= PROPERTY_USAGE_HIGH_END_GFX;
}
}
void BaseMaterial3D::_validate_property(PropertyInfo &p_property) const {
_validate_feature("normal", FEATURE_NORMAL_MAPPING, p_property);
_validate_feature("emission", FEATURE_EMISSION, p_property);
@@ -1933,10 +1927,6 @@ void BaseMaterial3D::_validate_property(PropertyInfo &p_property) const {
_validate_feature("refraction", FEATURE_REFRACTION, p_property);
_validate_feature("detail", FEATURE_DETAIL, p_property);
_validate_high_end("refraction", p_property);
_validate_high_end("subsurf_scatter", p_property);
_validate_high_end("heightmap", p_property);
if (p_property.name == "emission_intensity" && !GLOBAL_GET("rendering/lights_and_shadows/use_physical_light_units")) {
p_property.usage = PROPERTY_USAGE_NONE;
}