PFNKSDEFAULTALLOCATE callback function (ks.h)
An AVStream minidriver's AVStrMiniAllocate routine allocates a frame using the allocator specified in the Context parameter.
Syntax
PFNKSDEFAULTALLOCATE Pfnksdefaultallocate;
PVOID Pfnksdefaultallocate(
[in] PVOID Context
)
{...}
Parameters
[in] Context
Pointer to the allocator's context structure created in AVStrMiniInitializeAllocator.
Return value
Allocate returns a pointer to the newly allocated memory. Return NULL if the attempt to allocate memory failed.
Remarks
The minidriver specifies this routine's address in the Allocate member of its KSALLOCATOR_DISPATCH structure. The minidriver passes this structure to the class driver in KSPIN_DISPATCH.
AVStream calls this routine to allocate a frame. The handler should allocate a frame as described by the allocator framing context passed into the initialization dispatch.
For more information, see KS Allocators.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Available in Microsoft Windows XP and later operating systems and DirectX 8.0 and later DirectX versions. |
Target Platform | Desktop |
Header | ks.h (include Ks.h) |