0
0

Does anybody has a piece of code on how to play an mp3 from internet with media player? I want to prevent the use of mp3 with fmod and want to use fmod just for ogg. I am searching already a long time for it with no results, but saw a software which did it, they played a mp3 file from internet without downloading it. As everybody know, media player can open an url and play the mp3, but I did not find any function in the media player component which open an url. Just the filename dont do it, it will just download the file and play it after that.

  • You must to post comments
0
0

set the fileName property to the URL, that should work.

  • You must to post comments
0
0

No, that does not work. MP will just download the file before it plays…

  • You must to post comments
0
0

[quote="softtouch":2ltg6b2r]No, that does not work. MP will just download the file before it plays…[/quote:2ltg6b2r]

No, the file isn’t downloaded but it first prebuffer and stream from the internet.

  • You must to post comments
0
0

[quote="KarLKoX":3il0lcs1][quote="softtouch":3il0lcs1]No, that does not work. MP will just download the file before it plays…[/quote:3il0lcs1]

No, the file isn’t downloaded but it first prebuffer and stream from the internet.[/quote:3il0lcs1]

Thats not correct. I tried it. I tried to stream a 4MB mp3 and it took 40 seconds before it played. Thats exact the time for the download. I also observed via DU meter my network and it was permanent downloading with 1mbit. After 40 seconds, no more internet access and the file started to play. So I used Mediaplayer direct, not the control, it took 2 seconds and it start playing, and every 3-5 seconds, data are received from the net.
If you use the filename property of mediaplayer component in delphi, it just download first. I only know about the activex component which comes with MP 9 and 10, this has an URL property which streams, but not the original delphi component.

  • You must to post comments
0
0

I am talking about url from shoutcast servers not about mp3 placed in a ftp/http server, if you want to stream from a ftp it is up to you to read an amount of data and pass it to fmod for the decoding part.

  • You must to post comments
Showing 5 results
Your Answer

Please first to submit.