Le 13 juin 2011 07:40, Akos Veres <[email protected]> a écrit :
> Hi Liquidsoap devs/users,

Hi Alkos!

> Lately I've been lurking in the #savonet channel, but it seems rather quiet,
> so I've thought of bugging you guys here.

Yeah, we do not have enough time to participate in the IRC channel
these days and we try to focus on responding more in-depth through the
mailing-list..

> I'm having problems outputing the metadata to a file, or anywhere. What I'm
> trying to achieve is to perform a system() function when the track changes
> (eventually if I could get the next playing track that would be great too,
> but I didn't find the function for that yet.).
> Currently my conf file looks like this: http://pastebin.com/YbZZzHz1
> I tried reading the API, but I might have not too much knowledge
> understanding the methods, so if you guys could guide me to any
> docs/references, please feel free, I'm not scared to read.

Heh; you were not far from the right solution :)

Long story short: the liquidsoap scripting language is functional.
Therefore, you generally do not update a variable but redefine it.

In your script, line 18 should be:
radio = on_track(write_track, radio)
i.e. you redefine radio with the on_metadata wrapper added on top.

Then the new radio source will be used in the output, which will pull
data from it and ultimately trigger the on_metadata function with each
metadata pulled with the data.

Good luck with your script and do not hesitate to come back with more questions!
Romain

------------------------------------------------------------------------------
EditLive Enterprise is the world's most technically advanced content
authoring tool. Experience the power of Track Changes, Inline Image
Editing and ensure content is compliant with Accessibility Checking.
http://p.sf.net/sfu/ephox-dev2dev
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users

Reply via email to