Microsoft DirectX 9.0

IVideoFrameStep::Step

The Step method causes the filter graph to step forward by the specified number of frames.

Syntax

HRESULT Step(
  DWORD dwFrames,
  IUnknown *pStepObject
);

Parameters

dwFrames

Specifies the number of frames to skip. If dwFrames is 1, the graph steps forward one frame. If dwFrames is a number n greater than 1, the graph skips n - 1 frames and shows the nth frame.

pStepObject

Pointer to an interface on the filter that will control the stepping operation. Specify NULL to perform the frame stepping using the renderer filter in the graph. If the graph includes a custom filter that implements the frame stepping, then pStepObject should specify that filter's IBaseFilter interface.

Return Values

Returns an HRESULT. Possible values include the following.

Value Description
S_OK Success.
VFW_E_FRAME_STEP_UNSUPPORTED Frame stepping is not supported.
E_INVALIDARG The pStepObject parameter is invalid.

Remarks

When the step operation is complete, this method sends an EC_STEP_COMPLETE event notification to the filter graph manager, which will pass it to the application's event loop and set the filter graph to a paused state.

The frames step in real time, which means that if the movie is playing at 30 frames per second, calling IVideoFrameStep::Step with bMultiple set to 60 would take 2 seconds to execute. All methods in this interface are asynchronous, so control returns to the application immediately.

See Also