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

Fix WASM #4

Closed
wants to merge 74 commits into from
Closed

Conversation

Weibye
Copy link

@Weibye Weibye commented Aug 19, 2022

We have broken wasm in quite a few places, this is an attempt to fix that.

@Weibye Weibye marked this pull request as ready for review August 20, 2022 10:06
@Weibye Weibye mentioned this pull request Aug 20, 2022
@Weibye
Copy link
Author

Weibye commented Aug 20, 2022

@Aceeri This should now be ready to merge, but please review :)

Changes:

  • Bevy now compiles on wasm
  • Fix runtime panics on wasm
  • Fixed canvas-scaling
    • There are some odd behaviours around canvas scaling, but not sure if that is already existing or something we have added now
  • I think this should fully address regressions from [Merged by Bors] - Fix wasm examples bevyengine/bevy#4967

Note

  • I'm observing a canvas scaling issue where the height of the window is not correctly calculated. This is present on both main and on this branch so something we can fix later.
  • After our changes, the rate of update when rescaling has lowered. On main the window rescaling updates almost fully according to the resizing of the canvas.

new_windows,
winit_windows,
event_channel,
);
Copy link
Author

@Weibye Weibye Aug 20, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of this platform-specific code looks like a hot mess, I'm not completely sure how we can clean this up more?

@Aceeri Aceeri self-requested a review August 21, 2022 09:47
@Aceeri Aceeri force-pushed the windows-as-entities branch 3 times, most recently from 33e2306 to f4fe9c2 Compare November 20, 2022 22:33
@Aceeri
Copy link
Owner

Aceeri commented Nov 23, 2022

Went ahead and cherry picked the commits onto the main branch, so this is effectively merged :)

@Aceeri Aceeri closed this Nov 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants