-
-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Godot Subview Architecture - Android #1064
Comments
This was implemented by godotengine/godot#39855, closing. |
Is the usage of this awesome feature documented somewhere? :-D |
@SilvanaP Did you find a way to do it ? |
No, unfortunately not :-/ |
@SilvanaP @madhawa-se Apologies for the delay. We'll be expanding Android related documentation, including the use of this feature in the coming weeks. |
Describe the project you are working on:
Enable the ability to embed Godot as a subview within an Android application.
Describe the problem or limitation you are having in your project:
As of version 3.2.2, the Godot Android architecture is based off the Android
FragmentActivity
component. Since an Android application typically only has a singleActivity
active at a time (especially sinceActivityGroup
was deprecated), with theActivity
's view driving the entire screen display , this results in the inability to embed Godot as a subcomponent within an Android application.Describe the feature / enhancement and how it helps to overcome the problem or limitation:
The goal of this proposal is to update the Godot Android architecture to support using Godot as a subcomponent.
Describe how your proposal will work, with code, pseudocode, mockups, and/or diagrams:
The entry point for Godot apps on Android is the
Godot.java
class. The class extendsFragmentActivity
in order to hook into theActivity
lifecycle which enables to update the app's screen display viasetContentView
and propagate key lifecycle callbacks to the Godot Engine.As such, we need an alternative that provides the ability to update the screen's display while also providing the Godot Engine with the expected Android lifecycle callbacks, and that is modular and can be combined with other components in a single activity.
Based on these requirements, Android
Fragments
appear to be the best tool for the job, and will be used as the basis for this work.If this enhancement will not be used often, can it be worked around with a few lines of script?:
This affects the architecture for Godot Android apps, and thus cannot be worked around via scripting logic.
Is there a reason why this should be core and not an add-on in the asset library?:
This affects the architecture for Godot Android apps, and thus cannot be provided via scripts and/or plugins.
The text was updated successfully, but these errors were encountered: