commit
0b2e686d55
14 changed files with 370 additions and 93 deletions
|
@ -132,24 +132,30 @@ static void LEDUpdate(void * id, struct NoteFinder*nf)
|
|||
if( led->led_note_attached[j] != -1 ) continue;
|
||||
if( !led->timebased ) { selindex = j; break; }
|
||||
|
||||
float bias = 0;
|
||||
float timeimp = 1;
|
||||
if( led->snakey )
|
||||
{
|
||||
// bias = (j - led->snakeyplace + led->total_leds+(rand()%100)*.01);
|
||||
// if( bias > led->total_leds ) bias -= led->total_leds;
|
||||
float bias = 0;
|
||||
float timeimp = 1;
|
||||
|
||||
bias = (j - led->snakeyplace + led->total_leds) % led->total_leds;
|
||||
|
||||
if( bias > led->total_leds / 2 ) bias = led->total_leds - bias + 1;
|
||||
timeimp = 0;
|
||||
}
|
||||
|
||||
float score = led->time_of_change[j] * timeimp + bias;
|
||||
if( score < seltime )
|
||||
float score = led->time_of_change[j] * timeimp + bias;
|
||||
if( score < seltime )
|
||||
{
|
||||
seltime = score;
|
||||
selindex = j;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
seltime = score;
|
||||
selindex = j;
|
||||
if( led->time_of_change[j] < seltime )
|
||||
{
|
||||
seltime = led->time_of_change[j];
|
||||
selindex = j;
|
||||
}
|
||||
}
|
||||
}
|
||||
if( selindex >= 0 )
|
||||
|
|
|
@ -9,6 +9,9 @@ steady_bright = 0
|
|||
|
||||
rgby = 1
|
||||
sourcename = alsa_output.pci-0000_00_1f.3.analog-stereo.monitor
|
||||
#sourcename = default
|
||||
|
||||
|
||||
#alsa_output.pci-0000_01_00.1.hdmi-stereo.monitor
|
||||
# alsa_output.pci-0000_01_00.1.hdmi-stereo-extra1.monitor
|
||||
#alsa_output.pci-0000_00_1f.3.analog-stereo.monitor
|
||||
|
@ -16,12 +19,12 @@ skipfirst = 0
|
|||
firstval = 0
|
||||
port = 7777
|
||||
|
||||
address = 192.168.3.192
|
||||
address = 192.168.11.157
|
||||
|
||||
slope=.10
|
||||
amplify=.5
|
||||
|
||||
qtyamp=50
|
||||
qtyamp=120
|
||||
timebased=1
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue