ICTP Workshop 2007/Image capture with linux

From Bjoern Hassler's website
Jump to: navigation, search

{{#titlehere:}} Please note that the present pages on the ICTP workshop were obtained from a mediawiki used during the workshop. There may be a number of links that go to missing pages, and other inconsistencies. Much of it is also very informal, and should be seen as workshop notes!

Page copied from http://www.huyser.net/openEyAwiki/index.php/Main_Page .

1 different versions of the EyA workflow

2 possibly useful software for openEyA (substitutes for Mac software)

2.1 capture photos

  • gPhoto2 is a free, redistributable, ready to use set of digital camera software applications for Unix-like systems. Installed this from the Ubuntu distribution and it worked as advertised. The Canon A640 was automatically recognised. Here's code to capture multiple pictures:

gphoto2 --capture-image --interval 15 --frames 10 -P --filename=%y%m%d_%H-%M-%S.%C This saves 10 photos with a 15 sec interval. The -P gets photo from camera RAM; for the filename see date(1).

  • Canon Capture. Capture is a tool for periodic image capturing with digital Canon cameras. It is licensed under GPL and it was developed for Linux.

2.2 capture video / audio

video capture

  • FFmpeg is a very fast video and audio converter which unfortunately is broken in Ubuntu 7.10 Gutsy. Here's a solution. Code to record 30 seconds sound:

ffmpeg -f audio_device -i /dev/audio1 -vn -t 00:00:30 out.avi Theoretical code to record 30 seconds of video and sound: ffmpeg -f audio_device -i /dev/audio1 -f m4v -i /dev/video4linux2 -t 00:00:30 out.avi

  • Video For Linux wiki. V4L is built into the v2.1.x linux kernel; V4L2 is built into the v2.5.x linux kernel
  • Motion; everything but the kitchen sink...

audio capture

  • streamer (from the xawtv package) can write audio, but video is failing. Code for 30 seconds audio capture:

streamer -C /dev/dsp1 -t 0:30 -O sound.wav -F stereo

2.3 synchronize video and photos

  • FlowPlayer is a free Flash player which supports timestamps
  • flvtool adds timestamps to a Flashmovie; works with FlowPlayer
  • scripts to produce an XML file used by flvtool
  • SWFObject 2.0, a free flash player
  • Wowzamedia Free Flash server (for upto 10 streams)

3 hardware

3.1 remote controlable digital cameras

  • list
  • Why more than 6 Mpixel cameras could be a waste of money (but it needs to be tested!)
  • Also read Ken Rockwell's article on the megapixel myth

3.2 screengrabbers

  • Epiphan VGA2USB LR sits between "video out" and "camera in" and can grab the producer's screen at 30 fps

3.3 about webcams

  • Ubuntu 7.10 Gutsy has support for UVC built into the kernel; see here
  • The linux UVC people have list of cameras that should work with Ubunti 7.10 Gutsy.
  • V4L wiki page about linux usable webcams
  • QuickCam, a website by Logitech engineers who've developed linux drivers for Logitech cameras
  • Michel Xhaard's website which has linux drivers for hundreds of webcams