IWMSyncReader interface (wmsdkidl.h)
[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.]
The IWMSyncReader interface provides the ability to read ASF files using synchronous calls. This is in contrast to many of the methods in IWMReader, which are called asynchronously.
You get a pointer to an IWMSyncReader interface when you create a new synchronous reader object with a call to WMCreateSyncReader.
In addition to enabling synchronous reading, the methods of IWMSyncReader are tailored to meet the demands of editing applications. Default playback from IWMSyncReader delivers uncompressed samples for the default streams of all outputs. However, you can manipulate the selected streams during streaming without having to enable manual stream selection. You can also receive compressed or uncompressed samples, though you cannot change between them during streaming. Samples are delivered by either output number or stream number, so you can receive uncompressed samples from mutually exclusive streams.
Many of the methods in this interface are almost identical to corresponding methods in the asynchronous reader.
Use of this interface, as well as the implementation of an IStream COM object that passes data to this object, is demonstrated in the WMSyncReader SDK sample.
Inheritance
The IWMSyncReader interface inherits from the IUnknown interface. IWMSyncReader also has these types of members:
Methods
The IWMSyncReader interface has these methods.
IWMSyncReader::Close The Close method removes a file from the synchronous reader. |
IWMSyncReader::GetMaxOutputSampleSize The GetMaxOutputSampleSize method retrieves the maximum sample size for a specified output of the file open in the synchronous reader. |
IWMSyncReader::GetMaxStreamSampleSize The GetMaxStreamSampleSize method retrieves the maximum sample size for a specified stream in the file that is open in the synchronous reader. |
IWMSyncReader::GetNextSample The GetNextSample method retrieves the next sample from the file. |
IWMSyncReader::GetOutputCount The GetOutputCount method retrieves the number of outputs that exist for the file open in the synchronous reader. |
IWMSyncReader::GetOutputFormat The GetOutputFormat method retrieves the supported formats for a specified output media stream. |
IWMSyncReader::GetOutputFormatCount The GetOutputFormatCount method is used to determine all possible format types supported by this output on the synchronous reader. |
IWMSyncReader::GetOutputNumberForStream The GetOutputNumberForStream method retrieves the output number that corresponds with the specified stream. |
IWMSyncReader::GetOutputProps The GetOutputProps method retrieves the current properties of an uncompressed output stream. |
IWMSyncReader::GetOutputSetting The GetOutputSetting method retrieves a setting for a particular output by name. |
IWMSyncReader::GetReadStreamSamples The GetReadStreamSamples method ascertains whether a stream is configured to deliver compressed samples. |
IWMSyncReader::GetStreamNumberForOutput The GetStreamNumberForOutput method retrieves the stream number that corresponds with the specified output. |
IWMSyncReader::GetStreamSelected The GetStreamSelected method retrieves a flag indicating whether a particular stream is currently selected. |
IWMSyncReader::Open The Open method opens a file for reading. Unlike IWMReader::Open, this method is a synchronous call. |
IWMSyncReader::OpenStream The OpenStream method opens a stream for reading. |
IWMSyncReader::SetOutputProps The SetOutputProps method specifies the media properties of an uncompressed output stream. |
IWMSyncReader::SetOutputSetting The SetOutputSetting method specifies a named setting for a particular output. |
IWMSyncReader::SetRange The SetRange method enables you to specify a start time and duration for playback by the synchronous reader. |
IWMSyncReader::SetRangeByFrame The SetRangeByFrame method configures the synchronous reader to read a portion of the file specified by a starting video frame number and a number of frames to read. |
IWMSyncReader::SetReadStreamSamples The SetReadStreamSamples method specifies whether samples from a stream will be delivered compressed or uncompressed. |
IWMSyncReader::SetStreamsSelected The SetStreamsSelected method configures the samples to be delivered from a list of streams. Each stream can be set to deliver all samples, no samples, or only cleanpoint samples. |
Requirements
Requirement | Value |
---|---|
Target Platform | Windows |
Header | wmsdkidl.h |