Share via


IMediaFilter Interface

Multimedia components that provide time-based data expose the IMediaFilter interface. This interface abstracts an object that processes time-based data streams and represents a multimedia device (possibly implemented in software). It controls the active or running state of the object and the synchronization of this state with other objects in the system.

This interface inherits the IPersist interface.

When to Implement

Methods on this interface should be implemented as part of any filter. This is typically done by using the base class CBaseFilter, which implements IBaseFilter and IMediaFilter.

When to Use

Because the IMediaFilter interface is inherited by the IBaseFilter interface, which adds other necessary methods required to be exported by filters, this interface is not normally used directly by the filter graph manager or other filters. It can, however, be of use to plug-in distributors. For example, the filter graph manager internally exports IMediaFilter; its plug-in distributor exports IMediaControl and calls the IMediaFilter methods to implement its own methods.

Methods in Vtable Order

IUnknown methods Description
QueryInterface Returns pointers to supported interfaces.
AddRef Increments the reference count.
Release Decrements the reference count.
IMediaFilter methods Description
Stop Informs the filter to transition to the new (stopped) state.
Pause Informs the filter to transition to the new (paused) state.
Run Informs the filter to transition to the new (running) state.
GetState Determines the state of the filter.
SetSyncSource Identifies the reference clock to which the filter should synchronize activity.
GetSyncSource Retrieves the current reference clock (or NULL if there is no clock). Passes a time value to synchronize independent streams.

 Last updated on Tuesday, July 13, 2004

© 1992-2000 Microsoft Corporation. All rights reserved.