I have this code working with the older FMOD EX API, AND, I have this working in C++ with a straight 1:1 translation of function calls.
WHen I try it in Unity, it seemingly opens the stream, sets the “open state” to Ready, but on an immediate read of the format throws an ERR_FILE_EOF.
result = music.getOpenState(out openstate, out percentbuffered, out starving, out busy);
ERRCHECK(result);
if (openstate == FMOD.OPENSTATE.READY)
{
int dead1 = 0;
int dead2 = 0;
FMOD.SOUND_TYPE soundtype;
FMOD.SOUND_FORMAT refSoundFormat;
result = music.getFormat(out soundtype, out refSoundFormat, out dead1, out dead2);
ERRCHECK(result); <-- prints out that the stream is ERR_FILE_EOF and not ready?!
}
Again, same code, more or less 1:1 in C++ (pointers, etc...) works perfectly fine to parse the urls (e.g.):
supplied.
Note that if I stick the raw URL to the MP3 or OGG it also works fine, just not on .pls or .m3u resources anymore.