App-EventStreamr
view release on metacpan or search on metacpan
bin/station-mgr.pl view on Meta::CPAN
{
"host" : "",
"port" : "",
"password" : "",
"stream" : ""
}
}
CONFIG
my $config = from_json($json);
return $config;
}
sub blank_settings {
my $json = <<CONFIG;
{
"controller" : "http://10.4.4.10:5001"
}
CONFIG
my $config = from_json($json);
return $config;
}
=pod
=encoding UTF-8
=head1 NAME
station-mgr - station-mgr - Core Station Manager script
=head1 VERSION
version 0.5
=head1 SYNOPSIS
Usage:
station-mgr.pl
=head1 AUTHOR
Leon Wright < techman@cpan.org >
=head1 COPYRIGHT AND LICENSE
This software is Copyright (c) 2014 by Leon Wright.
This is free software, licensed under:
The GNU Affero General Public License, Version 3, November 2007
=cut
__END__
(dev) bofh-sider:~/git/eventstreamr/station $ ps waux|grep dv
leon 19898 2.5 0.1 850956 24560 pts/12 Sl+ 11:35 1:21 dvswitch -h localhost -p 1234
leon 20723 0.0 0.0 4404 612 ? S 12:27 0:00 sh -c ffmpeg -f video4linux2 -s vga -r 25 -i /dev/video0 -target pal-dv - | dvsource-file /dev/stdin -h localhost -p 1234
leon 20724 8.0 0.1 130680 24884 ? S 12:27 0:01 ffmpeg -f video4linux2 -s vga -r 25 -i /dev/video0 -target pal-dv -
leon 20725 0.1 0.0 10796 860 ? S 12:27 0:00 dvsource-file /dev/stdin -h localhost -p 1234
leon 20735 0.0 0.0 9396 920 pts/16 S+ 12:28 0:00 grep --color=auto dv
$VAR1 = {
'commands' => {
'alsa' => 'dvsource-alsa -h $host -p $port hw:$device',
'dv' => 'dvsource-firewire -h $host -p $port -c $device',
'record' => 'dvsink-files $device',
'v4l' => 'ffmpeg -f video4linux2 -s vga -r 25 -i $device -target pal-dv - | dvsource-file /dev/stdin -h $host -p $port',
'stream' => 'dvsink-command -- ffmpeg2theora - -f dv -F 25:2 --speedlevel 0 -v 4 --optimize -V 420 --soft-target -a 4 -c 1 -H 44100 -o - | oggfwd $host $port 8000 $password /$stream',
'file' => 'dvsource-file -l $device',
'dvswitch' => 'dvswitch -h 0.0.0.0 -p $port'
},
'config' => {
'roles' => [
{
'role' => 'ingest'
},
{
'role' => 'mixer'
},
{
'role' => 'stream'
}
],
'nickname' => 'test',
'room' => 'room1',
'devices' => [
{
'name' => 'Chicony Electronics Co. Ltd. ASUS USB2.0 Webcam',
'id' => 'video0',
'type' => 'v4l',
'device' => '/dev/video0'
},
{
'name' => 'C-Media Electronics, Inc. ',
'usbid' => '0d8c:0008',
'id' => '2',
'type' => 'alsa',
'device' => '2'
}
],
'device_control' => {
'video0' => {
'run' => '0'
}
},
'run' => '0',
'macaddress' => '00:15:58:d8:85:c7',
'mixer' => {
'port' => '1234',
'host' => 'localhost'
}
},
'dvswitch' => {
'check' => 1
},
'devices' => {
'array' => [
( run in 1.982 second using v1.01-cache-2.11-cpan-39bf76dae61 )