From ee03e99670fa43b11abc92fad82d9daeeab796b8 Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Sun, 13 Jul 2025 00:32:12 +0200 Subject: [PATCH] Port scene_viewer --- examples/tools/scene_viewer/main.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/examples/tools/scene_viewer/main.rs b/examples/tools/scene_viewer/main.rs index f5ab505d91..ae23aecfb2 100644 --- a/examples/tools/scene_viewer/main.rs +++ b/examples/tools/scene_viewer/main.rs @@ -173,8 +173,10 @@ fn setup_scene_after_load( let mut camera = commands.spawn(( Camera3d::default(), Projection::from(projection), - Transform::from_translation(Vec3::from(aabb.center) + size * Vec3::new(0.5, 0.25, 0.5)) - .looking_at(Vec3::from(aabb.center), Vec3::Y), + Transform::from_translation( + Vec3::from(aabb.center) + size * Vec3::new(-0.5, 0.25, -0.5), + ) + .looking_at(Vec3::from(aabb.center), Vec3::Y), Camera { is_active: false, ..default() @@ -214,7 +216,7 @@ fn setup_scene_after_load( info!("Spawning a directional light"); let mut light = commands.spawn(( DirectionalLight::default(), - Transform::from_xyz(1.0, 1.0, 0.0).looking_at(Vec3::ZERO, Vec3::Y), + Transform::from_xyz(-1.0, 1.0, 0.0).looking_at(Vec3::ZERO, Vec3::Y), )); if args.occlusion_culling == Some(true) { light.insert(OcclusionCulling);