tarina

git clone https://git.tarina.org/tarina
Log | Files | Refs | README | LICENSE

commit 58dc814f4511664dcdef44817a81cdcd3b0d7457
parent a6ecb4dc5e47137b7d55b9ba5bf9b032c0ede047
Author: rob <rob@tarina.org>
Date:   Sat, 19 Aug 2023 16:09:41 +0100

stream

Diffstat:
Mtarina.py | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/tarina.py b/tarina.py @@ -3504,10 +3504,11 @@ def startstream(camera, stream, plughw, channels): #stream_cmd = 'ffmpeg -f h264 -r 25 -i - -itsoffset 5.5 -fflags nobuffer -f alsa -ac '+str(channels)+' -i hw:'+str(plughw)+' -ar 44100 -vcodec copy -acodec libmp3lame -b:a 128k -ar 44100 -map 0:0 -map 1:0 -strict experimental -f flv ' + youtube + key[0] # #stream_cmd = 'ffmpeg -f h264 -r 25 -i - -itsoffset 5.5 -fflags nobuffer -f alsa -ac '+str(channels)+' -i hw:'+str(plughw)+' -ar 44100 -vcodec copy -acodec libmp3lame -b:a 128k -ar 44100 -map 0:0 -map 1:0 -strict experimental -f mpegts tcp://0.0.0.0:3333\?listen' - stream_cmd = 'ffmpeg -f h264 -r 25 -i - -itsoffset 5.5 -fflags nobuffer -f alsa -ac '+str(channels)+' -i hw:'+str(plughw)+' -ar '+soundrate+' -acodec mp2 -b:a 128k -ar '+soundrate+' -vcodec copy -map 0:0 -map 1:0 -g 0 -f mpegts udp://192.168.0.100:5000' + #stream_cmd = 'ffmpeg -f h264 -r 25 -i - -itsoffset 5.5 -fflags nobuffer -f alsa -ac '+str(channels)+' -i hw:'+str(plughw)+' -ar '+soundrate+' -acodec mp2 -b:a 128k -ar '+soundrate+' -vcodec copy -map 0:0 -map 1:0 -g 0 -f mpegts udp://10.42.0.169:5002' + stream_cmd = 'ffmpeg -f h264 -r 25 -i - -itsoffset 5.5 -fflags nobuffer -f alsa -ac '+str(channels)+' -i hw:'+str(plughw)+' -ar '+soundrate+' -acodec mp2 -b:a 128k -ar '+soundrate+' -vcodec copy -f mpegts udp://10.42.0.169:5002' try: stream = subprocess.Popen(stream_cmd, shell=True, stdin=subprocess.PIPE) - camera.start_recording(stream.stdin, format='h264', bitrate = 2000000) + camera.start_recording(stream.stdin, format='h264', bitrate = 500000) except: stream = '' #now = time.strftime("%Y-%m-%d-%H:%M:%S")