[chronojump/FS-TFT-Menu] CairoPaintBarsPreJumpReactiveRealtimeCapture fixed avg (totaldist/totaltime instead of avg of each o
- From: Xavier Padullés <xpadulles src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump/FS-TFT-Menu] CairoPaintBarsPreJumpReactiveRealtimeCapture fixed avg (totaldist/totaltime instead of avg of each o
- Date: Wed, 27 Apr 2022 17:18:04 +0000 (UTC)
commit 86edb7ff0db48928c9988538b6f4e8a00fd01d4d
Author: Xavier de Blas <xaviblas gmail com>
Date: Mon Apr 25 12:24:43 2022 +0200
CairoPaintBarsPreJumpReactiveRealtimeCapture fixed avg (totaldist/totaltime instead of avg of each of the
tracks)
src/gui/eventExecute.cs | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
---
diff --git a/src/gui/eventExecute.cs b/src/gui/eventExecute.cs
index 20eaa4fa2..fc4f1c0cb 100644
--- a/src/gui/eventExecute.cs
+++ b/src/gui/eventExecute.cs
@@ -3357,7 +3357,6 @@ public class CairoPaintBarsPreRunIntervalRealtimeCapture : CairoPaintBarsPre
//statistics for speed
double max = 0;
- double sum = 0; //for speed_l avg
double min = 1000;
//for absolute data. Absolute is from the beginning.
@@ -3391,8 +3390,6 @@ public class CairoPaintBarsPreRunIntervalRealtimeCapture : CairoPaintBarsPre
if(speed > max) //get max
max = speed;
- sum += speed; //get avg
-
if(speed < min) //get min
min = speed;
}
@@ -3401,7 +3398,7 @@ public class CairoPaintBarsPreRunIntervalRealtimeCapture : CairoPaintBarsPre
true, false, //usePersonGuides, useGroupGuides
0, 0, 0, 0,
max,
- sum / speed_l.Count,
+ UtilAll.DivideSafe(distanceTotal, timeTotal),
min));
/*
if(photocell_l.Count > 0)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]