diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2013-05-11 22:56:53 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2013-05-12 06:36:55 -0700 |
commit | 32941cb84f27ddc4397857afed84bb156f983e4e (patch) | |
tree | 05fc62da554b7d7ea19646d6f018dad59bc5221a /qt-ui | |
parent | d62d1124cfed290a8f9c0cc8d5c4a83de5308e84 (diff) | |
download | subsurface-32941cb84f27ddc4397857afed84bb156f983e4e.tar.gz |
Don't print temperatures that are below 200K
That threshold is of course ridiculous and arbitrary - but it seems like a
good assumption to make that anything below that is DEFINITELY not valid
data.
Because of the way the scene grows automatically in Qt, printing these
texts would squish the profile into one thin line.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r-- | qt-ui/profilegraphics.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/qt-ui/profilegraphics.cpp b/qt-ui/profilegraphics.cpp index 54b0df8b1..751d685e5 100644 --- a/qt-ui/profilegraphics.cpp +++ b/qt-ui/profilegraphics.cpp @@ -671,15 +671,15 @@ void ProfileGraphicsView::plot_temperature_text() (abs(mkelvin - last_printed_temp) < 400)) continue; last = sec; - - plot_single_temp_text(sec,mkelvin); + if (mkelvin > 200000) + plot_single_temp_text(sec,mkelvin); last_printed_temp = mkelvin; } /* it would be nice to print the end temperature, if it's * different or if the last temperature print has been more * than a quarter of the dive back */ - if ((abs(last_temperature - last_printed_temp) > 500) || - ((double)last / (double)sec < 0.75)) + if (last_temperature > 200000 && + ((abs(last_temperature - last_printed_temp) > 500) || ((double)last / (double)sec < 0.75))) plot_single_temp_text(sec, last_temperature); } |