.. instead of the 'More...' button in the top left of a chart when in
tabbed mode we now have a menu button when you hover over a tab.
.. the menu button activates the chart menu for now, till we refactor
to using a chart space.
.. the 'More...' menu is still available when in tiled mode (we need to
decide what to do there).
Unlike for the cadence value which uses 1/1024 second units, the wheel
revolution value is based on 1/2048 second units [1]. It is easy to
notice the problem when you ride downhill at 25 kph instead of 50kph! In
addition, the speed was initially incorrect because the previous wheel
position value was stale. This would sometimes give the speed of a
rocket for the initial interval and make a jump on the distance of
several km.
[1] Cycling Power Service, Bluetooth Service Specification, Date 2016-05-03, Revision CPS_v1.1, Prepared By Sports and Fitness Working Group, head of page 15.
https://www.bluetooth.org/DocMan/handlers/DownloadDoc.ashx?doc_id=412770,
When parsing a "distance slope wind" type, a truncate to integers was done
after computation to meters. This involved rounding issues that were
accumulated, and were quite visible when such a file was used to synchronized
with an RLV video (the slope changes happened "too early").
.. the OverviewWindow class has been refactored to extract out the
core dashboard UX/UI into a new class ChartSpace.
.. additionally, a ChartSpace contains a set of ChartSpaceItem which
need to be subclassed by the developer.
.. for the Overview a set of OverwiewItem classes have been introduced
such as RPEOverviewItem, MetricOverviewItem and so on. These are
subclasses of the ChartSpaceItem.
.. The overview window implementation is now mostly configuration and
assembly of a dashboard using OverviewItems and the ChartSpace.
.. This refactor is to enable the ChartSpace to be used as a drop in
replacement for the existing TabView.
.. There are no functional enhancements in this commit, but the
overview chart shouls appear to be unchanged by the user.
Switching from start_index to start_date_local fixes#3457
Since Duration is End-Start+1, End is decremented to match elapsed_time.
fixLapSwims don't rely on Smart Recording being enabled and,
since km is distance at the end of the sample, a correction is added.
Michael Dagenais found this change makes the widgets to play nicer with
Windows Managers and avoids them to get on top of other programs windows.
Minimize and Restore is automatically handled now, so this commit partially
reverts b89019264e, removing MainWindow
state changes tracking, but keeping VideoWindow position tracking.
This is a clean up to remove conditional compilation for all Qt versions
older than the last known to work: Qt 5.9 with Qt WebEngine and Qt Charts.
Includes an update note to INSTALL documents.
When the video widget is scrolled, the MeterWidget windows appeared on
top of the Main Window user interface. Now the visible portion of the
Video Window is tracked and used as a clipping region. This avoids
blocking the controls on bottom toolbar.
Interpolation math fixes: Slope and interpolation behave correctly when
ride point location doesnt change.
In gpx read: do not open same file twice with different read flags.
When the main window is minimized on Linux, the MeterWidgets stay on the desktop.
A signal were added to the main window for state changes.
The VideoWindow connects to that signal and hide/shows the MeterWidgets accordingly.
Currently, when you move the main window, the MeterWidgets do not follow
and become out of place.
On every Telemetry update, check if the real position on screen of the
video window has changed in order to update the position of the meter
widgets. The Video Window can move for several reasons like when
scrolled or when the Main Window is moved. The Meter Widgets are not
clipped like the Video Window by its scroll area parent though.
Elevation widget was showing progress based on distance, which is workout distance and didn't accout for distance change due to skip forward/skip back.
Add routedistance to realtimedata so elevation widget can access it
elevation using routedistance to show progress
Fix uninit iterator in elevation widget paint
Draw route distance in elevation widget
.. estimates(model, cp|ftp|w'|pmax|x|date) - returns a vector of values
for the model selected.
As with the estimate() function, passing a duration value 'x' will
return the PD model estimate for that duration.
.. also removed hard coded model names.
Enable Meter Widgets overlaid on Video Window for Linux
Meter Widgets, with a transparent background over the video window, use
little screen estate while providing all the needed information. They
were added for WIN32 first but actually work fine on Linux with minor
flag adjustments.
.. tests(user|bests, duration|power) - with no parameters will just
return the number of tests in a ride/date range, or with 2 parameters
will retrieve user defined or bests found by algorithm the last
parameter defines if duration (secs) or power (watts) values are
returned.
After this change:
QtMacVideoWindow.h is used only for native macOS video options:
GC_VIDEO_AV (incomplete)
GC_VIDEO_QUICKTIME (obsolete)
Otherwise standard VideoWindow.h is included with the same options for
the three supported OS:
GC_VIDEO_NONE: placeholder for no video, currently used for macOS builds
GC_VIDEO_VLC: basic video control plus videosync, macOS experimental
GC_VIDEO_QT5: basic video control only, macOS experimental
Overlay Widgets only works on Windows with VLC.
Tested with VLC 3.0.8 on the 3 Operating Systems.
.. resample(old, new, yvector) - returns yvector resampled from old
sample rate to new sample rate. Assumes yvector has already been
interpolated or smoothed as needed (see the interpolate function)
For example, resampling to 10s power samples in a user chart:
{
finalise {
t <- samples(SECS);
xx <- seq(head(t,1),tail(t,1),10);
yy <- resample(RECINTSECS, 10, samples(POWER));
}
x { xx; }
y { yy; }
}
.. interpolate(linear|cubic|akima|steffen, x,y, xvalues) - returns a
vector of yvalues for each element in xvalues where the points
in x,y are interpolated using the selected algorithm passed
in the first parameter. e.g:
xx <- samples(SECS);
yy <- samples(POWER);
first <- head(xx,1);
last <- tail(xx,1);
zxx <- seq(first, last, 0.1); # 10ths of a second
zyy <- interpolate(cubic, xx, yy, zxx);
For Windows we use Python embeddable distribution
For Linux the relocatable Python AppImage
Packages included: sip, numpy, pandas, scipy, lmfit and plotly
[publish binaries]
.. added WBAL and WBALSECS as options for the samples() function to
retreive the w'bal value (in joules) and the secs too.
.. seconds are potentially different to the samples(SECS) values as
the w'bal series is always in 1s samples with gaps in recording
accounted for as part of the calculation.
[skip appveyor]
Initially: sip, numpy, pandas, scipy, lmfit and plotly
Deployed Python added to search path
Binaries reference the Python library on Cellar
Related to 2c0ce8f5c5
.. bin(data, bins) - returns a vector of the data binned into bins, any
data less than the first bin will be discarded, and data greater than
the last bin will be included in the last bin.
the returned bin is based upon counts, so will need to be scaled
if want duration in seconds.
e.g:
b <- bins(data, quantiles(data, c(0,0.25,5,0.75,1))) * RECINTSECS;
.. annotate - didn't validate parameters - seemingly inocuous but there
are multiple validators that update leaf->seriesType. When this did
not happen a) syntax errors were ignored (and caused a crash) and
b) functions like samples(POWER) returned the wrong data.
.. annotate - assumed parameters were numeric or string but did not
support vectors.
.. lots of use of 'it' as a variable, overriding the scope of the
DataFilter::eval() function parameter which in a couple of cases
led to SEGV ('it' is used when indexing vectors).
.. quantile(vector, quantiles) - returns quantile values for the vector
passed. quantiles can be a single value, or vector of values. The
quantile is expressed as a value between 0 and 1, where 0.5 would
represent the median. Values outside this range are truncated to
0 or 1.
.. daterange(from, to, expression) - executes the expression setting the
selected daterange as from-to.
.. any expression that honours the trend view date selection will use
the from-to dates provided.
.. for example, to get weight data for a specific daterange:
measures <- daterange("2020/01/01", "2020/05/01",
measures("Body", "WeightKg"));
.. meanmax(SERIES [, start, stop]) - now allows the user to provide a
date range for the meanmax data to collect. This is so you can, for
example, plot a 'last 90 days' curve:
{
finalise {
yy <- meanmax(POWER, Date-90, Date);
xx <- seq(1, length(yy), 1);
}
x { xx; }
y { yy; }
}
.. meanmax(xvector, yvector) - returns a mean-maximal curve in 1s
intervals from the x,y pair passed in.
the data will be truncated where xvector and yvector are different
lengths, negative y values are set to 0 and the entire dataset
will be interpolated where there are gaps (i.e. the data is not
presented in 1s intervals).