aboutsummaryrefslogtreecommitdiff
path: root/stockton-levels/src/traits/tree.rs
diff options
context:
space:
mode:
authortcmal <me@aria.rip>2024-08-25 17:44:22 +0100
committertcmal <me@aria.rip>2024-08-25 17:44:22 +0100
commitc48b54f3fb7bbe9046915eb99eca02fa84dc55c9 (patch)
tree752831451d2bd3a658485df724a01ae39e80fae3 /stockton-levels/src/traits/tree.rs
parentb437109ebf4da243fd643f0a31546d0d0155b0a4 (diff)
feat(render): multithreaded texture loading
also a bunch of supporting changes
Diffstat (limited to 'stockton-levels/src/traits/tree.rs')
-rw-r--r--stockton-levels/src/traits/tree.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/stockton-levels/src/traits/tree.rs b/stockton-levels/src/traits/tree.rs
index 253ae1b..5ca0d59 100644
--- a/stockton-levels/src/traits/tree.rs
+++ b/stockton-levels/src/traits/tree.rs
@@ -24,29 +24,29 @@ use na::Vector3;
/// A node in a BSP tree.
/// Either has two children *or* a leaf entry.
#[derive(Debug, Clone)]
-pub struct BSPNode {
+pub struct BspNode {
pub plane_idx: u32,
pub min: Vector3<i32>,
pub max: Vector3<i32>,
- pub value: BSPNodeValue,
+ pub value: BspNodeValue,
}
#[derive(Debug, Clone)]
-pub enum BSPNodeValue {
- Leaf(BSPLeaf),
- Children(Box<BSPNode>, Box<BSPNode>),
+pub enum BspNodeValue {
+ Leaf(BspLeaf),
+ Children(Box<BspNode>, Box<BspNode>),
}
/// A leaf in a BSP tree.
/// Will be under a `BSPNode`, min and max values are stored there.
#[derive(Debug, Clone)]
-pub struct BSPLeaf {
+pub struct BspLeaf {
pub cluster_id: u32,
pub area: i32,
pub faces_idx: Box<[u32]>,
pub brushes_idx: Box<[u32]>,
}
-pub trait HasBSPTree<S: CoordSystem>: HasFaces<S> + HasBrushes<S> + HasVisData {
- fn get_bsp_root(&self) -> &BSPNode;
+pub trait HasBspTree<S: CoordSystem>: HasFaces<S> + HasBrushes<S> + HasVisData {
+ fn get_bsp_root(&self) -> &BspNode;
}