kitgit

tirbofish/dropbear · commit

66651ff51c6c93c724f1cc24e65aa3983a86ba05

feature: improved lighting feature: changed to uuid-based id system for assets

Unverified

Thribhu K <4tkbytes@pm.me> · 2026-03-25 02:51

view full diff

diff --git a/crates/dropbear-engine/Cargo.toml b/crates/dropbear-engine/Cargo.toml
index 7fab0c5..f76d848 100644
--- a/crates/dropbear-engine/Cargo.toml
+++ b/crates/dropbear-engine/Cargo.toml
@@ -48,6 +48,7 @@ image = {workspace = true, features = ["serde"]}
 puffin.workspace = true
 bitflags.workspace = true
 puffin_http.workspace = true
+uuid.workspace = true
 float-derive.workspace = true
 rkyv.workspace = true
 bevy_mikktspace.workspace = true
diff --git a/crates/dropbear-engine/src/lighting.rs b/crates/dropbear-engine/src/lighting.rs
index bdaf899..d05d814 100644
--- a/crates/dropbear-engine/src/lighting.rs
+++ b/crates/dropbear-engine/src/lighting.rs
@@ -79,7 +79,7 @@ impl Default for LightArrayUniform {
         Self {
             lights: [LightUniform::default(); MAX_LIGHTS],
             light_count: 0,
-            ambient_strength: 0.1,
+            ambient_strength: 0.5,
             _padding: [0; 2],
         }
     }
diff --git a/crates/dropbear-engine/src/pipelines/hdr.rs b/crates/dropbear-engine/src/pipelines/hdr.rs
index 4257e36..bfab1c1 100644
--- a/crates/dropbear-engine/src/pipelines/hdr.rs
+++ b/crates/dropbear-engine/src/pipelines/hdr.rs
@@ -1,7 +1,15 @@
 use crate::pipelines::create_render_pipeline;
 use crate::texture::{Texture, TextureBuilder};
+use wgpu::util::DeviceExt;
 use wgpu::Operations;
 
+#[repr(C)]
+#[derive(Copy, Clone, bytemuck::Pod, bytemuck::Zeroable)]
+struct PostProcessUniforms {
+    gamma: f32,
+    _pad: [f32; 3],
+}
+
 pub struct HdrPipeline {
     pipeline: wgpu::RenderPipeline,
     bind_group: wgpu::BindGroup,
@@ -12,6 +20,8 @@ pub struct HdrPipeline {
     format: wgpu::TextureFormat,
     layout: wgpu::BindGroupLayout,
     antialiasing: crate::multisampling::AntiAliasingMode,
+    gamma: f32,

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