diff --git a/README.md b/README.md index 7516391..466de4e 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ rust bevy light field camera array tooling - [X] person segmentation post-process (batch across streams) - [X] async segmentation model inference - [X] foreground extraction post-process and visualization mode -- [ ] recording session timeline viewer +- [X] recording session viewer - [ ] camera array calibration (extrinsics, intrinsics, color) - [ ] camera position visualization - [ ] 3d reconstruction dataset preparation diff --git a/tools/viewer.rs b/tools/viewer.rs index f94ea61..075010d 100644 --- a/tools/viewer.rs +++ b/tools/viewer.rs @@ -195,6 +195,7 @@ fn main() { Update, ( offline_viewer, + press_arrow_key_frame_navigation, ), ); } @@ -517,7 +518,18 @@ fn press_s_stop_recording( } -// TODO: add pipeline viewer /w left/right arrow keys and UI controls to switch between frames +fn press_arrow_key_frame_navigation( + mut frame_index: ResMut, + keys: Res>, +) { + if keys.just_pressed(KeyCode::ArrowLeft) { + frame_index.0 = frame_index.0.saturating_sub(1); + } + + if keys.just_pressed(KeyCode::ArrowRight) { + frame_index.0 += 1; + } +}