Le Monday 17 November 2008 21:50:54 Łukasz Jarosław Mozer, vous avez écrit :
> Hi there.
Hi !
> /Excuse for my mistakes and not very good english skills, i'm not
> native english speaker, but i hope that you understand me/
No pb !
> I'm new to liquidsoap - i discovered it only few days ago, but it was
> quick to migrate to it. Primary goal, was to provide low quality
> stream for our listeners with stable and foolproof tool.
>
> Of course, second goal was to replace iceS to save resources on our
> server. And then problem begin.
>
> For automatic play, we have written PHP app with web gui that allows
> us to manage of playlists, time periods, genres, tracks, etc.
>
> So i've wrote php script that returns track path and name, based on
> database stored values:
>
> def querytrack () =
> log(">>> Requesting for track from pilot")
> request.create(audio=true,
> get_process_output("/home/radio/pilot/decyzor.php")) end
>
> pilot = request.dynamic(querytrack)
> pilot = mksafe(pilot)
> pilot = smart_crossfade(pilot)
> pilot = rewrite_metadata([("song","$(display_title)")],pilot)
> pilot = normalize(pilot)
>
> live = input.http("http://some.mount:8000/point")
>
> radio = fallback(track_sensitive=false, transitions=[crossfade,crossfade],
> [live, pilot])
>
> All of that i wrote using provied by documentation samples. But worst
> thing is, that liquidsoap queries for track from playlist in advance.
> So it have always at least 2 tracks in playlist. It causes me lot of
> headache, because even if i schedule some set of music to play at
> certain weekday-hour, it always start playing even 15 minutes later.
> I've tried to hack this in my php script, adding average(songlen)*3
> to every timetable query. But it's no
Yes, this is one of the specific features that confuse users. The problem is
that between the moment when a song is submited to liquidsoap and the moment
it is ready to be streamd, there can be some long-lasting action to perform,
like downloading a file from a FTP or else..
Hence, liquidsoap tries to feed in advance each of its source, in order to
never fail to feed the icecast server with audio.
Most of the time, we use a song notification to notify the system when a song
is actually played. Wouldn't this fit your needs ?
It is true that it can be quite difficult with such an asynchronous system to
assert that a given song will be played at a given time. However, you can
reduce the amount of audio data that is downloaded in advance, using the
length and default_duration parameters. The first one defines how much audio
data shall be cached, and the second what is the default length for an mp3
song (for technical reasons, mp3 songs length is not well known, and
computing it costs a lot of CPU power, so we assume a default length)
Using these parameters, you should be able to have only one song waiting to be
streamed.
Romain
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users