0
0

I’m programming a little application and i wanna ply an mp3 file with fmod but i wanna use fread() routines…
I just wanna know how i can use the data stored in the buffer returned by fread().
I’ve tried FSOUND_Sample_Upload and FSOUND_Play_Song()…But it doesn’t work…Or it’s my buffer size, in fread() function, is too small or too large (i use a char[1024] for my buffer)….
Thanks for helping me…

ADreNaLiNe-DJ

  • You must to post comments
0
0

Did you try FSOUND_Stream_Open ?

  • You must to post comments
0
0

Yes, i’ve tried but i don’t need it…
I wanna use Samples but it doesn’t work with a code like this:

include <stdio.h>

include <stdlib.h>

int main (void)
{
File fdesc;
char buffer[1024];
int len;

fdesc=fopen(“test.mp3”, “rb”);
while(!feof(fdesc))
{
len=fread(temp, 1, 1024, fdesc);
//need fmod routines to play the buffer
}
fclose(fdesc);
}

The goal of this program is to send the buffer in a socket and play it on another machine (like an audio streaming server)…

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.