The following commit has been merged in the master branch:
commit 74230d22f516fda230203d40db5d5ecd466315d6
Author: Andrei Zavada <[email protected]>
Date:   Sun Apr 14 00:43:19 2013 +0300

    properly banish nan's from profiles on msmt overview

diff --git a/src/ui/mw/measurements.cc b/src/ui/mw/measurements.cc
index 5025bfe..c5ed48f 100644
--- a/src/ui/mw/measurements.cc
+++ b/src/ui/mw/measurements.cc
@@ -122,9 +122,10 @@ draw_timeline( cairo_t *cr) const
                                tmp[i] = (*cprofile)[i].metric;
                        sigproc::smooth( tmp, _p._p.smooth_profile);
                        for ( size_t i = 0; i < tmp.size(); ++i )
-                               cairo_line_to( cr,
-                                              tl_left_margin() + 
j_tl_pixel_start + ((float)i)/tmp.size() * j_tl_pixels,
-                                              -tmp[i] * scale + 
timeline_height()-12);
+                               if ( isfinite(tmp[i]) )
+                                       cairo_line_to( cr,
+                                                      tl_left_margin() + 
j_tl_pixel_start + ((float)i)/tmp.size() * j_tl_pixels,
+                                                      -tmp[i] * scale + 
timeline_height()-12);
                }
                cairo_line_to( cr, j_tl_pixel_start + tl_left_margin() + 
j_tl_pixels, timeline_height()-12);
                cairo_fill( cr);

-- 
Sleep experiment manager

_______________________________________________
debian-med-commit mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/debian-med-commit

Reply via email to