Last small fixes

This commit is contained in:
Elias Stepanik 2025-06-13 02:22:23 +02:00
parent 13a0b54364
commit d93063a8ba
4 changed files with 5 additions and 6 deletions

View File

@ -29,7 +29,7 @@ pub fn setup(
SphereMeshBuilder::new(radius, SphereKind::Ico { subdivisions: 100 })
.build(),
);
let material_handle = materials.add(StandardMaterial::from(Color::rgb(0.3, 0.6, 1.0)));
let material_handle = materials.add(StandardMaterial::from(Color::srgb(0.3, 0.6, 1.0)));
commands.entity(root.0).with_children(|parent| {
parent.spawn((

View File

@ -30,10 +30,10 @@ pub fn setup(
}
} else {
let mut tree = SparseVoxelOctree::new(octree_depth, octree_base_size, false, false, false);
let color = Color::rgb(0.2, 0.8, 0.2);
let color = Color::srgb(0.2, 0.8, 0.2);
// How many random spheres?
/*const NUM_SPHERES: usize = 5;
let mut rng = thread_rng();
let mut rng = threald_rng();
for _ in 0..NUM_SPHERES {
let center = Vec3::new(

View File

@ -15,7 +15,7 @@ pub fn visualize_octree_system(
gizmos.cuboid(
Transform::from_translation(octree_tf.translation)
.with_scale(Vec3::splat(octree.size)),
Color::rgba(1.0, 1.0, 0.0, 0.15),
Color::srgba(1.0, 1.0, 0.0, 0.15),
);
// Recursively draw children:
@ -62,7 +62,7 @@ fn visualize_recursive_center(
// Draw the child bounding box
gizmos.cuboid(
Transform::from_translation(child_center).with_scale(Vec3::splat(child_size)),
Color::rgba(0.5, 1.0, 0.5, 0.15), // greenish
Color::srgba(0.5, 1.0, 0.5, 0.15), // greenish
);
// Recurse

View File

@ -1,6 +1,5 @@
use crate::plugins::ui::systems::ui_system::*;
use bevy::app::{App, FixedUpdate, Plugin, PreUpdate, Startup};
use bevy::prelude::IntoSystemConfigs;
pub struct UiPlugin;
impl Plugin for UiPlugin {