Repository navigation
Conversation
Member
|
Ideally we would want to stop only the render part of the update when suspended, but that's much more complicated... This is a good solution I think until we can do that 👍 (unless the rendering rework offers a better solution?) Do you know if that fixes the similar issue on android? |
Member
|
bors try |
tryBuild failed: |
Contributor
Author
|
@mockersf I have not tested this on Android. |
Member
|
bors try |
tryBuild succeeded: |
mockersf
approved these changes
Jul 15, 2021
cart
approved these changes
Jul 16, 2021
cart
left a comment
Member
There was a problem hiding this comment.
This seems like a solid solution until we can decouple rendering from updates. I'm sold!
Member
|
bors r+ |
bors Bot
pushed a commit
that referenced
this pull request
Jul 16, 2021
# Objective This fixes a crash caused by iOS preventing GPU access when not focused: #2296 ## Solution This skips `app.update()` in `winit_runner` when `winit` sends the `Suspended` event, until `Resumed`. I've tested that this works for me on my iOS app.
Member
|
@HackerFoo could you comment on #2373 if you're ok with the license change? |
Contributor
Author
|
@mockersf Done. |
Member
|
thanks! |
|
Pull request successfully merged into main. Build succeeded: |
ostwilkens
pushed a commit
to ostwilkens/bevy
that referenced
this pull request
Jul 27, 2021
# Objective This fixes a crash caused by iOS preventing GPU access when not focused: bevyengine#2296 ## Solution This skips `app.update()` in `winit_runner` when `winit` sends the `Suspended` event, until `Resumed`. I've tested that this works for me on my iOS app.
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Objective
This fixes a crash caused by iOS preventing GPU access when not focused: #2296
Solution
This skips
app.update()inwinit_runnerwhenwinitsends theSuspendedevent, untilResumed.I've tested that this works for me on my iOS app.