From 6dded5c8eade9830ea60a7ecb9079de117c01824 Mon Sep 17 00:00:00 2001 From: yomguy Date: Mon, 9 Jan 2012 14:36:53 +0100 Subject: [PATCH] re-organize --- .../telecaster/gst_video_double_shout2.sh | 23 ++++++++++++++++++ .../tc_video_simple_webm_stream_hd.sh | 18 ++++++++++++++ .../{ => telecaster}/media/mp3/silence.mp3 | Bin .../{ => telecaster}/media/ogg/silence.ogg | Bin conf/{home => usr/local}/bin/rotate_desktop | 0 .../share/applications/rotate_desktop.desktop | 2 +- install.py | 7 ++++-- 7 files changed, 47 insertions(+), 3 deletions(-) create mode 100755 conf/home/fluxbox/telecaster/gst_video_double_shout2.sh create mode 100755 conf/home/fluxbox/telecaster/tc_video_simple_webm_stream_hd.sh rename conf/home/{ => telecaster}/media/mp3/silence.mp3 (100%) rename conf/home/{ => telecaster}/media/ogg/silence.ogg (100%) rename conf/{home => usr/local}/bin/rotate_desktop (100%) diff --git a/conf/home/fluxbox/telecaster/gst_video_double_shout2.sh b/conf/home/fluxbox/telecaster/gst_video_double_shout2.sh new file mode 100755 index 0000000..cd25b51 --- /dev/null +++ b/conf/home/fluxbox/telecaster/gst_video_double_shout2.sh @@ -0,0 +1,23 @@ +#!/bin/sh + +# Start TeleCaster video channel + +WIDTH=480 +HEIGHT=270 + +gst-launch v4l2src device=/dev/video0 ! queue ! videoscale ! video/x-raw-yuv, width=160, height=120 \ + ! queue ! videorate ! video/x-raw-yuv,framerate=25/1 \ + ! queue ! videomixer name=mix sink_1::xpos=0 sink_1::ypos=0 sink_1::alpha=0.9 \ + ! queue ! ffmpegcolorspace ! queue ! theoraenc quality=25 ! muxout. \ + jackaudiosrc connect=1 ! audioconvert ! audio/x-raw-int,rate=44100,channels=1,width=16 \ + ! queue ! audioconvert ! vorbisenc ! queue ! muxout. \ + oggmux name=muxout ! queue ! shout2send mount=/telecaster_live_video.ogg port=8000 password=source2parisson ip=127.0.0.1 \ + v4l2src device=/dev/video1 ! queue ! videoscale ! video/x-raw-yuv, width=$WIDTH, height=$HEIGHT \ + ! queue ! videorate ! video/x-raw-yuv,framerate=25/1 ! mix. \ + > /dev/null & + +sleep 2 + +jack_disconnect system:capture_1 gst-launch-0.10:in_jackaudiosrc0_1 +jack_connect jack_rack:out_1 gst-launch-0.10:in_jackaudiosrc0_1 + diff --git a/conf/home/fluxbox/telecaster/tc_video_simple_webm_stream_hd.sh b/conf/home/fluxbox/telecaster/tc_video_simple_webm_stream_hd.sh new file mode 100755 index 0000000..7afd26c --- /dev/null +++ b/conf/home/fluxbox/telecaster/tc_video_simple_webm_stream_hd.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +# Start TeleCaster video channel + +WIDTH=1024 +HEIGHT=576 + +gst-launch v4l2src device=/dev/video0 ! video/x-raw-yuv, width=$WIDTH, height=$HEIGHT \ + ! queue ! videoflip method=rotate-180 \ + ! queue ! ffmpegcolorspace \ + ! queue ! vp8enc speed=2 threads=2 quality=5 ! queue ! muxout. \ + jackaudiosrc connect=1 \ + ! queue ! audioconvert ! queue ! vorbisenc quality=3 ! queue ! muxout. \ + webmmux streamable=true name=muxout \ + ! tee name=t ! queue ! tcpserversink host=127.0.0.1 port=9000 \ + t. ! queue ! filesink location=/home/telecaster/trash/test.webm \ + > /dev/null & + diff --git a/conf/home/media/mp3/silence.mp3 b/conf/home/telecaster/media/mp3/silence.mp3 similarity index 100% rename from conf/home/media/mp3/silence.mp3 rename to conf/home/telecaster/media/mp3/silence.mp3 diff --git a/conf/home/media/ogg/silence.ogg b/conf/home/telecaster/media/ogg/silence.ogg similarity index 100% rename from conf/home/media/ogg/silence.ogg rename to conf/home/telecaster/media/ogg/silence.ogg diff --git a/conf/home/bin/rotate_desktop b/conf/usr/local/bin/rotate_desktop similarity index 100% rename from conf/home/bin/rotate_desktop rename to conf/usr/local/bin/rotate_desktop diff --git a/conf/usr/share/applications/rotate_desktop.desktop b/conf/usr/share/applications/rotate_desktop.desktop index 4182a90..aa85a41 100644 --- a/conf/usr/share/applications/rotate_desktop.desktop +++ b/conf/usr/share/applications/rotate_desktop.desktop @@ -1,6 +1,6 @@ [Desktop Entry] Name=Rotate Desktop -Exec=~/bin/rotate_desktop +Exec=/usr/local/bin/rotate_desktop Icon=preferences-desktop-rotate Type=Application Comment=Rotate Desktop for 180 degrees with the touchscreen diff --git a/install.py b/install.py index 41d276b..0f5235a 100644 --- a/install.py +++ b/install.py @@ -111,8 +111,9 @@ class Install(object): for dir in self.home_dirs: home_dir = self.home + '/.' + dir if not os.path.exists(home_dir): - shutil.copytree('conf/home/'+dir, home_dir, ignore=shutil.ignore_patterns('*.svn*')) - self.chown(dir) + os.makedirs(home_dir) + os.system('cp -r conf/home/'+dir + ' ' + home_dir) + self.chown(home_dir) dir = 'media' if not os.path.exists(self.home+os.sep+dir): @@ -145,6 +146,8 @@ class Install(object): if not os.path.islink(init_link): os.system('ln -s /etc/init.d/vncserver '+init_link) + + def run(self): if self.options['keepinit'] == False: print 'Installing init files...' -- 2.39.5