Currently, the library exposes extern C API functions. A possible (strongly typed, nicer) Rust wrapping is expected to base on it, but it would have to operate on Handle things instead of placing the actual sub-structures where it needs. This is a possible (even if minor) performance hit that we are likely OK with (since Rust clients using wgpu are not the most demanding in terms of CPU perf).
Another benefit of C-first approach is increased chance from Gecko contributors who don't care much about Rust ecosystem wrappers. Still, the issue is open for discussion, since gfx-portability took a different approach (Rust-first) by basing on gfx-hal.
Currently, the library exposes extern C API functions. A possible (strongly typed, nicer) Rust wrapping is expected to base on it, but it would have to operate on
Handlethings instead of placing the actual sub-structures where it needs. This is a possible (even if minor) performance hit that we are likely OK with (since Rust clients usingwgpuare not the most demanding in terms of CPU perf).Another benefit of C-first approach is increased chance from Gecko contributors who don't care much about Rust ecosystem wrappers. Still, the issue is open for discussion, since
gfx-portabilitytook a different approach (Rust-first) by basing ongfx-hal.