kitgit

tirbofish/dropbear · commit

1aca57634b4ca7a483ed24ac715a3488e82939af

wip: resetting computer, creating backup

Unverified

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

view full diff

diff --git a/crates/dropbear-engine/src/camera.rs b/crates/dropbear-engine/src/camera.rs
index 4de9409..efb966a 100644
--- a/crates/dropbear-engine/src/camera.rs
+++ b/crates/dropbear-engine/src/camera.rs
@@ -80,14 +80,6 @@ pub struct Camera {
     pub view_mat: DMat4,
     /// Projection Matrix
     pub proj_mat: DMat4,
-    
-    /// Smooth damping factor for camera position updates (0.0 = no smoothing, higher = more smoothing)
-    /// This helps prevent jittering when camera follows physics-driven objects
-    pub position_smoothing: f64,
-    /// Internal: previous eye position for smoothing
-    smooth_eye: DVec3,
-    /// Internal: previous target position for smoothing  
-    smooth_target: DVec3,
 }
 
 /// A simple builder/struct that allows you to build a [`Camera`]
@@ -102,7 +94,7 @@ pub struct CameraBuilder {
 }
 
 impl Camera {
-    pub const CAMERA_BIND_GROUP_LAYOUT: wgpu::BindGroupLayoutDescriptor<'_> = 
+    pub const CAMERA_BIND_GROUP_LAYOUT: wgpu::BindGroupLayoutDescriptor<'_> =
         BindGroupLayoutDescriptor {
             entries: &[BindGroupLayoutEntry {
                 binding: 0,
@@ -173,9 +165,6 @@ impl Camera {
             },
             view_mat,
             proj_mat,
-            position_smoothing: 10.0,  // Default smoothing value
-            smooth_eye: builder.eye,
-            smooth_target: builder.target,
         };
 
         log::debug!("Created new camera{}", if let Some(l) = label { format!(" with the label {}", l) } else { String::new() } );
@@ -228,17 +217,7 @@ impl Camera {
     }
 
     fn build_vp(&mut self) -> DMat4 {
-        // Apply smooth interpolation to camera position if smoothing is enabled
-        if self.position_smoothing > 0.0 {
-            let lerp_factor = (1.0 / (1.0 + self.position_smoothing)).clamp(0.0, 1.0);
-            self.smooth_eye = self.smooth_eye.lerp(self.eye, lerp_factor);
-            self.smooth_target = self.smooth_target.lerp(self.target, lerp_factor);
-        } else {
-            self.smooth_eye = self.eye;
-            self.smooth_target = self.target;

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