Пример #1
0
 private void btnExprShow_Click(object sender, EventArgs e)
 {
     using var s = GenerateFromExpression();
     //using var v = new global::Synthesizer.WaveFormView2(s);
     using var v = new WaveFormView(s);
     v.ShowDialog();
 }
Пример #2
0
        private void btnShowWaveForm_Click(object sender, EventArgs e)
        {
            ErnstTech.SoundCore.WaveForm form = new ErnstTech.SoundCore.WaveForm(new ErnstTech.SoundCore.WaveFormat(2, 44100, 16));
            form.BaseFrequency = 100;

            System.IO.Stream s = form.GenerateWave();

            using (WaveFormView view = new WaveFormView(s))
            {
                view.ZoomFactor = 0.25f;
                view.ShowDialog();
            }

            s.Close();
        }
Пример #3
0
 private void btnViewWaveForm_Click(object sender, EventArgs e)
 {
     using (OpenFileDialog ofd = new OpenFileDialog())
     {
         if (ofd.ShowDialog() == DialogResult.OK)
         {
             System.IO.Stream s = ofd.OpenFile();
             using (WaveFormView view = new WaveFormView(s))
             {
                 //view.ZoomFactor = 0.25f;
                 view.ShowDialog();
             }
             s.Close();
         }
     }
 }