Article ID: 139826 - View products that this article applies to.
This article was previously published under Q139826
This article has been archived. It is offered "as is" and will no longer be updated.
This article provides tips you can use to help you compress AVI (audio- video interleaved) files. This article should help to clarify the information in the documentation. This article also provides hints concerning the settings for Interleave, Compression Quality, Key Frame Every, and Data Rate - all settings available in the Video Compression Options dialog box.
Video Dimensions and Frame RateWhen authoring, consider that most display cards support up to 320x240x15 frames per second (fps). Larger images or faster frame rates increase the importance of testing on multiple machines with multiple configurations (CD- ROM drive speeds, video boards, display monitors, and so on).
Full Screen PlaybackIf your movie is 320x240 or less, you should get excellent full-screen playback that can handle 15 fps regardless of the video card. If your movie is bigger, it will play full screen, but performance may be poor. Test across multiple configurations to help identify the impact of stretching on various displays.
Video Compression OptionsThe following options are presented in the Compression Options dialog box. To gain access to this dialog box, on the File menu, click Save Options in SDK samples such as Aviedit and Aviview. Similar options are available in the Videdit utility from Video for Windows by clicking Save As on the File menu.
The interleave option places audio data physically between video frame data in the AVI file to ensure the best performance and synchronization. For example, with a 1:1 interleave setting, each frame of a 15 fps video would have 1/15 seconds of audio data. This setting does not matter when editing the file. When saving for playback, interleave every frame for best playback performance. Interleaving multiple audio streams is not possible using this option.
Use the highest quality number to get the best quality, but use the entire allowable data rate. A lower quality may take up less than the requested data rate.
Key Frame Every:
Normally, use the default key frame value for a particular codec. Fewer key frames could give a little better picture quality, but if your system can't keep up on playback, you'll stall for a longer time, and you won't degrade as gracefully. More key frames means fewer frames skipped when playback can't keep up.
The minimum data rate that can be achieved on most computers is 100K/sec for single spin CD-ROM drives, and 225K/sec for double spin CD-ROM drives. Most computers can do more (150K and 300K for single and double speed respectively).
The AVIMakeCompressedStream(), AVISave(), and AVISaveOptions() functions use the AVICOMPRESSOPTIONS structure to specify some of the compression options discussed in this article. The ICCompressorChoose() function uses the COMPVARS structure for a similar purpose. See the documentation for the products listed at the beginning of this article for more information.
Contact us for more help
Connect with Answer Desk for expert help.