Ejemplo n.º 1
0
        private async Task LoadWaveformsAsync(IWaveSource waveSource)
        {
            Channels = null;
            var channelData = await WaveformData.GetData(waveSource);

            Channels =
                new ObservableCollection <WaveformDataModel>(channelData.Select(x => new WaveformDataModel {
                Data = x
            }));
        }
Ejemplo n.º 2
0
        private async Task LoadWaveformsAsync(IWaveSource waveSource)
        {
            Channels = null;
            //read the specified waveSource into n arrays of samples where n is the number of channels of the waveSource
            var channelData = await WaveformData.GetData(waveSource);

            //by setting the Channels property, the Waveform Control automatically renders the waveform
            Channels =
                new ObservableCollection <WaveformDataModel>(channelData.Select(x => new WaveformDataModel {
                Data = x
            }));
        }