blob: 85855a9157300a298ebd2d490690adcd0c494712 [file] [log] [blame]
Guido van Rossum7268c931992-08-18 21:11:18 +00001CMIF video tools
2================
Guido van Rossume4bddea1991-10-30 11:52:48 +00003
Guido van Rossum7268c931992-08-18 21:11:18 +00004This directory contains Python and C programs to manipulate files
5containing digitized video in the "CMIF video format".
6
7
8History
9-------
Guido van Rossumb2e82281992-08-18 16:01:19 +000010
11We started this in October 1991, when we had a large framegrabber
Guido van Rossum7268c931992-08-18 21:11:18 +000012board on loan from SGI for a few weeks: we developed a movie recording
13program (camcorder.py) and added numerous features, including still
14frame capture and synchronous sound recording using a second machine
15(the machine holding the framegrabber board didn't have audio).
Guido van Rossumb2e82281992-08-18 16:01:19 +000016
Guido van Rossum7268c931992-08-18 21:11:18 +000017During the following months, when we started using and processing the
18recorded film fragments, the "CMIF video format" was revised several
19times, and we eventually created an object-oriented interface for
20reading and writing various incarnations of these files, called VFile.
21(This module is also used by our flagship application, the CMIF
22editor, not in this directory but in /ufs/guido/mm/.)
Guido van Rossumb2e82281992-08-18 16:01:19 +000023
Guido van Rossum7268c931992-08-18 21:11:18 +000024When we got our own Indigo entry-level video board (in June 1992) and
25a version of the Irix video library that supported capturing PAL
26format (in August 1992), Sjoerd added an interface to the video
Guido van Rossum815adc91992-08-20 11:54:00 +000027library to Python (sv) and Guido wrote Vrec.py (based upon a
Guido van Rossum7268c931992-08-18 21:11:18 +000028still frame grabber by Sjoerd, in turn based upon SGI demo code in C)
29to record a movie using it.
Guido van Rossumb2e82281992-08-18 16:01:19 +000030
Guido van Rossum7268c931992-08-18 21:11:18 +000031 Guido van Rossum
32 Jack Jansen
33 Sjoerd Mullender
Guido van Rossume4bddea1991-10-30 11:52:48 +000034
Guido van Rossum96059b31991-11-04 14:31:31 +000035
Guido van Rossum7268c931992-08-18 21:11:18 +000036Overview of files
37-----------------
38
Guido van Rossume4bddea1991-10-30 11:52:48 +000039cam.py network real-time tv broadcast; see tv.py
40 usage: cam [packfactor [host]]
41 specifying 'all' for host broadcasts
42
43camcorder.py record video movies or make snapshots (in movie format)
Guido van Rossum96059b31991-11-04 14:31:31 +000044 usage: camcorder [-c] [-a audiohost [-s]] [-p pf] [moviefile]
45 -c color (equivalent to -p 0)
Guido van Rossume4bddea1991-10-30 11:52:48 +000046 -a audiohost syncaudio is running on audiohost
47 -s start syncaudio (on audiohost)
Guido van Rossum96059b31991-11-04 14:31:31 +000048 -p packfactor packfactor (default 2; 0 records color)
Guido van Rossume4bddea1991-10-30 11:52:48 +000049 moviefile (default film.video)
50 keyboard commands:
51 s stop grabbing (single step if already stopped)
52 c continuous grabbing
53 r start recording
54 p pause recording (record single frame if paused)
55 ESC quit
56
Guido van Rossum815adc91992-08-20 11:54:00 +000057Vrec.py record video movies using the Indigo video library and
Guido van Rossumb2e82281992-08-18 16:01:19 +000058 board
59
Guido van Rossum815adc91992-08-20 11:54:00 +000060colorsys.py color conversions, used by video
61
Guido van Rossume4bddea1991-10-30 11:52:48 +000062statit.py various statistics operations on movie files
63
64syncaudio.py record audio synchronized with camcorder -a
65 usage: syncaudio videohost soundfile
Guido van Rossum96059b31991-11-04 14:31:31 +000066 soundfile format: 16 bits/sample, 16000 samples/sec, 1 channel
67 (actually, you'd better set the sampling rate to 16000
68 with the audio panel)
Guido van Rossume4bddea1991-10-30 11:52:48 +000069
70tv.py receiver for transmissions from cam.py
71
Guido van Rossum7caf6111991-11-04 15:55:01 +000072vcopy.py selectively write frames from one movie file to another
73 usage: vcopy infile outfile
74 commands: 'n' gets next frame; 'w' writes current frame
75
Guido van Rossume4bddea1991-10-30 11:52:48 +000076video.py player for movies recorded by camcorder.py
Guido van Rossum7385d581991-11-22 14:03:57 +000077 usage: video [-l] [-p pf] [-m mag] [-F]
78 [moviefile [soundfile [skipbytes]]]
Guido van Rossum228381e1991-11-04 18:04:47 +000079 -p pf override packfactor (to zoom)
80 -l looping -- restart movie when done
Guido van Rossum7385d581991-11-22 14:03:57 +000081 -m mag magnification
82 -F run at max speed
Guido van Rossum228381e1991-11-04 18:04:47 +000083 moviefile default is film.video
84 soundfile default is none (no sound)
85 skipbytes byte offset in soundfile where sound starts
Guido van Rossume4bddea1991-10-30 11:52:48 +000086
Guido van Rossum7268c931992-08-18 21:11:18 +000087Vplay.py similar but more modern, using VFile.py
Guido van Rossumb2e82281992-08-18 16:01:19 +000088
Guido van Rossumeda5dfd1991-11-06 16:13:25 +000089vinfo.py print summary of movie file(s)
90 usage: vinfo [-d] moviefile ...
91 -d print delta times (default: print abs times)
Guido van Rossume4bddea1991-10-30 11:52:48 +000092
Guido van Rossum7268c931992-08-18 21:11:18 +000093Vinfo.py similar but more modern, using VFile.py
Guido van Rossumb2e82281992-08-18 16:01:19 +000094
Guido van Rossum96059b31991-11-04 14:31:31 +000095vpregs.py definition of VP registers
96
Guido van Rossume4bddea1991-10-30 11:52:48 +000097vtime.py virtual time module imported by syncaudio.py and camcorder.py
98
Guido van Rossum815adc91992-08-20 11:54:00 +000099Vtime.py (unrelated to vtime!!!) Copy a video file,
100 manipulating the time codes (e.g. faster/slower, or
101 regenerate time codes, or drop frames too close apart)
102
Guido van Rossum9ee7e151992-08-25 12:29:30 +0000103Vedit.py interactive video editing program
104
105Viewer.py two viewer classes used by Vedit
106
Guido van Rossume4bddea1991-10-30 11:52:48 +0000107
Guido van Rossum7268c931992-08-18 21:11:18 +0000108The following are C programs, either for efficiency or because they
109need to link with a C library:
Guido van Rossume4bddea1991-10-30 11:52:48 +0000110
111squash.c make a movie smaller by averaging pixels
112 usage: squash factor [bits] <moviefile >newmoviefile
113 factor x and y compression factor
114 bits #bits left per sample in result (default 8)
115
116squash2.c make a movie smaller by dropping pixels
117 usage: squash2 factor <moviefile >newmoviefile
118 factor x and y compression factor
119
120tomono.c like squash2 but outputs a monochrome movie
121
Guido van Rossum7caf6111991-11-04 15:55:01 +0000122v2i.c convert the first frame of a movie file to SGI .rgb format
Guido van Rossume4bddea1991-10-30 11:52:48 +0000123 link with -limage
Guido van Rossum7268c931992-08-18 21:11:18 +0000124
125i2v.c convert an rgb file to "lrectwrite" format (this was
126 used one time by the CMIF editor)