Skip to content
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

low_processor_mode black screen on android when switching back to app #60465

Closed
Nazzaroth2 opened this issue Apr 23, 2022 · 2 comments · Fixed by #60506
Closed

low_processor_mode black screen on android when switching back to app #60465

Nazzaroth2 opened this issue Apr 23, 2022 · 2 comments · Fixed by #60506

Comments

@Nazzaroth2
Copy link

Godot version

3.5.beta4

System information

Android 12, GLES3, Samsung Galaxy S10+, Android SDK 31

Issue description

What happens:
When switching between android apps, or when minimizing all apps and reopening the godo-app the screen stays black. When a touch-sensitive object is on the screen, a new press on the screen refreshes and show the app-content again.

What should happen:
When switching back to the app the content should show up right away.

Additional Info:
As far as i have a recollection of these issues, this bug was also present before, just as the flickering issues. Those got fixed in the new beta-releases.
Before i made a custom build of godot with the forced-frame-redraw fix (sadly i can't remember what thread it was). That custom build did not have the black-screen issue the official beta-builds have.

Steps to reproduce

Using low_proccessor_mode in 3.5beta4 and exporting to android. Then switching to another app and back to godot-app.

Minimal reproduction project

No response

@Calinou
Copy link
Member

Calinou commented Apr 23, 2022

This was attempted to be fixed in #59606, but I guess it needs more work to cater to all situations.

cc @m4gr3d

@Calinou Calinou added this to the 3.5 milestone Apr 23, 2022
@fire fire changed the title low_proccesor_mode black screen on android when switching back to app low_processor_mode black screen on android when switching back to app Apr 23, 2022
@Nazzaroth2
Copy link
Author

alright, i played around a little bit more and found a workaround for this problem. If anyone needs a quick fix until the bug is correctly fixed try this:

depending on your setup either add a control-node that never gets deleted or make an autoloaded control node.
Then add this code to the node:

func _notification(what):
	if what == MainLoop.NOTIFICATION_WM_FOCUS_IN:
		if visible:
			self.hide()
		else:
			self.show()

This will toggle the visibility of the controlnode every time the app gets focused again, forcing a frame refresh (i guess?) and thus making sure the app gets shown immediatley.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants