kitgit

tirbofish/dropbear · diff

c12f63a · tk

100 utah teapots with 30 fps, not good. todo: optimise code. jarvis, run github actions

Unverified

diff --git a/Cargo.toml b/Cargo.toml
index 7b17222..cde9eb4 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -31,6 +31,7 @@ gilrs = "0.11"
 git2 = "0.20"
 glam = { version = "0.30", features = ["serde"] }
 hecs = { version = "0.10", features = ["serde"] }
+lazy_static = "1.5"
 log = "0.4"
 log-once = "0.4"
 model_to_image = "0.1.1"
diff --git a/dropbear-engine/Cargo.toml b/dropbear-engine/Cargo.toml
index 7ffd453..05012b1 100644
--- a/dropbear-engine/Cargo.toml
+++ b/dropbear-engine/Cargo.toml
@@ -33,6 +33,7 @@ winit.workspace = true
 hecs.workspace = true
 once_cell.workspace = true
 parking_lot.workspace = true
+lazy_static.workspace = true
 
 [target.'cfg(not(target_os = "android"))'.dependencies]
 rfd.workspace = true
diff --git a/dropbear-engine/src/entity.rs b/dropbear-engine/src/entity.rs
index b0c481b..668c61c 100644
--- a/dropbear-engine/src/entity.rs
+++ b/dropbear-engine/src/entity.rs
@@ -1,15 +1,11 @@
-use std::collections::HashMap;
 use std::path::PathBuf;
 use glam::{DMat4, DQuat, DVec3, Mat4};
-use once_cell::sync::Lazy;
-use parking_lot::RwLock;
 use serde::{Deserialize, Serialize};
 use wgpu::{util::DeviceExt, BindGroup, Buffer};
 
 use crate::{
     graphics::{Graphics, Instance}, model::Model
 };
-use crate::model::Mesh;
 
 #[derive(Debug, Clone, Deserialize, Serialize, Copy, PartialEq)]
 pub struct Transform {
@@ -61,10 +57,7 @@ impl Transform {
 #[derive(Default)]
 pub struct AdoptedEntity {
     pub model: Option<Model>,
-    pub uniform: ModelUniform,
-    pub uniform_buffer: Option<Buffer>,

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