bevyengine / bevyengine/bevy

Bevy ignores explicit canvas size on web/webgpu platform

Open
#20,164 1 comment 0 reactions 0 assignees View on GitHub
A-Windowing O-Web
Dominant language
Rust
Stars
48.2k
Forks
4.8k
Avg merge
3d 22h
Merged PRs (30d)
161

Description

## Bevy version

0.16.1

## What you did

I specify a specific width/height on an HTML canvas
``````,
I set the canvas id on my primary window:
```rust
app.add_plugins((DefaultPlugins.set(WindowPlugin {
primary_window: Some(Window {
canvas: Some("#bevy-canvas".into()),
..default()
}),
..default()
})
```

## What went wrong

Bevy resized my canvas to 1280x720:

Image

## Additional information

Repository reproducing the issue https://github.com/rectalogic/bevy_canvas_size

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.