Поддерживаемые музыкальные файлы от аудио библиотеки BASS - PullRequest
1 голос
/ 30 января 2012

Есть ли способ узнать, поддерживается ли расширение файла аудио библиотекой Bass (например, WAV / AIFF / MP3 / MP2 / MP1 / OGG)? Я хотел бы написать такую ​​функцию, как:

Public void  Play(string File)
{
   if(IsSupportedFile(file)
     {

       // Add the appropriate code to play the file
     }

}
Public bool isSupported(string File)
{
  // Should return true if the file extension is supported by bass audio and add ons
}

1 Ответ

3 голосов
/ 08 декабря 2012

Попробуйте:

Public bool isSupported(string File)
{
  return Un4seen.Bass.Utils.BASSAddOnIsFileSupported(Nothing, file);
}
...