From a1705964c24ec44e3a313a2bbbc75426665c3044 Mon Sep 17 00:00:00 2001 From: frederic wagner Date: Tue, 12 Jul 2022 20:07:25 +0200 Subject: [PATCH] fix in gpconv --- apps/gipy/app.js | 4 +--- apps/gipy/gpconv/src/main.rs | 3 ++- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/apps/gipy/app.js b/apps/gipy/app.js index 6acf35312..d2068d1d2 100644 --- a/apps/gipy/app.js +++ b/apps/gipy/app.js @@ -137,10 +137,8 @@ function display(path) { Bangle.drawWidgets(); } -Bangle.loadWidgets() +Bangle.loadWidgets(); let path = new Path("test.gpc"); -lat = path.min_lat; -lon = path.min_lon; var current_segment = path.nearest_segment(new Point(lon, lat), 0, Number.MAX_VALUE); diff --git a/apps/gipy/gpconv/src/main.rs b/apps/gipy/gpconv/src/main.rs index a60924a53..a19f0530d 100644 --- a/apps/gipy/gpconv/src/main.rs +++ b/apps/gipy/gpconv/src/main.rs @@ -158,7 +158,8 @@ fn save_json>(path: P, points: &[(f64, f64)]) -> std::io::Result< } fn main() { - let input_file = std::env::args().nth(2).unwrap_or("m.gpx".to_string()); + let input_file = std::env::args().nth(1).unwrap_or("m.gpx".to_string()); + eprintln!("input is {}", input_file); let p = points(&input_file).collect::>(); let rp = rdp(&p, 0.001); // let rp = rdp(&p, 0.0001);