From 32941cb84f27ddc4397857afed84bb156f983e4e Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Sat, 11 May 2013 22:56:53 -0700 Subject: 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 --- qt-ui/profilegraphics.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'qt-ui') 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); } -- cgit v1.2.3-70-g09d2