diff options
Diffstat (limited to 'platform/android')
-rw-r--r-- | platform/android/display_server_android.cpp | 14 | ||||
-rw-r--r-- | platform/android/export/export_plugin.cpp | 4 | ||||
-rw-r--r-- | platform/android/java/app/config.gradle | 4 | ||||
-rw-r--r-- | platform/android/java/lib/AndroidManifest.xml | 3 | ||||
-rw-r--r-- | platform/android/java/lib/src/org/godotengine/godot/Godot.java | 2 | ||||
-rw-r--r-- | platform/android/os_android.cpp | 6 | ||||
-rw-r--r-- | platform/android/os_android.h | 2 |
7 files changed, 19 insertions, 16 deletions
diff --git a/platform/android/display_server_android.cpp b/platform/android/display_server_android.cpp index 720752d28f..34f0064a5e 100644 --- a/platform/android/display_server_android.cpp +++ b/platform/android/display_server_android.cpp @@ -344,8 +344,8 @@ void DisplayServerAndroid::process_events() { Vector<String> DisplayServerAndroid::get_rendering_drivers_func() { Vector<String> drivers; -#ifdef OPENGL_ENABLED - drivers.push_back("opengl"); +#ifdef GLES3_ENABLED + drivers.push_back("opengl3"); #endif #ifdef VULKAN_ENABLED drivers.push_back("vulkan"); @@ -407,13 +407,13 @@ DisplayServerAndroid::DisplayServerAndroid(const String &p_rendering_driver, Dis keep_screen_on = GLOBAL_GET("display/window/energy_saving/keep_screen_on"); -#if defined(OPENGL_ENABLED) - if (rendering_driver == "opengl") { +#if defined(GLES3_ENABLED) + if (rendering_driver == "opengl3") { bool gl_initialization_error = false; - if (RasterizerGLES2::is_viable() == OK) { - RasterizerGLES2::register_config(); - RasterizerGLES2::make_current(); + if (RasterizerGLES3::is_viable() == OK) { + RasterizerGLES3::register_config(); + RasterizerGLES3::make_current(); } else { gl_initialization_error = true; } diff --git a/platform/android/export/export_plugin.cpp b/platform/android/export/export_plugin.cpp index aa1aa4d264..5bd5648b6e 100644 --- a/platform/android/export/export_plugin.cpp +++ b/platform/android/export/export_plugin.cpp @@ -1612,11 +1612,11 @@ Vector<String> EditorExportPlatformAndroid::get_enabled_abis(const Ref<EditorExp void EditorExportPlatformAndroid::get_preset_features(const Ref<EditorExportPreset> &p_preset, List<String> *r_features) { String driver = ProjectSettings::get_singleton()->get("rendering/driver/driver_name"); - if (driver == "GLES2") { + if (driver == "opengl3") { r_features->push_back("etc"); } // FIXME: Review what texture formats are used for Vulkan. - if (driver == "Vulkan") { + if (driver == "vulkan") { r_features->push_back("etc2"); } diff --git a/platform/android/java/app/config.gradle b/platform/android/java/app/config.gradle index 3fafdf8573..2a2850df0f 100644 --- a/platform/android/java/app/config.gradle +++ b/platform/android/java/app/config.gradle @@ -1,8 +1,8 @@ ext.versions = [ androidGradlePlugin: '7.0.3', compileSdk : 30, - minSdk : 19, - targetSdk : 30, + minSdk : 19, // Also update 'platform/android/java/lib/AndroidManifest.xml#minSdkVersion' value + targetSdk : 30, // Also update 'platform/android/java/lib/AndroidManifest.xml#targetSdkVersion' value buildTools : '30.0.3', kotlinVersion : '1.5.10', fragmentVersion : '1.3.6', diff --git a/platform/android/java/lib/AndroidManifest.xml b/platform/android/java/lib/AndroidManifest.xml index 3034794d69..2de62271c4 100644 --- a/platform/android/java/lib/AndroidManifest.xml +++ b/platform/android/java/lib/AndroidManifest.xml @@ -4,6 +4,9 @@ android:versionCode="1" android:versionName="1.0"> + <!-- Should match the mindSdk and targetSdk values in platform/android/java/app/config.gradle --> + <uses-sdk android:minSdkVersion="19" android:targetSdkVersion="30" /> + <application> <!-- Records the version of the Godot library --> diff --git a/platform/android/java/lib/src/org/godotengine/godot/Godot.java b/platform/android/java/lib/src/org/godotengine/godot/Godot.java index 5de092ee7e..d39ab30cda 100644 --- a/platform/android/java/lib/src/org/godotengine/godot/Godot.java +++ b/platform/android/java/lib/src/org/godotengine/godot/Godot.java @@ -263,7 +263,7 @@ public class Godot extends Fragment implements SensorEventListener, IDownloaderC GodotLib.setup(command_line); final String videoDriver = GodotLib.getGlobal("rendering/driver/driver_name"); - if (videoDriver.equals("Vulkan")) { + if (videoDriver.equals("vulkan")) { mRenderView = new GodotVulkanRenderView(activity, this); } else { mRenderView = new GodotGLRenderView(activity, this, xrMode, use_32_bits, diff --git a/platform/android/os_android.cpp b/platform/android/os_android.cpp index 94ca51f75a..1a4c5ec00f 100644 --- a/platform/android/os_android.cpp +++ b/platform/android/os_android.cpp @@ -262,14 +262,14 @@ Size2i OS_Android::get_display_size() const { } void OS_Android::set_context_is_16_bits(bool p_is_16) { -#if defined(OPENGL_ENABLED) +#if defined(GLES3_ENABLED) //if (rasterizer) // rasterizer->set_force_16_bits_fbo(p_is_16); #endif } void OS_Android::set_opengl_extensions(const char *p_gl_extensions) { -#if defined(OPENGL_ENABLED) +#if defined(GLES3_ENABLED) ERR_FAIL_COND(!p_gl_extensions); gl_extensions = p_gl_extensions; #endif @@ -321,7 +321,7 @@ OS_Android::OS_Android(GodotJavaWrapper *p_godot_java, GodotIOJavaWrapper *p_god main_loop = nullptr; -#if defined(OPENGL_ENABLED) +#if defined(GLES3_ENABLED) gl_extensions = nullptr; use_gl2 = false; #endif diff --git a/platform/android/os_android.h b/platform/android/os_android.h index 9bb37325cf..d2e0e7d1e9 100644 --- a/platform/android/os_android.h +++ b/platform/android/os_android.h @@ -47,7 +47,7 @@ private: bool use_apk_expansion; -#if defined(OPENGL_ENABLED) +#if defined(GLES3_ENABLED) const char *gl_extensions; #endif |