# HG changeset patch # User morphbr # Date 1175292772 -3600 # Node ID b94790c04fd5556048d8861050831dcdac12c8a3 # Parent e5618b012121504fd9bc0bdcb5c90ed040ebc1a7 [svn r478] * GMyth-Stream: - Fixed bug regarding buffer length diff -r e5618b012121 -r b94790c04fd5 gmyth-stream/plugins/media/ffmpeg.py --- a/gmyth-stream/plugins/media/ffmpeg.py Fri Mar 30 23:09:39 2007 +0100 +++ b/gmyth-stream/plugins/media/ffmpeg.py Fri Mar 30 23:12:52 2007 +0100 @@ -30,7 +30,7 @@ # good one: /tmp/mpg/cpm.mpg mpeg mpeg1video 400 25 mp2 192 320 240 5000 self.path = self.config.get("FFmpeg", "path") - self.path += " -i %s -bufsize 4096 -f %s -vcodec %s -b %d -r %d -acodec %s -ab %d -s %dx%d -" % ( + self.path += " -i %s -f %s -vcodec %s -b %d -r %d -acodec %s -ab %d -s %dx%d -" % ( self.filename, self.mux, self.vcodec, self.vbitrate,\ self.fps, self.acodec, self.abitrate, self.width, self.height) @@ -57,7 +57,7 @@ conn,addr= self.socket.accept() lib.log("Sending Data to client: %s" % addr[0]) - data = child_stdout.read(4096) + data = child_stdout.read(1024) conn.settimeout(5) retry = 0 diff -r e5618b012121 -r b94790c04fd5 gmyth-stream/plugins/media/mencoder.py --- a/gmyth-stream/plugins/media/mencoder.py Fri Mar 30 23:09:39 2007 +0100 +++ b/gmyth-stream/plugins/media/mencoder.py Fri Mar 30 23:12:52 2007 +0100 @@ -49,7 +49,6 @@ self.socket = socket.socket(socket.AF_INET,socket.SOCK_STREAM) self.socket.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) self.socket.bind( ('', self.port) ) - self.socket.settimeout(10) self.socket.listen(1) def play(self): @@ -66,7 +65,7 @@ conn,addr= self.socket.accept() lib.log("Sending Data to client: %s" % addr[0]) - data = fifo.read(4096) + data = fifo.read(1024) conn.settimeout(5) retry = 0 @@ -77,7 +76,7 @@ lib.log("Socket error (maybe timeout ?)") retry += 1 - data = fifo.read(4096) + data = fifo.read(1024) if (retry < 5): lib.log("Finished sending Data to client: %s" % addr[0])