From c8849cfe63ed6d471b600d88935db5fac3609edf Mon Sep 17 00:00:00 2001 From: Joshua Groves Date: Thu, 13 Sep 2018 20:24:45 -0600 Subject: [PATCH] Add DX12 and Metal backends --- .gitignore | 2 +- Cargo.toml | 3 ++- src/lib.rs | 4 ++++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index a821aa992..173b95142 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,4 @@ - /target **/*.rs.bk Cargo.lock +.vscode diff --git a/Cargo.toml b/Cargo.toml index 954288242..8038a668e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,8 +4,9 @@ version = "0.1.0" authors = ["Dzmitry Malyshau "] [features] -default = ["gfx-backend-vulkan"] [dependencies] gfx-hal = { git = "https://github.com/gfx-rs/gfx" } gfx-backend-vulkan = { git = "https://github.com/gfx-rs/gfx", optional = true } +gfx-backend-dx12 = { git = "https://github.com/gfx-rs/gfx", optional = true } +gfx-backend-metal = { git = "https://github.com/gfx-rs/gfx", optional = true } diff --git a/src/lib.rs b/src/lib.rs index af237c19b..ad15c5820 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,6 +1,10 @@ extern crate gfx_hal as hal; #[cfg(feature = "gfx-backend-vulkan")] extern crate gfx_backend_vulkan as back; +#[cfg(feature = "gfx-backend-dx12")] +extern crate gfx_backend_dx12 as back; +#[cfg(feature = "gfx-backend-metal")] +extern crate gfx_backend_metal as back; mod command; mod device;