playcanvas / playcanvas/engine
resizeCanvas() doesn't always work correctly
@slimbuck is already working on this.
Since Feb 3, 2020.
- Dominant language
- JavaScript
- Stars
- 16.8k
- Forks
- 2k
- Avg merge
- 4h 32m
- Merged PRs (30d)
- 222
Description
Description
We are facing a problem when we change the orientation of the mobile device on iOS in Safari - from portrait mode to landscape mode. All the contents of the applications squeezes randomly.
We have studied this issue and we realized that the function resizeCanvas() doesn't always work correctly after turning the screen. It seems that the function/resize triggers before Safari swaps height and width. We thought that maybe we could solve this issue by triggering the function ourselves after some timeout.
Is it possible to run resizeCanvas() in the namespace of user scripts?
As I understand this is also a known issue. Are there any solutions available?
URL: https://toyota.3dconfiguration.com/
Video: Video with bug
Device: iPhone X
Browser: Safari 12.4
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.