gfx-rs / gfx

[maintenance mode] A low-overhead Vulkan-like GPU API for Rust.
http://gfx-rs.github.io/
Apache License 2.0
5.35k stars 551 forks source link

WIP: OpenXR integration #3761

Closed blaind closed 2 years ago

blaind commented 3 years ago

One take at issue #3219

PR checklist:

I've made a proof-of-concept for OpenXR rendering on Bevy engine, using wgpu & underlying stack. See https://github.com/blaind/xrbevy

The code in this pull request is not even close to merge-able, but I thought its good idea to open it for further discussion.

For architecture of the pull request, see https://github.com/blaind/xrbevy/blob/main/docs/architecture.md (evolving document)

See also https://github.com/gfx-rs/wgpu-rs/pull/910 and https://github.com/gfx-rs/wgpu/pull/1387

blaind commented 3 years ago

Even though this renders, there might be some parts from OpenXR api that are missing currently:

blaind commented 3 years ago

I also drafted a diagram about openxr entities:

screenshot

I wonder if the swapchain handling could be integrated into gfx (or wgpu?)

blaind commented 2 years ago

I'll close this - there's a better encapsulation approach with raw handles that's being continued at https://github.com/gfx-rs/wgpu/pull/1415 && https://github.com/gfx-rs/wgpu/pull/1609