Mercurial > hg > ugly-duckling
comparison src/app/app.component.ts @ 63:dc07ec243491
Use Collect instead of Process.
author | Lucas Thompson <dev@lucas.im> |
---|---|
date | Fri, 09 Dec 2016 14:06:44 +0000 |
parents | f31b14e2132e |
children | f5072712ddf5 |
comparison
equal
deleted
inserted
replaced
62:2171dd56756c | 63:dc07ec243491 |
---|---|
36 } | 36 } |
37 | 37 |
38 extractFeatures(outputInfo: ExtractorOutputInfo): void { | 38 extractFeatures(outputInfo: ExtractorOutputInfo): void { |
39 if (!this.canExtract || !outputInfo) return; | 39 if (!this.canExtract || !outputInfo) return; |
40 this.canExtract = false; | 40 this.canExtract = false; |
41 this.piperService.process({ | 41 this.piperService.collect({ |
42 audioData: [...Array(this.audioBuffer.numberOfChannels).keys()] | 42 audioData: [...Array(this.audioBuffer.numberOfChannels).keys()] |
43 .map(i => this.audioBuffer.getChannelData(i)), | 43 .map(i => this.audioBuffer.getChannelData(i)), |
44 audioFormat: { | 44 audioFormat: { |
45 sampleRate: this.audioBuffer.sampleRate, | 45 sampleRate: this.audioBuffer.sampleRate, |
46 channelCount: this.audioBuffer.numberOfChannels | 46 channelCount: this.audioBuffer.numberOfChannels |