comparison layer/TimeValueLayer.cpp @ 1391:c39f2d439d59 spectrogramparam

Toward highlighting peaks on spectrum
author Chris Cannam
date Tue, 13 Nov 2018 15:16:48 +0000
parents a1393b4384a5
children 28075cc658c9
comparison
equal deleted inserted replaced
1390:3c99083a4d83 1391:c39f2d439d59
563 frame - prevPoints.begin()->frame) { 563 frame - prevPoints.begin()->frame) {
564 usePoints = nextPoints; 564 usePoints = nextPoints;
565 } 565 }
566 566
567 if (!usePoints.empty()) { 567 if (!usePoints.empty()) {
568 int fuzz = 2; 568 int fuzz = ViewManager::scalePixelSize(2);
569 int px = v->getXForFrame(usePoints.begin()->frame); 569 int px = v->getXForFrame(usePoints.begin()->frame);
570 if ((px > x && px - x > fuzz) || 570 if ((px > x && px - x > fuzz) ||
571 (px < x && x - px > fuzz + 3)) { 571 (px < x && x - px > fuzz + 3)) {
572 usePoints.clear(); 572 usePoints.clear();
573 } 573 }