[lug] individual frames from AVI file?

Tkil tkil at scrye.com
Tue Jun 8 02:20:55 MDT 2004

Stupid question time.

I recently got a Canon PowerShot S400 "Digital Elph" camera.  It has
two movie modes, either 320x240 or 640x480, both at 15 frames per
second.  I believe the output format is MJPEG, in an AVI container:

| $ tcprobe -i 0066.avi 
| [tcprobe] RIFF data, AVI video
| [avilib] V: 15.000 fps, codec=MJPG, frames=2700, width=320, height=240
| [avilib] A: 11024 Hz, format=0x01, bits=8, channels=1, bitrate=88 kbps,
| [avilib]    180 chunks, 1984320 bytes, CBR
| [tcprobe] summary for 0066.avi, (*) = not default, 0 = not detected
| import frame size: -g 320x240 [720x576] (*)
|        frame rate: -f 15.000 [25.000] frc=0 (*)
|       audio track: -a 0 [0] -e 11024,8,1 [48000,16,2] -n 0x1 [0x2000] (*)
|                    bitrate=88 kbps
|            length: 2700 frames, frame_time=66 msec, duration=0:02:59.998

What tools can I use to decompose these streams into individual
frames?  I have found various references to using the avi* and tc*
programs, but the closest I've gotten is having it biff at the
non-standard frame rate.

My eventual goal is to extract about 2 seconds of video at about the
2:50 mark as individual frames (either JPEG or PNG or any raster
format, really); do some smoothing, posterization, quantization, then
rebuilding them into a small animated GIF.


More information about the LUG mailing list