1.1 --- a/gmyth-stream/server/tests/client.py Wed Apr 04 16:47:00 2007 +0100
1.2 +++ b/gmyth-stream/server/tests/client.py Thu Apr 12 23:17:33 2007 +0100
1.3 @@ -6,10 +6,10 @@
1.4
1.5 if len(sys.argv) < 2:
1.6 HOST = 'localhost'
1.7 - PORT = 5000
1.8 + PORT = 50000
1.9 elif len(sys.argv) == 2:
1.10 HOST = sys.argv[1]
1.11 - PORT = 5000
1.12 + PORT = 50000
1.13 else:
1.14 HOST = sys.argv[1]
1.15 PORT = int(sys.argv[2])
1.16 @@ -25,25 +25,25 @@
1.17
1.18
1.19 mplayer = os.popen("which mplayer").read().strip()
1.20 -mplayer += " - 1> /dev/null"
1.21 +mplayer += " -idx - -vo x11 1> /dev/null"
1.22 pin, pout = os.popen2(mplayer)
1.23
1.24 -#teste = open("/tmp/teste2", "w")
1.25 +#teste = open("teste.avi", "w")
1.26
1.27 -data = socket.recv(1024)
1.28 +data = socket.recv(4096)
1.29 i = 0
1.30
1.31 while (data != ""):
1.32 pin.write(data)
1.33 #teste.write(data)
1.34 - data = socket.recv(1024)
1.35 - if (i == 500):
1.36 - socket.send("OK")
1.37 + data = socket.recv(4096)
1.38 + #if (i == 500):
1.39 + # socket.send("OK")
1.40 i += 1
1.41
1.42 pin.close()
1.43 socket.close()
1.44 -
1.45 +#teste.close()
1.46
1.47 # from select import select
1.48 # r, w, x = select([pout], []. [], 0)