diff options
| author | Johannes Hofmann <Johannes.Hofmann@gmx.de> | 2026-10-27 17:53:14 +0100 |
|---|---|---|
| committer | Johannes Hofmann <Johannes.Hofmann@gmx.de> | 2026-10-27 17:53:14 +0100 |
| commit | d7142ca2c39c3ca2c58240558abcac9a0e8f8e09 (patch) | |
| tree | d63cc11ee739a687109205e89601a0affb7b6e6d /crates | |
| parent | 0899294929e62a520a88c71cdc225e5b4b9154ea (diff) | |
web: show tracked finger positions in pinch probe (build 27k)
Diffstat (limited to 'crates')
| -rw-r--r-- | crates/wipfel/src/app.rs | 2 | ||||
| -rw-r--r-- | crates/wipfel/src/canvas_view.rs | 9 |
2 files changed, 7 insertions, 4 deletions
diff --git a/crates/wipfel/src/app.rs b/crates/wipfel/src/app.rs index 4ed2e90..7d8eef6 100644 --- a/crates/wipfel/src/app.rs +++ b/crates/wipfel/src/app.rs @@ -149,7 +149,7 @@ fn find_peak_panel(p: &FpProps) -> Html { pub fn app() -> Html { let bitmap = use_state(|| None::<web_sys::ImageBitmap>); let view = use_state(ViewState::default); - let status = use_state(|| "No image loaded · build 27j".to_string()); + let status = use_state(|| "No image loaded · build 27k".to_string()); let db_status = use_state(|| "Loading hill database…".to_string()); let fit_info = use_state(String::new); let tick = use_state(|| 0u32); diff --git a/crates/wipfel/src/canvas_view.rs b/crates/wipfel/src/canvas_view.rs index e053add..f6c575f 100644 --- a/crates/wipfel/src/canvas_view.rs +++ b/crates/wipfel/src/canvas_view.rs @@ -498,8 +498,8 @@ pub fn canvas_view(props: &Props) -> Html { (c.0, c.1, c.2) }; format!( - "pinch d={dist:.0} f={f:.3} pd={pd} mv={mv} sd={sd} s={:.4}", - scale + "pinch d={dist:.0} f={f:.3} pd={pd} mv={mv} sd={sd} p1=({:.0},{:.0}) p2=({:.0},{:.0})", + x1, y1, x2, y2 ) } None => { @@ -508,7 +508,10 @@ pub fn canvas_view(props: &Props) -> Html { c.2 += 1; c.2 }; - format!("pinch d={dist:.0} seed#{sd}") + format!( + "pinch d={dist:.0} seed#{sd} p1=({:.0},{:.0}) p2=({:.0},{:.0})", + x1, y1, x2, y2 + ) } }; (ev, dbg) |
