diff src/app/waveform/waveform.component.ts @ 299:46a6b91ea51b

Update to match latest changes to piper-js shape structures
author Chris Cannam <cannam@all-day-breakfast.com>
date Thu, 11 May 2017 11:29:54 +0100
parents bc67503ea8c6
children 1d39cc796046
line wrap: on
line diff
--- a/src/app/waveform/waveform.component.ts	Wed May 10 15:42:26 2017 +0100
+++ b/src/app/waveform/waveform.component.ts	Thu May 11 11:29:54 2017 +0100
@@ -21,10 +21,9 @@
 import {
   FeatureCollection,
   SimpleResponse,
-  VectorFeatures,
-  MatrixFeatures,
-  TrackFeature,
-  TrackFeatures
+  VectorFeature,
+  MatrixFeature,
+  TracksFeature
 } from 'piper/HigherLevelUtilities';
 import {toSeconds} from 'piper';
 import {FeatureList, Feature} from 'piper/Feature';
@@ -697,7 +696,8 @@
     switch (features.shape) {
 
       case 'vector': {
-        const collected = features.collected as VectorFeatures;
+        const collected = features.collected as VectorFeature;
+	const startTime = collected.startTime; //!!! + make use of
 	const stepDuration = collected.stepDuration;
 	const featureData = collected.data;
 	this.addLineLayer(stepDuration, featureData, colour);
@@ -807,9 +807,9 @@
         break;
       }
       case 'matrix': {
-	const collected = features.collected as MatrixFeatures;
+	const collected = features.collected as MatrixFeature;
+        const startTime = collected.startTime; //!!! + make use of
         const stepDuration = collected.stepDuration;
-        // !!! + start time
         const matrixData = collected.data;
 
         if (matrixData.length === 0) {