Note [Deprecated. This API may be removed from future releases of Windows.]
IMediaDet interface retrieves information about a media file, such as the number of streams, and the media type, duration, and frame rate of each stream. It also contains methods for retrieving individual frames from a video stream. The Media Detector (MediaDet) object exposes this interface.
To obtain information about a file using this interface, perform the following steps:
- Create an instance of the MediaDet object by calling CoCreateInstance. The class ID is CLSID_MediaDet.
- Call IMediaDet::put_Filename to specify the name of the source file.
- Call IMediaDet::get_OutputStreams to obtain the number of output streams in the source.
- Call IMediaDet::put_CurrentStream to specify a particular stream.
- Call any of the following methods:
Note Do not use the same MediaDet object with multiple files. To get information or video frames from more than one file, use separate MediaDet instances.
The IMediaDet interface does not support VIDEOINFOHEADER2 formats, so you cannot use this interface to get interlaced fields or information about interlacing. Also, if the upstream decoder supports only VIDEOINFOHEADER2, you cannot use
IMediaDet. This might be the case with an MPEG-2 decoder, for example. Also, the
IMediaDet interface ignores any streams in the file that are not video or audio. For example, if the file contains an audio stream, a data stream, and a video stream, the get_OutputStreams method will report only two streams (the audio and video).
The IMediaDet interface inherits from the IUnknown interface. IMediaDet also has these types of members:
The IMediaDet interface has these methods.
Switches the media detector to bitmap grab mode and seeks the filter graph to a specified time.
Retrieves the stream number currently used by the media detector.
Retrieves the name of the source file currently used by the media detector.
Retrieves a pointer to the source filter currently used by the media detector.
Retrieves the frame rate of the current stream.
Retrieves the number of audio and video streams contained in the media source.
Retrieves the duration of the current stream.
Retrieves the media type of the current stream.
Retrieves the globally unique identifier (GUID) for the media type of the current stream.
Retrieves a string representing the GUID of the media type for the current stream.
Retrieves a video frame at the specified media time.
Retrieves a pointer to the ISampleGrabber interface.
Specifies the stream number for the media detector to use.
Specifies the name of the source file for the media detector to use.
Specifies a source filter for the media detector to use.
Retrieves a video frame at the specified media time and writes it to a file.
Note The header file Qedit.h is not compatible with Direct3D headers later than version 7.
Note To obtain Qedit.h, download the Microsoft Windows SDK Update for Windows Vista and .NET Framework 3.0. Qedit.h is not available in the Microsoft Windows SDK for Windows 7 and .NET Framework 3.5 Service Pack 1.