ComponentOne Bitmap for WPF
C1.WPF.DX.4.5.2 Assembly / C1.Util.DX Namespace / DXUtil Class / AllocateClearedMemory Method
Size of the buffer to allocate.
Default value used to clear the buffer.
Alignment, 16 bytes by default.

In This Topic
    AllocateClearedMemory Method
    In This Topic
    Allocate an aligned memory buffer and clear it with a specified value (0 by default).
    Syntax
    'Declaration
     
    Public Shared Function AllocateClearedMemory( _
       ByVal sizeInBytes As Integer, _
       Optional ByVal clearValue As Byte, _
       Optional ByVal align As Integer _
    ) As IntPtr
    public static IntPtr AllocateClearedMemory( 
       int sizeInBytes,
       byte clearValue,
       int align
    )

    Parameters

    sizeInBytes
    Size of the buffer to allocate.
    clearValue
    Default value used to clear the buffer.
    align
    Alignment, 16 bytes by default.

    Return Value

    A pointer to a buffer aligned.
    Remarks
    To free this buffer, call FreeMemory.
    See Also