Skip to content

Commit

Permalink
update some stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
jan-tennert committed Oct 9, 2024
1 parent 0f6f0d1 commit 168f348
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 8 deletions.
Binary file removed scenarios/Test.png
Binary file not shown.
1 change: 0 additions & 1 deletion scenarios/Test.sim

This file was deleted.

2 changes: 1 addition & 1 deletion scenarios/earth_satellites.sim
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"bodies":[{"children":[{"children":[],"data":{"mass":0.0,"starting_position":{"x":149676047.62437057,"y":145468789.39744163,"z":62705286.14179747},"starting_velocity":{"x":-16.660751062419582,"y":16.85519821471999,"z":8.180891832173366},"name":"Mars","model_path":"mars.glb","diameter":0.0,"rotation_speed":0.0,"simulate":true,"naif_id":4,"fixed_body_frame":{"target_id":499,"orientation_id":499},"ellipsoid":{"semi_major_equatorial_radius_km":3396.19,"semi_minor_equatorial_radius_km":3396.19,"polar_radius_km":3376.2},"light_source":null,"rotation_matrix":{"x":{"x":0.4554736018180847,"y":0.869995653629303,"z":0.18881569802761078},"y":{"x":-0.7704004645347595,"y":0.2789040207862854,"z":0.5733198523521423},"z":{"x":0.4461243450641632,"y":-0.40659576654434204,"z":0.7972784638404846}}}},{"children":[{"children":[],"data":{"mass":450000.0,"starting_position":{"x":139697751.6768489,"y":-55457691.56188262,"z":26726.49883086234},"starting_velocity":{"x":8.512277308736511,"y":20.73621312430883,"z":-2.743211831320219},"name":"ISS","model_path":"iss.glb","diameter":0.1,"rotation_speed":0.0,"simulate":true,"naif_id":-1,"fixed_body_frame":{"target_id":-1,"orientation_id":-1},"ellipsoid":{"semi_major_equatorial_radius_km":1.0,"semi_minor_equatorial_radius_km":1.0,"polar_radius_km":1.0},"light_source":null,"rotation_matrix":{"x":{"x":1.0,"y":0.0,"z":0.0},"y":{"x":0.0,"y":1.0,"z":0.0},"z":{"x":0.0,"y":0.0,"z":1.0}}}},{"children":[],"data":{"mass":10800.0,"starting_position":{"x":139708447.6237727,"y":-55461983.31379145,"z":33786.01008588448},"starting_velocity":{"x":13.95250317957649,"y":32.23801340370306,"z":-4.892445364940268},"name":"Hubble","model_path":"hubble.glb","diameter":0.01,"rotation_speed":0.0,"simulate":true,"naif_id":-1,"fixed_body_frame":{"target_id":-1,"orientation_id":-1},"ellipsoid":{"semi_major_equatorial_radius_km":1.0,"semi_minor_equatorial_radius_km":1.0,"polar_radius_km":1.0},"light_source":null,"rotation_matrix":{"x":{"x":1.0,"y":0.0,"z":0.0},"y":{"x":0.0,"y":1.0,"z":0.0},"z":{"x":0.0,"y":0.0,"z":1.0}}}}],"data":{"mass":5.972e24,"starting_position":{"x":139703169.6031987,"y":-50894516.80238317,"z":-22031976.570581574},"starting_velocity":{"x":10.34755584668519,"y":25.363844384635943,"z":10.995351298282669},"name":"Earth","model_path":"earth.glb","diameter":12742.0,"rotation_speed":1436.0,"simulate":true,"naif_id":399,"fixed_body_frame":{"target_id":399,"orientation_id":399},"ellipsoid":{"semi_major_equatorial_radius_km":6378.1366,"semi_minor_equatorial_radius_km":6378.1366,"polar_radius_km":6356.7519},"light_source":null,"rotation_matrix":{"x":{"x":0.9411901831626892,"y":-0.3378697335720062,"z":-0.002259173896163702},"y":{"x":0.3378687798976898,"y":0.9411928653717041,"z":-0.000803968112450093},"z":{"x":0.0023979549296200275,"y":-6.617409326281631e-6,"z":0.9999971389770508}}}}],"data":{"mass":1.9885e30,"starting_position":{"x":-982171.6832391358,"y":-655394.8782055749,"z":28787.74341113935},"starting_velocity":{"x":0.01127558914848326,"y":-0.008532815916463004,"z":-0.0001656555243002107},"name":"Sun","model_path":"sun.glb","diameter":1392700.032,"rotation_speed":0.0,"simulate":true,"naif_id":-1,"fixed_body_frame":{"target_id":-1,"orientation_id":-1},"ellipsoid":{"semi_major_equatorial_radius_km":1.0,"semi_minor_equatorial_radius_km":1.0,"polar_radius_km":1.0},"light_source":{"intensity":3.75e28,"range":9e30,"color":"#FFFFFF","enabled":true},"rotation_matrix":{"x":{"x":1.0,"y":0.0,"z":0.0},"y":{"x":0.0,"y":1.0,"z":0.0},"z":{"x":0.0,"y":0.0,"z":1.0}}}}],"data_sets":["pck11.pca","de440s.bsp"],"starting_time_millis":1725148800000,"title":"Earth Satellites","description":"A scenario with all major satellites orbiting the Earth.","scale":1e-7,"timestep":150}
{"bodies":[{"children":[{"children":[{"children":[],"data":{"mass":450000.0,"starting_position":{"x":139697751.6768489,"y":-55457691.56188262,"z":26726.49883086234},"starting_velocity":{"x":8.512277308736511,"y":20.73621312430883,"z":-2.743211831320219},"name":"ISS","model_path":"iss.glb","rotation_speed":0.0,"simulate":true,"naif_id":-1,"fixed_body_frame":{"target_id":-1,"orientation_id":-1},"ellipsoid":{"semi_major_equatorial_radius_km":1.0,"semi_minor_equatorial_radius_km":1.0,"polar_radius_km":1.0},"light_source":null,"rotation_matrix":{"x":{"x":1.0,"y":0.0,"z":0.0},"y":{"x":0.0,"y":1.0,"z":0.0},"z":{"x":0.0,"y":0.0,"z":1.0}}}},{"children":[],"data":{"mass":10800.0,"starting_position":{"x":139708447.6237727,"y":-55461983.31379145,"z":33786.01008588448},"starting_velocity":{"x":13.95250317957649,"y":32.23801340370306,"z":-4.892445364940268},"name":"Hubble","model_path":"hubble.glb","rotation_speed":0.0,"simulate":true,"naif_id":-1,"fixed_body_frame":{"target_id":-1,"orientation_id":-1},"ellipsoid":{"semi_major_equatorial_radius_km":1.0,"semi_minor_equatorial_radius_km":1.0,"polar_radius_km":1.0},"light_source":null,"rotation_matrix":{"x":{"x":1.0,"y":0.0,"z":0.0},"y":{"x":0.0,"y":1.0,"z":0.0},"z":{"x":0.0,"y":0.0,"z":1.0}}}}],"data":{"mass":5.972e24,"starting_position":{"x":139703169.6031987,"y":-50894516.80238317,"z":-22031976.570581578},"starting_velocity":{"x":10.34755584668519,"y":25.363844384635943,"z":10.995351298282667},"name":"Earth","model_path":"earth.glb","rotation_speed":1436.0,"simulate":true,"naif_id":399,"fixed_body_frame":{"target_id":399,"orientation_id":399},"ellipsoid":{"semi_major_equatorial_radius_km":6378.1366,"semi_minor_equatorial_radius_km":6378.1366,"polar_radius_km":6356.7519},"light_source":null,"rotation_matrix":{"x":{"x":0.9411901831626892,"y":-0.3378697335720062,"z":-0.002259173896163702},"y":{"x":0.3378687798976898,"y":0.9411928653717041,"z":-0.000803968112450093},"z":{"x":0.0023979549296200275,"y":-6.617409326281631e-6,"z":0.9999971389770508}}}},{"children":[],"data":{"mass":0.0,"starting_position":{"x":149676047.62437055,"y":145468789.39744163,"z":62705286.14179747},"starting_velocity":{"x":-16.660751062419582,"y":16.85519821471999,"z":8.180891832173366},"name":"Mars","model_path":"mars.glb","rotation_speed":0.0,"simulate":true,"naif_id":4,"fixed_body_frame":{"target_id":499,"orientation_id":499},"ellipsoid":{"semi_major_equatorial_radius_km":3396.19,"semi_minor_equatorial_radius_km":3396.19,"polar_radius_km":3376.2},"light_source":null,"rotation_matrix":{"x":{"x":0.4554736018180847,"y":0.869995653629303,"z":0.18881569802761078},"y":{"x":-0.7704004645347595,"y":0.2789040207862854,"z":0.5733198523521423},"z":{"x":0.4461243450641632,"y":-0.40659576654434204,"z":0.7972784638404846}}}}],"data":{"mass":1.9885e30,"starting_position":{"x":-982171.6832391358,"y":-655394.8782055749,"z":28787.74341113935},"starting_velocity":{"x":0.01127558914848326,"y":-0.008532815916463004,"z":-0.0001656555243002107},"name":"Sun","model_path":"sun.glb","rotation_speed":0.0,"simulate":true,"naif_id":-1,"fixed_body_frame":{"target_id":-1,"orientation_id":-1},"ellipsoid":{"semi_major_equatorial_radius_km":1.0,"semi_minor_equatorial_radius_km":1.0,"polar_radius_km":1.0},"light_source":{"intensity":3.75e28,"range":9e30,"color":"#FFFFFF","imposter_color":"#FFFFFF","enabled":true},"rotation_matrix":{"x":{"x":1.0,"y":0.0,"z":0.0},"y":{"x":0.0,"y":1.0,"z":0.0},"z":{"x":0.0,"y":0.0,"z":1.0}}}}],"data_sets":["pck11.pca","de440s.bsp"],"starting_time_millis":1725148800000,"title":"Earth Satellites (WIP)","description":"A scenario with all major satellites orbiting the Earth.","scale":1e-7,"timestep":150}
Binary file removed scenarios/solar_system_copy.png
Binary file not shown.
1 change: 0 additions & 1 deletion scenarios/solar_system_copy.sim

