diff --git a/zen/stream/process-stream.sh b/zen/stream/process-stream.sh index ab0687e..e71c60c 100755 --- a/zen/stream/process-stream.sh +++ b/zen/stream/process-stream.sh @@ -18,7 +18,8 @@ function startFFmpeg() { echo 1 > /tmp/stream-reset # Stream WebCamera - ffmpeg -f pulse -i 1 -f video4linux2 -video_size 1280x720 -framerate 25 -i /dev/video0 -hls_time "${HLS_TIME}" "${what}.m3u8" > /tmp/ffmpeg.log 2>&1 + #ffmpeg -f pulse -i 1 -f video4linux2 -video_size 1280x720 -framerate 25 -i /dev/video0 -hls_time "${HLS_TIME}" "${what}.m3u8" > /tmp/ffmpeg.log 2>&1 + ffmpeg -f pulse -i 1 -f video4linux2 -video_size 720x480 -framerate 25 -i /dev/video0 -hls_time "${HLS_TIME}" "${what}.m3u8" > /tmp/ffmpeg.log 2>&1 ## MORE SOURCES # http://4youngpadawans.com/stream-camera-video-and-audio-with-ffmpeg/ @@ -43,6 +44,7 @@ sudo mount -t tmpfs tmpfs "${currentpath}" cd "${currentpath}" what="$(date +%Y%m%d%H%M)-LIVE" +echo "STARTING $what" # Start ffmpeg in background startFFmpeg & @@ -122,8 +124,9 @@ while true; do ipfs name publish --key='star_1' --timeout=5s "${m3u8hash}" & # Copy files to web server - cp current.m3u8 /var/www/html/live.m3u8 - cp /tmp/process-stream.log /var/www/html/live.log + cat current.m3u8 + # cp current.m3u8 /var/www/html/live.m3u8 + # cp /tmp/process-stream.log /var/www/html/live.log fi else sleep 5