Share via


IMediaObject interface (mediaobj.h)

[The feature associated with this page, DirectShow, is a legacy feature. It has been superseded by MediaPlayer, IMFMediaEngine, and Audio/Video Capture in Media Foundation. Those features have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer, IMFMediaEngine and Audio/Video Capture in Media Foundation instead of DirectShow, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

The IMediaObject interface provides methods for manipulating a Microsoft DirectX Media Object (DMO).

Inheritance

The IMediaObject interface inherits from the IUnknown interface. IMediaObject also has these types of members:

Methods

The IMediaObject interface has these methods.

 
IMediaObject::AllocateStreamingResources

The AllocateStreamingResources method allocates any resources needed by the DMO. Calling this method is always optional.
IMediaObject::Discontinuity

The Discontinuity method signals a discontinuity on the specified input stream.
IMediaObject::Flush

The Flush method flushes all internally buffered data.
IMediaObject::FreeStreamingResources

The FreeStreamingResources method frees resources allocated by the DMO. Calling this method is always optional.
IMediaObject::GetInputCurrentType

The GetInputCurrentType method retrieves the media type that was set for an input stream, if any.
IMediaObject::GetInputMaxLatency

The GetInputMaxLatency method retrieves the maximum latency on a specified input stream.
IMediaObject::GetInputSizeInfo

The GetInputSizeInfo method retrieves the buffer requirements for a specified input stream.
IMediaObject::GetInputStatus

The GetInputStatus method queries whether an input stream can accept more input data.
IMediaObject::GetInputStreamInfo

The GetInputStreamInfo method retrieves information about an input stream, such as any restrictions on the number of samples per buffer, and whether the stream performs lookahead on the input data. This information never changes.
IMediaObject::GetInputType

The GetInputType method retrieves a preferred media type for a specified input stream.
IMediaObject::GetOutputCurrentType

The GetOutputCurrentType method retrieves the media type that was set for an output stream, if any.
IMediaObject::GetOutputSizeInfo

The GetOutputSizeInfo method retrieves the buffer requirements for a specified output stream.
IMediaObject::GetOutputStreamInfo

The GetOutputStreamInfo method retrieves information about an output stream; for example, whether the stream is discardable, and whether it uses a fixed sample size. This information never changes.
IMediaObject::GetOutputType

The GetOutputType method retrieves a preferred media type for a specified output stream.
IMediaObject::GetStreamCount

The GetStreamCount method retrieves the number of input and output streams.
IMediaObject::Lock

The Lock method acquires or releases a lock on the DMO. Call this method to keep the DMO serialized when performing multiple operations.
IMediaObject::ProcessInput

The ProcessInput method delivers a buffer to the specified input stream.
IMediaObject::ProcessOutput

The ProcessOutput method generates output from the current input data.
IMediaObject::SetInputMaxLatency

The SetInputMaxLatency method sets the maximum latency on a specified input stream. For the definition of maximum latency, see IMediaObject::GetInputMaxLatency.
IMediaObject::SetInputType

The SetInputType method sets the media type on an input stream, or tests whether a media type is acceptable.
IMediaObject::SetOutputType

The SetOutputType method sets the media type on an output stream, or tests whether a media type is acceptable.

Requirements

Requirement Value
Target Platform Windows
Header mediaobj.h (include Dmo.h)