Microsoft DirectX 8.1 (C++)

VMR Filter Components

This topic applies to Windows XP Home Edition and Windows XP Professional only.

The VMR employs a modular design that enables applications to configure it for many different rendering scenarios. Depending on its configuration, the VMR contains from two to five subcomponents (in addition to its input pins).

VMR in Windowed Mode with Multiple Streams

Mixer: The mixer is a COM object that is loaded by the VMR when multiple input streams are detected. The mixer collects information about each input stream and sorts the streams into the correct Z-order. It is responsible for determining when each input pin receives a sample and for instructing the image compositor at the proper time to perform the actual blending. The mixer also calculates the time stamp to be applied to each output image. When the application is supplying a bitmap to be displayed on top of the composited image, the mixer is responsible for ensuring that the bitmap is displayed on top even if the Z-order of the input streams is modified.

Image Compositor: The Image Compositor is a COM object that performs the actual blending of the input streams onto a single DirectDraw surface provided by the Allocator-Presenter. The VMR provides a default image compositor that enables applications to perform 2-D alpha-blending effects. Applications can provide a custom image compositor to enable other 2-D and 3-D effects such as applying textures to portions of the image, per-pixel alpha blending, mapping the image to stationary or moving 3-D objects, and so on.

Allocator-Presenter: The Allocator-Presenter is a COM object that allocates the DirectDraw object and handles the communication with the graphics card. The drawing can be performed either as a flip or as a blit. Applications can plug in their own Allocator-Presenter if they wish to create and control the DirectDraw object, and/or to obtain access to the video bits at presentation time.

Core Syncronization Unit: The Core Synchronization Unit is a COM object that ensures that each frame is presented at the correct time. It uses the IReferenceClock interface provided by the Filter Graph Manager and performs quality management and frame reporting functions.

Window Manager: The Window Manager is used only when the VMR is operating in windowed mode. The Window Manager is implemented as a static library, and it supports the old DirectShow IVideoWindow and IBasicVideo interfaces for backward compatibility.