mobiletechtracker / NetCoreAudio

Allows playback of audio files on .NET Core with minimal dependencies
MIT License
124 stars 20 forks source link

Error when play .wav and .mp3 #5

Closed Doughboy02 closed 5 years ago

Doughboy02 commented 5 years ago

I get an error whenever trying to run the line Player.Play(filePath).GetAwaiter().GetResult();

Error Error executing MCI command 'Status C:\Users\Panda\source\repos\TextToSpeechApi\TextToSpeechApi\bin\Debug\netcoreapp2.1\Voices\testing sound.mp3 Length'. Error code: 310. Message: Specify a device or driver name that is less than 79 characters.

Wasn't sure if this was the same error that has already been posted considering the Error code is different...

MortenChristiansen commented 5 years ago

Have you tried using a relative path?

fiodarsazanavets commented 5 years ago

On Windows, there is a hard limit on the number of characters you can use in the path or audio device alias in the media interface. As suggested, please use a relative path.

fiodarsazanavets commented 5 years ago

Closing since this issue is caused by the limitation of Windows media interface and not the library itself.