kitgit

tirbofish/dropbear · commit

f14f3c1e8fe5d6ad238029646eaf3a73a8fb7fb3

ensured that SlangShaderBuilder works, made the starts of it. need to implement more arguments. Unverified

Thribhu K <4tkbytes@pm.me> · 2026-01-26 05:46

view full diff

diff --git a/Cargo.toml b/Cargo.toml
index 9042336..8d56500 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -75,6 +75,8 @@ postcard = { version = "1.1"}
 pollster = "0.4"
 yakui = { git = "https://github.com/SecondHalfGames/yakui", rev = "ddf7614" }
 yakui-wgpu = { git = "https://github.com/SecondHalfGames/yakui", rev = "ddf7614" }
+thiserror = "2.0"
+tempfile = "3.24"
 
 [workspace.dependencies.image]
 version = "0.25"
diff --git a/crates/dropbear-engine/Cargo.toml b/crates/dropbear-engine/Cargo.toml
index 8897280..a596f34 100644
--- a/crates/dropbear-engine/Cargo.toml
+++ b/crates/dropbear-engine/Cargo.toml
@@ -12,6 +12,7 @@ readme.workspace = true
 dropbear_future-queue = { path = "../dropbear_future-queue" }
 dropbear-traits = { path = "../dropbear-traits" }
 dropbear-macro = { path = "../dropbear-macro" }
+slank = { path = "../slank", features = ["download-slang"] }
 
 anyhow.workspace = true
 app_dirs2.workspace = true
diff --git a/crates/dropbear-engine/src/pipelines/shaders/light.slang b/crates/dropbear-engine/src/pipelines/shaders/light.slang
new file mode 100644
index 0000000..428e996
--- /dev/null
+++ b/crates/dropbear-engine/src/pipelines/shaders/light.slang
@@ -0,0 +1,57 @@
+struct Light {
+    float4 position;
+    float4 direction; // x, y, z, outer_cutoff_angle
+    float4 color; // r, g, b, light_type (0, 1, 2)
+
+    float constant;
+    float lin;
+    float quadratic;
+
+    float cutoff;
+};
+
+
+struct CameraUniform {
+    float4 view_pos;
+    float4x4 view_proj;
+};
+
+[[vk::binding(0, 0)]]

Large diffs are not rendered by default. Showing the first 50 of 1037 lines. Show full diff