diff options
author | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-12-29 02:06:12 +0100 |
---|---|---|
committer | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2022-01-14 21:08:22 +0100 |
commit | 40be15920f849100dbf5bf94a1d09e81bf05c6e4 (patch) | |
tree | 575410d96325f875e13b3a76c5eb4cde8fe0b6b5 /editor/editor_export.cpp | |
parent | 472b5b116742bbb1bdc8197c60efef57c7fd169f (diff) |
Remove support for PVRTC texture encoding and decoding
On the only platform where PVRTC is supported (iOS),
ETC2 generally supersedes PVRTC in every possible way. The increased
memory usage is not really a problem thanks to modern iOS' devices
processing power being higher than its Android counterparts.
Diffstat (limited to 'editor/editor_export.cpp')
-rw-r--r-- | editor/editor_export.cpp | 32 |
1 files changed, 4 insertions, 28 deletions
diff --git a/editor/editor_export.cpp b/editor/editor_export.cpp index 014e27ae15..f97973ce5d 100644 --- a/editor/editor_export.cpp +++ b/editor/editor_export.cpp @@ -1501,36 +1501,12 @@ void EditorExport::add_export_preset(const Ref<EditorExportPreset> &p_preset, in } String EditorExportPlatform::test_etc2() const { - // String driver = ProjectSettings::get_singleton()->get("rendering/driver/driver_name"); - // bool etc_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_etc"); - // bool etc2_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_etc2"); - String driver = ProjectSettings::get_singleton()->get("rendering/driver/driver_name"); - bool etc_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_etc"); - bool etc2_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_etc2"); - - if (driver == "opengl3" && !etc_supported) { - return TTR("Target platform requires 'ETC' texture compression for OpenGL. Enable 'Import Etc' in Project Settings."); - } else if (driver == "vulkan" && !etc2_supported) { - // FIXME: Review if this is true for Vulkan. - return TTR("Target platform requires 'ETC2' texture compression for Vulkan. Enable 'Import Etc 2' in Project Settings."); - } - return String(); -} + const bool etc2_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_etc2"); -String EditorExportPlatform::test_etc2_or_pvrtc() const { - String driver = ProjectSettings::get_singleton()->get("rendering/driver/driver_name"); - bool etc2_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_etc2"); - bool pvrtc_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_pvrtc"); - // String driver = ProjectSettings::get_singleton()->get("rendering/driver/driver_name"); - // bool etc2_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_etc2"); - // bool pvrtc_supported = ProjectSettings::get_singleton()->get("rendering/textures/vram_compression/import_pvrtc"); - - if (driver == "opengl3" && !pvrtc_supported) { - return TTR("Target platform requires 'PVRTC' texture compression for OpenGL. Enable 'Import Pvrtc' in Project Settings."); - } else if (driver == "vulkan" && !etc2_supported && !pvrtc_supported) { - // FIXME: Review if this is true for Vulkan. - return TTR("Target platform requires 'ETC2' or 'PVRTC' texture compression for Vulkan. Enable 'Import Etc 2' or 'Import Pvrtc' in Project Settings."); + if (!etc2_supported) { + return TTR("Target platform requires 'ETC2' texture compression. Enable 'Import Etc 2' in Project Settings."); } + return String(); } |