Share via


IAsyncReader::Request (Windows Embedded CE 6.0)

1/6/2010

This method queues a request for data.

Syntax

HRESULT Request(
  IMediaSample* pSample,
  DWORD dwUser 
);

Parameters

  • pSample
    Media sample being requested.
  • dwUser
    [in] User context.

Return Value

Returns an HRESULT value that depends on the implementation of the interface. Current DirectShow implementation return values include the following.

Value Description

VFW_E_BADALIGN

An invalid alignment was specified.

VFW_E_MEDIA_TIME_NOT_SET

Time has not been set.

HRESULT_FROM_WIN32

Request for data past end of file.

NOERROR

No error.

S_OK

Success.

Remarks

Media sample start and stop times contain the requested absolute byte position (start-inclusive and stop-exclusive). This method might fail if the sample is not obtained from an agreed allocator or if the start or stop position does not match the agreed alignment. The samples allocated from the source pin's allocator might fail IMediaSample::GetPointer until after returning from IAsyncReader::WaitForNext.

The stop position must be aligned, which means it might exceed duration. On completion, the stop position will be corrected to the unaligned actual data.

The dwUser parameter is used by the caller to identify the sample that returned from the IAsyncReader::WaitForNext method. It has no meaning within IAsyncReader but could be used to track individual sample information.

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, Version 2.12 requires DXPAK 1.0 or later

See Also

Reference

IAsyncReader Interface