hello,
there's a problem i'm experiencing when i'm using a slightly modified
smart_crossfade on our rotation. the applied modification should allow
that tracks are being sequenced (the default transition) whenever news
are going to be broadcast. news.mp3's are being recognized by their
metadata. the problem is they aren't sequenced as they should - they're
always faded in.
in order to track down the problem i've stripped down smart_crossfade to
just two transition alternatives and use it on a simple playlist:
01-music.mp3
02-news.mp3
03-music.mp3
which i'm playing in "normal" mode. my conditional_smart_crossfade
function is set to crossfade between music tracks and sequence when news
are either the last or next track.
when running this setup i experience that news are being sequenced on
the first round through the playlist exactly the way they're expected to
do, but on the next and all following runs of the playlist the news are
clearly being faded in (no crossing), although the log output shows
always that the proper branch was chosen.
the transitions at the end of news towards the next music track are
always proper sequences without fading.
the whole .liq i'm using reads as this:
-------------------------------------------------------------------------------------------------------------------
set( "log.file", false)
set( "log.stdout", true)
def conditional_smart_crossfade( ~start_next = 5.,
~fade_in = 3.,
~fade_out = 3.,
~high = -15.,
~medium = -32.,
~margin = 4.,
~width = 2.,
~conservative = false,
~default = ( fun( a, b) ->
sequence( [a, b])),
s)
fade.out = fade.out( type = "sin", duration = fade_out)
fade.in = fade.in( type = "sin", duration = fade_in)
add = fun( a, b) -> add( normalize = false, [b, a])
log = log( label = "TRANSITION")
def transition( a, b, ma, mb, sa, sb)
if string.match( pattern = 'news', ma["artist"])
or string.match( pattern = 'news', mb["artist"])
then
log( "transition in effect: NONE for news")
default( sa, sb) *)
else
log( "transition in effect: CROSSED for music")
add( fade.out(sa), fade.in(sb))
end
end
smart_cross( width = width, duration = start_next, conservative =
conservative, transition, s)
end
s = playlist( mode = "normal", "/path_to_my_3_files_rotation")
s = conditional_smart_crossfade( s)
out( s)
-------------------------------------------------------------------------------------------------------------------
*) it doesn't make a difference whether i'm using default( sa, sb) or
sequence( [sa, sb]) !
the behaviour is not track-dependent. selecting other tracks for
sequencing led to the same behaviour (only difference: often they didn't
sequence properly even on the first run).
when i'm changing the branching condition to "true", thus always
choosing the default (sequencing) transition, all sequences are played
properly.
thanks in advance for any help with that issue
peter
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users