Indexes
[The feature associated with this page, Windows Media Format 11 SDK, is a legacy feature. It has been superseded by Source Reader and Sink Writer. Source Reader and Sink Writer have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use Source Reader and Sink Writer instead of Windows Media Format 11 SDK, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]
A common requirement for applications that read digital media files is the ability to seek to a specific point in the content. Seeking can be difficult because there is no guarantee that the various streams in a file have samples with concurrent start times. This problem is addressed with the use of indexes. An index is an object in an ASF file that equates video samples with their presentation times. No index is required for audio streams because audio data is more closely connected with presentation time than video data is.
The indexer object of the Windows Media Format SDK can create three different types of indexes: temporal indexes, frame-based indexes, and SMPTE time code indexes.
Temporal indexes are the most common type. They simply equate video samples with the corresponding presentation times.
A frame-based index equates video samples with video frame numbers and presentation times. Frame numbers are particularly useful in applications that edit video.
A SMTPE time code index is the rarest type of index. It uses SMPTE time code as the basis of the index and can be used only on streams that have SMPTE time stamps included with their samples. For more information about SMPTE time code, see SMPTE Time Code Support.
An ASF file can contain an index of each type for each video stream it contains. As a default, a temporal index is included for each video stream in files created by the writer object. You can change the automatic indexing settings for your files to suit your needs.
Related topics