summaryrefslogtreecommitdiff
path: root/editor
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-03-06 00:57:49 +0100
committerGitHub <noreply@github.com>2019-03-06 00:57:49 +0100
commitb4d5c1ab5be236b3b2b9f6b3b5f3445a2285df72 (patch)
tree47c568523c3049d48f5f0dd9a2c14576d0d0aa29 /editor
parentd592ee6be880ff65287cf6279a769b522b3d94f8 (diff)
parentb0f782a0e323434df36276c87dfc4def1a93eade (diff)
Merge pull request #26633 from akien-mga/driver-fallback-etc
Disable driver fallback to GLES2 by default
Diffstat (limited to 'editor')
-rw-r--r--editor/editor_export.cpp16
1 files changed, 13 insertions, 3 deletions
diff --git a/editor/editor_export.cpp b/editor/editor_export.cpp
index 249bbb2a39..62c0228f6a 100644
--- a/editor/editor_export.cpp
+++ b/editor/editor_export.cpp
@@ -1163,13 +1163,23 @@ void EditorExport::add_export_preset(const Ref<EditorExportPreset> &p_preset, in
String EditorExportPlatform::test_etc2() const {
String driver = ProjectSettings::get_singleton()->get("rendering/quality/driver/driver_name");
+ bool driver_fallback = ProjectSettings::get_singleton()->get("rendering/quality/driver/fallback_to_gles2");
bool etc_supported = ProjectSettings::get_singleton()->get("rendering/vram_compression/import_etc");
bool etc2_supported = ProjectSettings::get_singleton()->get("rendering/vram_compression/import_etc2");
if (driver == "GLES2" && !etc_supported) {
- return TTR("Target platform requires 'ETC' texture compression for GLES2. Enable 'rendering/vram_compression/import_etc' in Project Settings.");
- } else if (driver == "GLES3" && !etc2_supported) {
- return TTR("Target platform requires 'ETC2' texture compression for GLES3. Enable 'rendering/vram_compression/import_etc2' in Project Settings.");
+ return TTR("Target platform requires 'ETC' texture compression for GLES2. Enable 'Import Etc' in Project Settings.");
+ } else if (driver == "GLES3") {
+ String err;
+ if (!etc2_supported) {
+ err += TTR("Target platform requires 'ETC2' texture compression for GLES3. Enable 'Import Etc 2' in Project Settings.");
+ }
+ if (driver_fallback && !etc_supported) {
+ if (err != String())
+ err += "\n";
+ err += TTR("Target platform requires 'ETC' texture compression for the driver fallback to GLES2.\nEnable 'Import Etc' in Project Settings, or disable 'Driver Fallback Enabled'.");
+ }
+ return err;
}
return String();
}