EC_REPAINT

[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.]

A video renderer requires a repaint.

Parameters

lParam1

(IUnknown*) Pointer to the IPin interface of the video renderer's input pin, or NULL.

lParam2

Zero.

Default Action

The lParam1 parameter might specify the video renderer's input pin. If so, the filter graph manager finds the output pin connected to that pin and queries it for the IMediaEventSink interface. If the output pin supports IMediaEventSink, the filter graph manager calls IMediaEventSink::Notify with the EC_REPAINT event code. This gives the upstream filter the opportunity to re-send the last sample.

If lParam1 is NULL, or if the pin does not support IMediaEventSink, or if the Notify method fails, the filter graph manager handles the EC_REPAINT event by itself. Its behavior depends on the state of the graph:

  • Running: Ignores the event. (The renderer will receive the next sample in the stream.)
  • Paused: Seeks the graph to its current location, thereby flushing the filter and re-queuing the data.
  • Stopped: Pauses and stops the graph, thereby re-queuing the data.

By default, the filter graph manager does not pass this event to the application.

Remarks

Video renderers send this message when they receive a WM_PAINT message and have no data to display.

Requirements

Requirement Value
Header
Dshow.h

See also

Event Notification Codes

Event Notification in DirectShow