changeset 1430:31499c3520ee single-point

Use overspill to render time-value point line properly at edges
author Chris Cannam
date Wed, 20 Mar 2019 11:18:45 +0000
parents 8a7c82282fbc
children af824022bffd
files layer/RegionLayer.h layer/TimeValueLayer.cpp view/View.cpp
diffstat 3 files changed, 6 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/layer/RegionLayer.h	Tue Mar 19 13:06:35 2019 +0000
+++ b/layer/RegionLayer.h	Wed Mar 20 11:18:45 2019 +0000
@@ -48,11 +48,11 @@
     QString getLabelPreceding(sv_frame_t) const override;
 
     bool snapToFeatureFrame(LayerGeometryProvider *v, sv_frame_t &frame,
-                                    int &resolution,
-                                    SnapType snap) const override;
+                            int &resolution,
+                            SnapType snap) const override;
     bool snapToSimilarFeature(LayerGeometryProvider *v, sv_frame_t &frame,
-                                      int &resolution,
-                                      SnapType snap) const override;
+                              int &resolution,
+                              SnapType snap) const override;
 
     void drawStart(LayerGeometryProvider *v, QMouseEvent *) override;
     void drawDrag(LayerGeometryProvider *v, QMouseEvent *) override;
--- a/layer/TimeValueLayer.cpp	Tue Mar 19 13:06:35 2019 +0000
+++ b/layer/TimeValueLayer.cpp	Wed Mar 20 11:18:45 2019 +0000
@@ -938,7 +938,7 @@
     sv_frame_t frame1 = v->getFrameForX(x1);
     if (m_derivative) --frame0;
 
-    EventVector points(m_model->getEventsWithin(frame0, frame1 - frame0));
+    EventVector points(m_model->getEventsWithin(frame0, frame1 - frame0, 1));
     if (points.empty()) return;
 
     paint.setPen(getBaseQColor());
@@ -949,7 +949,7 @@
 
 #ifdef DEBUG_TIME_VALUE_LAYER
     cerr << "TimeValueLayer::paint: resolution is "
-              << m_model->getResolution() << " frames" << endl;
+         << m_model->getResolution() << " frames" << endl;
 #endif
 
     double min = m_model->getValueMinimum();
--- a/view/View.cpp	Tue Mar 19 13:06:35 2019 +0000
+++ b/view/View.cpp	Wed Mar 20 11:18:45 2019 +0000
@@ -1796,8 +1796,6 @@
 
             } else {
 
-//                cerr << "progress = " << completion << endl;
-
                 if (!pb->isVisible()) {
                     i->second.lastCheck = 0;
                     timer->setInterval(2000);