0
0

Hi Everyone!

I’ve got a (I think silly, but hey – I just started ;)) question.
I’m sending mp3 audio data over a socket connection (bluetooth – bluez libs) and I’d like to play it at the client machine.
My Problem is, that I’ve got no idea how I can get the audio data (at the client machine) from the socket to the FAUDIO_Stream_Open( ….) Method, cause the method does only allow a *char pointer.

What should I do? Create a new Thread, which reads the audio data into the memory and pass a pointer to the FAUDIO_Stream_Open method? Or is there a better way to do?

Hope someone can help me!!!
THX

Rantanplan

  • You must to post comments
0
0

I think you should have a look at FSOUND_Stream_Create, it will create a callback that asks for new data when needed. But you most timing funtions won’t work because fmod doesn’t know when the stream stops

good luck 😉

  • You must to post comments
0
0

Thx Chris for the answer!

I figured out that I’ll have to use the file callback methods. So I have to overwrite them and emulate a virtual file for the bluetooth connection.
Has anyone got some ideas how to emulate the seeking???

Hopefully someone got some ideas – it’s really hard to find some information about that topic! (play music over socket streams)

greets

Markus

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.