Fix non generic audio files not loading the audio player,

This commit is contained in:
KillzXGaming 2019-03-29 18:36:30 -04:00
parent 6afce74460
commit 8b2c8466fc
7 changed files with 4 additions and 1 deletions

Binary file not shown.

View file

@ -40,6 +40,9 @@ namespace FirstPlugin
public AudioPlayer OpenForm()
{
if (audioData == null)
throw new Exception("Audio data is null!");
AudioPlayer form = new AudioPlayer();
form.Text = FileName;
form.Dock = DockStyle.Fill;

View file

@ -131,7 +131,7 @@ namespace Switch_Toolbox.Library.Forms
memWav.Position = 0;
//Load the player
audioChannel.audioPlayer.Open(new MemoryStream(audioChannel.Data),"wav", activeDevice);
audioChannel.audioPlayer.Open(new MemoryStream(audioChannel.Data),"test.wav", activeDevice);
/* OpenFileDialog openFileDialog = new OpenFileDialog();
if (openFileDialog.ShowDialog() == DialogResult.OK)