private void DrawFourierResults(int nSamples) { if (fg != null) { waveGrid.Children.Remove(fg); } this.Height = 300; fg = new FourierGraph(this, Af, nSamples); fg.Visibility = Visibility.Visible; fg.SetValue(Grid.RowProperty, 3); fg.SetValue(Grid.ColumnProperty, 0); fg.SetValue(Grid.ColumnSpanProperty, 4); waveGrid.Children.Add(fg); }
//Loads a wave file from win32 recording. Wave is only held in memory at this time. //Does not save it yet. public Wave(MainWindow mainWindowInst, TopToolbars tbs) { scale = 1; SaveHeader(); fg = null; this.tbs = tbs; filePath = ""; mouseDown = false; InitializeComponent(); win = mainWindowInst; Show.IsEnabled = false; h = getRecordHead(); convertPtrToArray(getData()); SetWaveGrid(); DrawWave(waveSamples); SetInfo(); }