Partager via


IBasicVideo::GetCurrentImage (Windows CE 5.0)

Send Feedback

This method retrieves the current image waiting at the renderer.

HRESULTGetCurrentImage(long* pBufferSize,long* pDIBImage);

Parameters

  • pBufferSize
    [in, out] Size of the buffer the caller is passing in.
  • pDIBImage
    [out] Pointer to a buffer where the complete image will be stored in device-independent bitmap (DIB) format. The buffer must be cast to a long pointer for the function.

Return Values

Returns an HRESULT value.

Remarks

An application can use this method to get a copy of the current image the video renderer holds when paused.

The size of the buffer required to hold the image can be obtained by calling the method with a null image pointer. In this case, the buffer size is filled out with the byte count required.

The buffer size pointer must always be valid. If the application calls this method and the buffer size is too small to hold the image, the renderer returns E_OUTOFMEMORY.

Pause the video renderer before calling this method. Calling this method in any other state than paused returns VFW_E_NOT_PAUSED.

Depending on what data the source filter has available, the video renderer is not guaranteed to service this request.

If no image is available, it returns E_FAIL.

When called successfully, the output image pointer is filled with the entire DIB image, including the Microsoft Win32 BITMAPINFOHEADER structure, required palette, and bit masks as defined in the Win32 BITMAPINFO structure.

The format of the image that is returned depends on the type provided by the source filter, and cannot be explicitly defined in advance.

Typically, the image will be a 24-bit, 16-bit, or 8-bit palletized image.

Requirements

DirectShow applications and DirectShow filters have different include file and link library requirements.

For more information, see Setting Up the Build Environment.

Pocket PC: Windows Mobile 5.0 and later
Smartphone: Windows Mobile 5.0 and later
OS Versions: Windows CE 2.12 and later. Version 2.12 requires DXPAK 1.0 or later.
Header:

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.