1 /* Qtinfo by Elliot Lee <sopwith@redhat.com> */
5 static void file_info(char *filename);
7 int main(int argc, char *argv[])
12 printf("Usage: %s filename...\n", argv[0]);
16 for(i = 1; i < argc; i++) {
24 file_info(char *filename)
29 qtfile = quicktime_open(filename, 1, 0);
32 printf("Couldn't open %s as a QuickTime file.\n", filename);
36 printf("\nFile %s:\n", filename);
37 n = quicktime_audio_tracks(qtfile);
38 printf(" %d audio tracks.\n", n);
39 for(i = 0; i < n; i++) {
41 printf(" %d channels. %d bits. sample rate %ld. length %ld. compressor %s.\n",
42 quicktime_track_channels(qtfile, i),
43 quicktime_audio_bits(qtfile, i),
44 quicktime_sample_rate(qtfile, i),
45 quicktime_audio_length(qtfile, i),
46 quicktime_audio_compressor(qtfile, i));
47 printf(" %ssupported.\n",
48 quicktime_supported_audio(qtfile, i)?"":"NOT ");
51 n = quicktime_video_tracks(qtfile);
52 printf(" %d video tracks.\n", n);
53 for(i = 0; i < n; i++) {
54 printf(" %dx%d rate %f length %ld compressor %s.\n",
55 quicktime_video_width(qtfile, i),
56 quicktime_video_height(qtfile, i),
57 quicktime_frame_rate(qtfile, i),
58 quicktime_video_length(qtfile, i),
59 quicktime_video_compressor(qtfile, i));
60 printf(" %ssupported.\n",
61 quicktime_supported_video(qtfile, i)?"":"NOT ");