Using the DirectShow EVR Filter

[The component described on this page, Enhanced Video Renderer, is a legacy feature. It has been superseded by the Simple Video Renderer (SVR) exposed through the MediaPlayer and IMFMediaEngine components. To play video content you should send data into one of these components and allow them to instantiate the new video renderer. These components have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer or the lower level IMFMediaEngine APIs to play video media in Windows instead of the EVR, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

To create the enhanced video renderer (EVR) filter, call CoCreateInstance. The CLSID is CLSID_EnhancedVideoRenderer, defined in uuids.h. You do not have to call MFStartup or MFShutdown to use the EVR filter.

For more information about using the EVR filter in a DirectShow application, see Audio/Video Playback in DirectShow.

The EVR filter starts with one input pin, which corresponds to the reference stream. To add pins for substreams, query the filter for the IEVRFilterConfig interface and call IEVRFilterConfig::SetNumberOfStreams. Call this method before connecting any input pins. Pin 0 is always the reference stream. Connect this pin before any other pins, because the format of the reference stream might limit which substream formats are available.

Before starting the graph, set the video clipping window and the destination rectangle. For more information, see Using the Video Display Controls.

Unlike the Video Mixing Renderer (VMR), the EVR does not have operational modes (windowed, windowless, and so forth). In particular:

  • The EVR does not support windowed mode. The application must provide the clipping window.
  • The EVR does not have a renderless mode. To replace the default presenter, call IMFVideoRenderer::InitializeRenderer.
  • The EVR does not have a mixing mode. The EVR always creates the mixer. If you have one input stream, it is not necessary to call SetNumberOfStreams to force the EVR to use the mixer.

Filter Interfaces

The EVR filter exposes the following interfaces. Some of these interfaces are documented in the DirectShow SDK. Use QueryInterface to retrieve pointers to these interfaces:

Input Pin Interfaces

The input pins on the EVR filter expose the following interfaces. Use QueryInterface to retrieve pointers to these interfaces:

In addition, you can use the IMFGetService interface to retrieve the following interface:

Audio/Video Playback in DirectShow

Enhanced Video Renderer