This file was deleted.

2 changes: 1 addition & 1 deletion scenarios/voyager_1.sim

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion scenarios/voyager_2.sim

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions src/simulation/components/billboard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@ fn auto_scale_billboards(
predicate = false;
}
}
billboard_visible.0 = !settings.dynamic_hide || predicate;
billboard_visible.0 = (!settings.dynamic_hide || predicate) && !star;
let multiplier = if star {
1000. //TODO: Fix the star billboard, shader too bright
5000.
} else {
775.
};
Expand All @@ -81,7 +81,7 @@ fn auto_scale_billboards(
c_transform,
p_transform,
children,
!settings.dynamic_hide || predicate,
(!settings.dynamic_hide || predicate) && !star,
multiplier
)
}
Expand Down
3 changes: 3 additions & 0 deletions src/simulation/ui/metadata.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,9 @@ fn edit_starting_time(ui: &mut egui::Ui, scenario_data: &mut ScenarioData) {
ui.horizontal(|ui| {
ui.label("Starting Date");
ui.add(DatePickerButton::new(&mut new_date));
if ui.button("Update bodies (TODO)").on_hover_text("Update bodies to new date").clicked() {

}
});
let mut hour = current_date.time().hour();
let mut minute = current_date.time().minute();
Expand Down

0 comments on commit 168f348

Please sign in to comment.