Closed Cuteistfox closed 3 months ago
Might be a Wayland issue ? Can you try using X11 ? Could you maybe try to start using gdb to get a stacktrace of the segfault?
or x.org i got `warning: ambiguous glob re-exports --> geom/src/lib.rs:72:9 | 72 | pub use polyline::*; | ^^^^^^^^^^^ the name PointsAlongs in the type namespace is first re-exported here
73 |
pub use polyline3::*; | ------------ but the name PointsAlongs in the type namespace is also re-exported here |
---|
= note: #[warn(ambiguous_glob_reexports)]
on by default
warning: geom
(lib) generated 1 warning
Compiling egregoria v0.1.0 (/home/meow/Egregoria/egregoria)
Compiling native_app v0.4.3 (/home/meow/Egregoria/native_app)
Finished release [optimized] target(s) in 29.99s
Running target/release/native_app
[ 145 INFO winit::platform_impl::platform::x11::window] Guessed window scale factor: 1
[ 26767 INFO wgpu_hal::gles::egl] Loading Wayland library to get the current display
[ 26856 INFO wgpu_hal::gles::egl] Loading X11 library to get the current display
[ 27247 INFO wgpu_hal::gles::egl] Using X11 platform
[ 48768 INFO wgpu_hal::gles::egl] Display vendor "Mesa Project", version (1, 5)
[ 48824 INFO wgpu_hal::gles::egl] EGL surface: +srgb
[ 48829 INFO wgpu_hal::gles::egl] Trying native-render
[ 48858 INFO wgpu_hal::gles::egl] EGL context: +robust access EXT
[ 49799 INFO wgpu_hal::gles::egl] EGL context: +surfaceless
[ 58734 INFO wgpu_hal::gles::adapter] Vendor: AMD
[ 59010 INFO wgpu_hal::gles::adapter] Renderer: AMD Radeon Graphics (renoir, LLVM 15.0.7, DRM 3.49, 6.2.0-25-generic)
[ 59015 INFO wgpu_hal::gles::adapter] Version: OpenGL ES 3.2 Mesa 23.0.2
[ 59021 INFO wgpu_hal::gles::adapter] SL version: OpenGL ES GLSL ES 3.20
[ 59041 INFO wgpu_core::instance] Adapter Vulkan AdapterInfo { name: "AMD Radeon Graphics (RADV RENOIR)", vendor: 4098, device: 5708, device_type: IntegratedGpu, driver: "radv", driver_info: "Mesa 23.0.2", backend: Vulkan }
[ 100505 INFO wgpu_engine::shader] compiling shader pbr/brdf_convolution took 3.752543ms
[ 105145 INFO wgpu_engine::shader] compiling shader mipmap took 549.378µs
[ 266010 INFO common::saveload] successfully loaded camera3D
[ 266588 WARN /home/meow/.cargo/registry/src/index.crates.io-6f17d22bba15001f/egui-wgpu-0.22.0/src/renderer.rs:299] Detected a linear (sRGBA aware) framebuffer Bgra8UnormSrgb. egui prefers Rgba8Unorm or Bgra8Unorm
[ 266706 INFO naga::back::spv::writer] Skip function Some("position_from_screen")
[ 266838 INFO native_app::game_loop] loaded egui_render
[ 266888 INFO egregoria ] Seed is 123
[ 266894 INFO egregoria ] EgregoriaOptions { terrain_size: 50, save_replay: true }
[ 267080 INFO egregoria::economy::market] ItemID(2v1) 5$
[ 267091 INFO egregoria::economy::market] ItemID(3v1) 3$
[ 267097 INFO egregoria::economy::market] ItemID(4v1) 6.75$
[ 267102 INFO egregoria::economy::market] ItemID(5v1) 0.12$
[ 267109 INFO egregoria::economy::market] ItemID(6v1) 11.25$
[ 267114 INFO egregoria::economy::market] ItemID(7v1) 17.50$
[ 267119 INFO egregoria::economy::market] ItemID(8v1) 30$
[ 267124 INFO egregoria::economy::market] ItemID(9v1) 12.50$
[ 267129 INFO egregoria::economy::market] ItemID(10v1) 25$
[ 267136 INFO egregoria::economy::market] ItemID(11v1) 12.50$
[ 267141 INFO egregoria::economy::market] ItemID(12v1) 25$
[ 267146 INFO egregoria::economy::market] ItemID(13v1) 12.50$
[ 267152 INFO egregoria::economy::market] ItemID(14v1) 50$
[ 267157 INFO egregoria::economy::market] ItemID(15v1) 62.50$
[ 267163 INFO egregoria::economy::market] ItemID(16v1) 6.25$
[ 267169 INFO egregoria::economy::market] ItemID(17v1) 12.50$
[ 267174 INFO egregoria::economy::market] ItemID(19v1) 6.25$
[ 267180 INFO egregoria::economy::market] ItemID(22v1) 12.50$
[ 267186 INFO egregoria::economy::market] ItemID(18v1) 37.50$
[ 267191 INFO egregoria::economy::market] ItemID(18v1) 25$
[ 267197 INFO egregoria::economy::market] ItemID(20v1) 6.25$
[ 267203 INFO egregoria::economy::market] ItemID(21v1) 0$
[ 267208 INFO egregoria::economy::market] ItemID(21v1) 0$
[ 267391 INFO egregoria::engine_interaction] generating terrain..
[ 287665 INFO native_app::audio] decoding assets/sounds/road_lay.ogg: 44100 sps|36368 total samples|2 channels|took 21.775627ms
[ 338298 INFO native_app::audio] decoding assets/sounds/car_loop.ogg: 44100 sps|441000 total samples|1 channels|took 72.41163ms
[ 340721 INFO native_app::audio] decoding assets/sounds/car_engine.ogg: 96000 sps|382343 total samples|2 channels|took 74.86358ms
[ 341094 INFO native_app::audio] decoding assets/sounds/calm_wind.ogg: 44100 sps|280959 total samples|2 channels|took 75.24026ms
[ 778046 INFO native_app::audio] decoding assets/sounds/forest.ogg: 44100 sps|2941158 total samples|2 channels|took 512.13544ms
[ 788331 INFO native_app::audio] decoding assets/sounds/music2.ogg: 48000 sps|3243797 total samples|2 channels|took 522.351ms
[ 1170070 INFO native_app::audio] decoding assets/sounds/music1.ogg: 44100 sps|6590592 total samples|2 channels|took 904.1277ms
[ 1297795 INFO egregoria::engine_interaction] took 1.0303941s
[ 1297847 INFO egregoria::map::map] connect IntersectionID(1v1) IntersectionID(2v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [(Rail, 9.0)] } Straight
[ 1297870 INFO egregoria::map::map] invalidate IntersectionID(1v1)
[ 1297894 INFO egregoria::map::map] invalidate IntersectionID(2v1)
[ 1297946 INFO egregoria::map::map] build special ExternalTrading with shape OBB { corners: [V2(3072.2002, 1), V2(3072.2002, 201), V2(3000, 201), V2(3000, 1)] } and gen NoWalkway { door_pos: V2(0, 0) } and zone None
[ 1298023 INFO egregoria::map::map] connect IntersectionID(3v1) IntersectionID(4v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [] } Straight
[ 1298037 INFO egregoria::map::map] invalidate IntersectionID(3v1)
[ 1298046 INFO egregoria::map::map] invalidate IntersectionID(4v1)
[ 1298058 INFO egregoria::map::map] build special RailFreightStation with shape OBB { corners: [V2(6476.334, 9348.582), V2(6560.8574, 9529.844), V2(6415.8486, 9597.463), V2(6331.325, 9416.201)] } and gen NoWalkway { door_pos: V2(0, 0) } and zone None
[ 1298096 INFO egregoria::map::map] connect IntersectionID(2v1) IntersectionID(5v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [(Rail, 9.0)] } Curved((V2(86.369225, 1026.4293), V2(769.6488, 1122.028)))
[ 1298435 INFO egregoria::map::map] invalidate IntersectionID(2v1)
[ 1298473 INFO egregoria::map::map] invalidate IntersectionID(5v1)
[ 1306684 INFO egregoria::map::map] connect IntersectionID(5v1) IntersectionID(6v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [(Rail, 9.0)] } Curved((V2(1220.0071, 1769.0775), V2(124.35895, 1098.7653)))
[ 1307174 INFO egregoria::map::map] invalidate IntersectionID(5v1)
[ 1307208 INFO egregoria::map::map] invalidate IntersectionID(6v1)
[ 1314928 INFO egregoria::map::map] connect IntersectionID(6v1) IntersectionID(7v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [(Rail, 9.0)] } Curved((V2(42.93809, 605.6197), V2(44.27462, 336.83038)))
[ 1314987 INFO egregoria::map::map] invalidate IntersectionID(6v1)
[ 1315013 INFO egregoria::map::map] invalidate IntersectionID(7v1)
[ 1315420 INFO egregoria::map::map] connect IntersectionID(7v1) IntersectionID(8v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [] } Curved((V2(35.33773, 196.22282), V2(104.76436, 33.762276)))
[ 1315445 INFO egregoria::map::map] invalidate IntersectionID(7v1)
[ 1315460 INFO egregoria::map::map] invalidate IntersectionID(8v1)
[ 1315527 INFO egregoria::map::map] connect IntersectionID(8v1) IntersectionID(9v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [] } Curved((V2(100.229965, 27.057882), V2(11.64551, 151.25386)))
[ 1315553 INFO egregoria::map::map] invalidate IntersectionID(8v1)
[ 1315569 INFO egregoria::map::map] invalidate IntersectionID(9v1)
[ 1315635 INFO egregoria::map::map] connect IntersectionID(9v1) IntersectionID(3v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [] } Curved((V2(2.7997699, 88.05137), V2(-82.526405, 31.382696)))
[ 1315657 INFO egregoria::map::map] invalidate IntersectionID(9v1)
[ 1315671 INFO egregoria::map::map] invalidate IntersectionID(3v1)
[ 1315738 INFO egregoria::map::map] connect IntersectionID(4v1) IntersectionID(10v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [] } Curved((V2(-127.458755, 67.86706), V2(-22.762417, -149.21057)))
[ 1315769 INFO egregoria::map::map] invalidate IntersectionID(4v1)
[ 1315782 INFO egregoria::map::map] invalidate IntersectionID(10v1)
[ 1316382 INFO egregoria::map::map] connect IntersectionID(10v1) IntersectionID(11v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [] } Curved((V2(-23.662527, -128.27911), V2(81.388405, -140.30061)))
[ 1316425 INFO egregoria::map::map] invalidate IntersectionID(10v1)
[ 1316444 INFO egregoria::map::map] invalidate IntersectionID(11v1)
[ 1317400 INFO egregoria::map::map] connect IntersectionID(11v1) IntersectionID(7v1) LanePattern { lanes_forward: [(Rail, 9.0)], lanes_backward: [] } Curved((V2(31.722439, -125.47416), V2(16.93638, -111.57578)))
[ 1317423 INFO egregoria::map::map] invalidate IntersectionID(11v1)
[ 1317438 INFO egregoria::map::map] invalidate IntersectionID(7v1)
[ 1317564 INFO native_app::inputmap] Go Left ScanCode(30), Left
[ 1317574 INFO native_app::inputmap] Go Right ScanCode(32), Right
[ 1317578 INFO native_app::inputmap] Go Forward ScanCode(17), Up
[ 1317582 INFO native_app::inputmap] Go Backward ScanCode(31), Down
[ 1317586 INFO native_app::inputmap] Camera Move LShift + Right, Middle
[ 1317591 INFO native_app::inputmap] Camera Rotate Right
[ 1317597 INFO native_app::inputmap] Zoom Plus, Scroll Up
[ 1317602 INFO native_app::inputmap] Dezoom Minus, Scroll Down
[ 1317606 INFO native_app::inputmap] Rotate LControl + Scroll Up, LControl + Scroll Down
[ 1317612 INFO native_app::inputmap] Close Escape
[ 1317616 INFO native_app::inputmap] Select Left
[ 1317621 INFO native_app::inputmap] No Snapping LControl
[ 1317625 INFO native_app::inputmap] Hide interface H
[ 1317629 INFO native_app::inputmap] Up Elevation LControl + Scroll Up
[ 1317634 INFO native_app::inputmap] Down Elevation LControl + Scroll Down
[ 1317639 INFO native_app::inputmap] Economy Menu E
[ 1317643 INFO native_app::inputmap] Pause/Play Space
[ 1391206 INFO native_app::game_loop] version is 0.6.1
[ 1392371 INFO wgpu_engine::meshload] loaded mesh "assets/models/simple_car.glb" in 1.129845ms (188 tris)
[ 1393385 INFO wgpu_engine::meshload] loaded mesh "assets/models/train.glb" in 0.52639496ms (644 tris)
[ 1393687 INFO wgpu_engine::meshload] loaded mesh "assets/models/wagon_freight.glb" in 0.26996ms (796 tris)
[ 1394165 INFO wgpu_engine::meshload] loaded mesh "assets/models/wagon.glb" in 0.464168ms (2248 tris)
[ 1394286 INFO wgpu_engine::meshload] loaded mesh "assets/models/truck.glb" in 0.108004004ms (154 tris)
[ 1394357 WARN wgpu_engine/src/meshload.rs:248] extension not supported: , KHR_materials_specular, KHR_materials_ior
[ 1394390 INFO wgpu_engine::meshload] loaded mesh "assets/models/pedestrian.glb" in 0.092986ms (52 tris)
[ 1394400 INFO native_app::rendering::entity_render] finished init of instanced render
[ 1394472 INFO wgpu_engine::meshload] loaded mesh "assets/models/pine.glb" in 0.065003ms (36 tris)
[ 1443148 INFO wgpu_engine::meshload] loaded mesh "assets/models/bakery.glb" in 0.505576ms (12 tris)
[ 1532721 INFO wgpu_engine::meshload] loaded mesh "assets/models/flour_factory.glb" in 89.53054ms (318 tris) (tangents)
[ 1560693 INFO wgpu_engine::meshload] loaded mesh "assets/models/coal_power_plant.glb" in 27.91373ms (716 tris)
[ 1560969 INFO wgpu_engine::meshload] loaded mesh "assets/models/rail_freight_station.glb" in 0.223673ms (348 tris)
[ 1561073 INFO wgpu_engine::meshload] loaded mesh "assets/models/external_trading.glb" in 0.091763005ms (156 tris)
[ 1571042 WARN wgpu_engine/src/meshload.rs:248] extension not supported: , KHR_materials_specular, KHR_materials_ior
[ 1571993 INFO wgpu_engine::meshload] loaded mesh "assets/models/wheat_up.glb" in 3.75089ms (16 tris)
[ 1577875 WARN wgpu_engine/src/meshload.rs:248] extension not supported: , KHR_materials_specular, KHR_materials_ior
[ 1579748 INFO wgpu_engine::meshload] loaded mesh "assets/models/solarpanel.glb" in 4.437287ms (108 tris)
[ 1581228 INFO wgpu_engine::meshload] loaded mesh "assets/models/salad.glb" in 1.424944ms (64 tris)
[ 1582035 INFO wgpu_engine::drawables::terrain] finished init of terrain render
[ 1592539 INFO native_app::rendering::map_rendering] finished init of road render
[ 1592580 INFO native_app::audio] finished init of game audio
[ 1592721 INFO native_app::game_loop] finished init of game loop
[ 1593068 INFO native_app::context] resized: PhysicalSize { width: 1536, height: 864 }
[ 1604088 INFO egregoria::souls] 1 souls added
[ 1765487 INFO wgpu_engine::shader] compiling shader to_cubemap.vert took 244.142µs
[ 1765865 INFO wgpu_engine::shader] compiling shader atmosphere_cubemap.frag took 339.662µs
[ 1766444 INFO wgpu_engine::shader] compiling shader pbr/convolute_diffuse_irradiance.frag took 261.775µs
[ 1767164 INFO wgpu_engine::shader] compiling shader pbr/specular_prefilter.frag took 329.894µs
[ 1768703 INFO wgpu_engine::shader] compiling shader lit_mesh.vert took 120.418µs
[ 1768962 INFO wgpu_engine::shader] compiling shader terrain.vert took 116.45µs
[ 1769176 INFO wgpu_engine::shader] compiling shader instanced_mesh.vert took 125.227µs
[ 1770651 INFO wgpu_engine::shader] compiling shader ssao took 358.929µs
[ 1770719 INFO naga::back::spv::writer] Skip function Some("uv2s")
[ 1770727 INFO naga::back::spv::writer] Skip function Some("sample_depth")
[ 1770733 INFO naga::back::spv::writer] Skip function Some("derivative")
[ 1771935 INFO wgpu_engine::shader] compiling shader pixel.frag took 1.014678ms
[ 1773412 INFO wgpu_engine::shader] compiling shader terrain.frag took 1.169861ms
[ 1774326 INFO wgpu_engine::shader] compiling shader water.frag took 300.118µs
[ 1774381 INFO naga::back::spv::writer] Skip function Some("sample_depth")
[ 1775982 INFO wgpu_engine::shader] compiling shader background took 503.762µs
[ 1776043 INFO naga::back::spv::writer] Skip function Some("dither")
fish: Job 1, 'cargo run --release' terminated by signal SIGSEGV (Address boundary error)
`
If you could use gdb to get a trace of the segfault that would be much appreciated
~ gdb -- cargo run --release
(gdb) run
<SIGSEGV (Address boundary error) happens here>
(gdb) backtrace
<offending code is shown here, please send this>
You can probably use valgrind too for the same idea
in gdb i get ` gdb -- cargo run --release Excess command line arguments ignored. (--release) GNU gdb (Ubuntu 13.1-2ubuntu2) 13.1 Copyright (C) 2023 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: https://www.gnu.org/software/gdb/bugs/. Find the GDB manual and other documentation resources online at: http://www.gnu.org/software/gdb/documentation/.
For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from cargo... /home/meow/Egregoria/run: No such file or directory. (gdb) run Starting program: /home/meow/.cargo/bin/cargo
This GDB supports auto-downloading debuginfo from the following URLs: https://debuginfod.ubuntu.com Enable debuginfod for this session? (y or [n]) n Debuginfod has been disabled. To make this setting permanent, add 'set debuginfod enabled off' to .gdbinit. [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". process 476962 is executing new program: /home/meow/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/cargo [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". Rust's package manager
Usage: cargo [+toolchain] [OPTIONS] [COMMAND]
Options:
-V, --version Print version info and exit
--list List installed commands
--explain Run
rustc --explain CODE
-v, --verbose... Use verbose output (-vv very verbose/build.rs output)
-q, --quiet Do not print cargo log messages
--color
Some common cargo commands are (see all commands with --list): build, b Compile the current package check, c Analyze the current package and report errors, but don't build object files clean Remove the target directory doc, d Build this package's and its dependencies' documentation new Create a new cargo package init Create a new cargo package in an existing directory add Add dependencies to a manifest file remove Remove dependencies from a manifest file run, r Run a binary or example of the local package test, t Run the tests bench Run the benchmarks update Update dependencies listed in Cargo.lock search Search registry for crates publish Package and upload this package to the registry install Install a Rust binary. Default location is $HOME/.cargo/bin uninstall Uninstall a Rust binary
See 'cargo help
For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from cargo... /home/meow/Egregoria/run: No such file or directory. (gdb) run run --release Starting program: /home/meow/.cargo/bin/cargo run --release
This GDB supports auto-downloading debuginfo from the following URLs: https://debuginfod.ubuntu.com Enable debuginfod for this session? (y or [n]) n Debuginfod has been disabled. To make this setting permanent, add 'set debuginfod enabled off' to .gdbinit. [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". process 477108 is executing new program: /home/meow/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/cargo [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". [New Thread 0x7ffff753e6c0 (LWP 477111)] warning: ambiguous glob re-exports --> geom/src/lib.rs:72:9 | 72 | pub use polyline::*; | ^^^^^^^^^^^ the name PointsAlongs in the type namespace is first re-exported here
73 |
pub use polyline3::*; | ------------ but the name PointsAlongs in the type namespace is also re-exported here |
---|
= note: #[warn(ambiguous_glob_reexports)]
on by default
warning: geom
(lib) generated 1 warning
Finished release [optimized] target(s) in 0.14s
Thread 2 "cargo" received signal SIGUSR1, User defined signal 1. [Switching to Thread 0x7ffff753e6c0 (LWP 477111)] __memcpy_avx_unaligned_erms () at ../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S:400 400 ../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S: No such file or directory. (gdb) run run --release The program being debugged has been started already. Start it from the beginning? (y or n) y Starting program: /home/meow/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/cargo run --release
[Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". [Detaching after vfork from child process 477457] [Detaching after vfork from child process 477458] [Detaching after vfork from child process 477510] [New Thread 0x7ffff753e6c0 (LWP 477514)] warning: ambiguous glob re-exports --> geom/src/lib.rs:72:9 | 72 | pub use polyline::*; | ^^^^^^^^^^^ the name PointsAlongs in the type namespace is first re-exported here
73 |
pub use polyline3::*; | ------------ but the name PointsAlongs in the type namespace is also re-exported here |
---|
= note: #[warn(ambiguous_glob_reexports)]
on by default
warning: geom
(lib) generated 1 warning
Finished release [optimized] target(s) in 0.36s
Thread 2 "cargo" received signal SIGUSR1, User defined signal 1.
[Switching to Thread 0x7ffff753e6c0 (LWP 477514)]
std::sys::unix::cvt
at library/alloc/src/boxed.rs:1962
(gdb)
`
i dont think gdb is working
Oh indeed, here are instructions that should work
~ gdb target/release/native_app
(gdb) run
<SIGSEGV (Address boundary error) happens here>
(gdb) backtrace
<offending code is shown here, please send this>
i get `#0 __memcpy_avx_unaligned () at ../sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S:220
() at library/core/src/ops/function.rs:284
` after i run backtrace
Interesting! So wgpu is at fault here. Can you try running without --release
?
cargo build
gdb target/debug/native_app
(gdb) run
...
it works
Damn, tough one! We'll see once I update to wgpu 0.17
its Wgpu causing the bug
Might be a misuse on my part but I can't work on it, I am on vacation for 2 months right now. Anyway a segfault in wgpu's code is definitely trouble on wgpu side since I don't do anything unsafe
Maybe once I update to wgpu 0.18 it can work
It's been a while with a few updates to webgpu (0.16 -> 0.19) and egui (0.22 -> 0.26). Would it be possible to try again?
I forgot about this issue, im trying again on my new setup
Broken, but is probly from something elese and i dont even want to play this anymore
No problem
i anylised the backtrace and can see it appears to be a bug with wgpu