Not logged in
Fri Aug 15 11:52:32 2008
Multi-computer display and recording of digital camera output
Through the magic of gstreamer, I've been able to live play on one machine, compress the image, send it to another machine via udp, and also display it there. The "tee" function also allows one to save at the same images at time as well.
The command line used on the "server", say Rosalba or Mafalda is:
CamServe -F 'Mono8' -c 44058 -E 20000 -X 0 -Y 0 -H 480 -W 752 -l 0 -m 100 | gst-launch-0.10 fdsrc fd=0 blocksize=360960 ! video/x-raw-gray, height=480, width=752, bpp=8,depth=8,framerate=60/1 ! tee name=t1 t1. ! video/x-raw-gray, height=480, width=752, bpp=8,depth=8,framerate=60/1 ! ffmpegcolorspace ! ximagesink t1. ! video/x-raw-gray, height=480, width=752, bpp=8,depth=8,framerate=60/1 ! ffmpegcolorspace ! queue ! smokeenc keyframe=8 qmax=40 ! udpsink host="126.96.36.199" port=5000
This both displays the image and sends it to the host 188.8.131.52 in this case.
I've written a primitive shell script that does most of this.
It requires at the minimum an IP address. You can also give it a number of images (the -m number) and also the exposure value (-E 20000).
Currently in /cvs/cds/caltech/target/Prosilica/40mCode/SnapCode/ there is a script called CameraServerScript.
Typing in "CameraServerScript 184.108.40.206" would send it to that IP address.
Typing in "CameraServerScript 220.127.116.11 500 40000" would run for 500 images at an exposure value of 40000.
To actually receive, you need gstreamer installed and run the following command:
gst-launch udpsrc port=5000 ! smokedec ! queue ! ffmpegcolorspace ! ximagesink sync=false
Make sure you have the right IP address to send to.
Still working on multicasting (basically a server is constantly sending out images, and the client subscribes to the multicast).