You can easily control cue and crossfade points per song in liquidsoap using metadata via the annotate protocol. Namely there are 4 variables you can pass as metadata, liq_fade_in, liq_fade_out, liq_cue_in, and liq_cue_out. These do what you would expect.
However, you can also use the annotate protocol even if you aren’t using a textfile playlist. If you are using request.dynamic you can pass a string containing the annotate metadata to request.create.
You have to use some operators on your source to actually get the crossfades and fades to apply however. You’ll need cue_cut and one of the crossfade operators (crossfade or smart_crossfade).
Assuming you have assigned a playlist or request.dynamic source to backup_playlist:
This opens up quite a few possibilities in my mind. For example you could assign per-track fades or cue points in a database, fetch them via an API or similar in liquidsoap and use the annotate protocol with request.dynamic to have per track fades/cuepoints.
I’m using something like this in my own project right now, where I get all the
information for the next track, including fade and cue points, via an external
ruby script:
Modern Online Radio with Liquidsoap Book - Free Sample
Need more help with liquidsoap?
Can’t get your script to work?
I wrote a book to help you learn Liquidsoap. The book covers all aspects of liquidsoap, from getting started, to making dynamic streams, audio processing, video, customizing metadata, authentication, and more. The book is available for purchase now here!
You can get a free sample chapter of my book! Just enter your email address to subscribe to my mailing list and I'll send you a free PDF sample of the book in return.