update with VRPN integration
This commit is contained in:
parent
9c778afa2b
commit
d7bc604289
6 changed files with 1003 additions and 182 deletions
12
src/main.rs
12
src/main.rs
|
@ -8,10 +8,11 @@
|
|||
use crate::scene::*;
|
||||
use crate::utils::*;
|
||||
use crate::viewer::*;
|
||||
|
||||
use crate::tracker::*;
|
||||
|
||||
use bevy::{prelude::*, window::PresentMode, render::camera::CameraProjectionPlugin};
|
||||
use offaxis::{offaxis_camera_setup, OffAxisProjection};
|
||||
use tracker::setup_tracker;
|
||||
|
||||
mod offaxis;
|
||||
mod scene;
|
||||
|
@ -19,6 +20,7 @@ mod screeninfo;
|
|||
mod utils;
|
||||
mod viewer;
|
||||
mod projection;
|
||||
mod tracker;
|
||||
|
||||
fn main() {
|
||||
App::new()
|
||||
|
@ -33,6 +35,11 @@ fn main() {
|
|||
},
|
||||
..default()
|
||||
}))
|
||||
// use hot reloading
|
||||
// .add_plugins(DefaultPlugins.set(AssetPlugin {
|
||||
// watch_for_changes: true,
|
||||
// ..Default::default()
|
||||
// }))
|
||||
// .add_plugin(scene::BuildScenePlugin)
|
||||
.add_system(bevy::window::close_on_esc)
|
||||
.add_system(cycle_msaa)
|
||||
|
@ -40,6 +47,9 @@ fn main() {
|
|||
// .add_system(modify_projection)
|
||||
|
||||
.add_startup_system(offaxis_camera_setup)
|
||||
.add_startup_system(setup_tracker)
|
||||
.add_system(update_tracker)
|
||||
|
||||
.add_plugin(CameraProjectionPlugin::<OffAxisProjection>::default())
|
||||
.add_system(simulate_viewer)
|
||||
.add_system(apply_viewer_to_projections)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue