gfx-rs / gfx

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

Integrate with Godot #1791

Open kvark opened 6 years ago

kvark commented 6 years ago

Godot is one of the most popular open source game engines, and it's currently using GL only. It would be great to have a tighter collaboration between our teams, and I could see the following paths:

  1. Provide them with our Vulkan portability implementation. This can be started right now, with our task to assist the porting efforts, quickly identify and fix upcoming issues.
  2. Rewrite the rendering component (following the visual server protocol, as far as I see) in Rust. It's supposed to run on a separate thread(s), and we can then call gfx-hal directly from it.
erlend-sh commented 6 years ago

Fairly succinct description of Godot's tentative plan for gfx-rs here.

by @akien-mga

[DirectX 9] Won't happen for several reasons:

  • Godot is cross-platform at its core, and won't bother supporting a proprietary API for a single platform if there are open source alternatives (OpenGL, Vulkan)

  • If you don't have OpenGL drivers installed, you likely also don't have DirectX installed either, so that's not a solution. What you're experiencing is probably people who don't have drivers for OpenGL 3.3 (required by Godot 3.0), and those likely wouldn't have drivers for DirectX 10+ either. This will be solved with Godot 3.1 which supports OpenGL 2.1 again, which 99.9% of the market should support.

  • Our way forward is to implement a Vulkan backend which is cross-platform and performant, and not spend time on a 15 year old DirectX 9 which cannot support any of Godot's rendering features.

  • Eventually, the Vulkan backend could be used together with a portability layer like gfx-rs which would allow to translate to DirectX 10+, Metal and OpenGL if need be - though even then I doubt DirectX 10+ support will be really useful when all hardware capable for DX10 should also support Vulkan.

zakarumych commented 6 years ago

IIRC @karroffel works in this direction.

karroffel commented 6 years ago

Yes I am working on a rendering engine with C/C++ API, it can already present to the Godot-created window and right now I'm in the process of implementing a render graph implementation. I'll post updates later on!

vultix commented 4 years ago

@karroffel Thank you for your work on this! What's the current status of the project?

karroffel commented 4 years ago

@vultix unfortunately I am no longer working on that project.