Notifies a video capture driver to allocate a capture buffer from memory located on a video capture device.
DV_ERR_INVALHANDLE | Indicates the specified device handle is not valid. |
DV_ERR_NOMEM | Indicates the device is unable to allocate or lock memory. |
DV_ERR_NOTSUPPORTED | Indicates the driver does no have on-board memory. |
dwParam1
Address of a LPBYTE to return the address of the driver-allocated buffer.
dwParam2
Size, in bytes, of the buffer.
Normally, only devices that provide substantial on-board not included in the system heap should respond to this message. Devices that support this message can use faster capture rates because fewer data copy operations are needed during capture.
If the driver repsonds without error to this message, it must store the address of the allocated buffer in the location pointed to by dwParam1. The reference to memory outside the system heap must remain valid until the buffer is freed by the DVM_STREAM_FREEBUFFER message.
The buffer size can be larger than the dwBufferLength member of the VIDEOHDR structure to allow for sector alignment on the disk. (dwBufferLength specifies the amount of memory needed to store an image of maximum height, width, and color depth.)
If a 16-bit driver allocates buffers via this method, the buffer pointer returned must be a tiled 16:16 pointer, similar to that returned by GlobalAlloc and GlobalLock.
The buffer allocated must be accessible for DMA by the operating system.