diff layer/WaveformLayer.cpp @ 71:72fa239a4880

* Modify to use Vamp SDK for proper feature extraction plugins. Requires that the vamp-plugin-sdk directory tree be present below plugin/ (it's separate in Subversion).
author Chris Cannam
date Fri, 31 Mar 2006 15:56:35 +0000
parents 6dad2724f3aa
children 45ba0b381c5d
line wrap: on
line diff
--- a/layer/WaveformLayer.cpp	Thu Mar 30 15:00:22 2006 +0000
+++ b/layer/WaveformLayer.cpp	Fri Mar 31 15:56:35 2006 +0000
@@ -600,8 +600,12 @@
 	    (ch, frame0 < 0 ? 0 : frame0, frame1, modelZoomLevel);
         
 	if (mergingChannels || mixingChannels) {
-	    otherChannelRanges = m_model->getRanges
-		(1, frame0 < 0 ? 0 : frame0, frame1, modelZoomLevel);
+            if (m_model->getChannelCount() > 1) {
+                otherChannelRanges = m_model->getRanges
+                    (1, frame0 < 0 ? 0 : frame0, frame1, modelZoomLevel);
+            } else {
+                otherChannelRanges = ranges;
+            }
 	}
 
 	for (int x = x0; x <= x1; ++x) {