mirror of
https://github.com/denoland/deno.git
synced 2024-11-21 15:04:11 -05:00
0cb00a6e89
Fixes https://github.com/denoland/deno/issues/23508 `width` and `height` are required to configure the wgpu surface because Deno is headless and depends on user to create a window. The options were non-standard extension of `GPUCanvasConfiguration#configure`. This PR adds a required options parameter with the `width` and `height` options to `Deno.UnsafeWindowSurface` constructor. ```typescript // Old, non-standard extension of GPUCanvasConfiguration const surface = new Deno.UnsafeWindowSurface("x11", displayHandle, windowHandle); const context = surface.getContext(); context.configure({ width: 600, height: 800, /* ... */ }); ``` ```typescript // New const surface = new Deno.UnsafeWindowSurface({ system: "x11", windowHandle, displayHandle, width: 600, height: 800, }); const context = surface.getContext(); context.configure({ /* ... */ }); ``` |
||
---|---|---|
.. | ||
config | ||
ffi | ||
integration | ||
napi | ||
node_compat | ||
registry | ||
specs | ||
testdata | ||
unit | ||
unit_node | ||
util | ||
wpt | ||
Cargo.toml | ||
lib.rs | ||
README.md |