Поделиться через


IOverlayNotify Interface (Windows Embedded CE 6.0)

1/6/2010

This interface provides an upstream filter, such as a decoder, with notifications of changes to the rendering window. This includes notifications of changes to the palette, color key, and window position, and visible region (clipping) changes.

Most software video decoders let the video renderer draw the decompressed images they produce by passing the media samples to the IMemInputPin interface on the renderer's input pin.

However, some video decoding filters (typically hardware decompression boards) handle the drawing of the images themselves, perhaps by using a VGA connector.

These filters do not need to use IMemInputPin, but can instead use the IOverlay interface provided by the renderer input pin. Through this interface, the decoder can be notified when the window position or size changes, or when the current system palette changes in order to install and change color keys and palettes.

When to Implement

To get notifications of when the window size or position changes, when the current system palette changes, or when a different color key is used, decoders that do their own drawing should implement an IOverlayNotify interface.

A pointer to this interface can then be passed to the IOverlay interface on the renderer's input pin, through the IOverlay::Advise method, to set up an advise link (essentially a callback mechanism).

After the advise link is established, the renderer calls the decoder's IOverlayNotify methods when the appropriate events occur.

An advise link can be canceled by calling IOverlay::Unadvise.

When to Use

The video renderer is the only filter that calls the methods on this interface. This is done by the default video renderer. If you are writing a replacement video renderer, you must use the methods on this interface if your filter supports IOverlay and this interface is passed to your filter in an IOverlay::Advise call.

Methods in Vtable Order

The following table shows the methods that appear in the Vtable beneath the standard COM methods inherited from IUnknown.

Method Description

OnPaletteChange

Provides notification that the palette of the window has changed.

OnClipChange

Provides notification that the visible region of the window has changed.

OnColorKeyChange

Provides notification that the chroma key has changed.

OnPositionChange

Provides notification that the position has changed.

Requirements

Windows Embedded CE Windows CE 2.12 and later
Note Microsoft DirectShow applications and DirectShow filters have different include file and Library requirements
For more information, see Setting Up the Build Environment

See Also

Reference

DirectShow Interfaces