Bewerken

Delen via


AudioQueue.AllocateBuffer Method

Definition

Overloads

AllocateBuffer(Int32, AudioQueueBuffer*)

Allocates an audio buffer associated with this AudioQueue

AllocateBuffer(Int32, IntPtr)

Allocates an audio buffer associated with this AudioQueue, used for fixed bit rate buffers.

AllocateBuffer(Int32, AudioQueueBuffer*)

Allocates an audio buffer associated with this AudioQueue

public AudioToolbox.AudioQueueStatus AllocateBuffer (int bufferSize, out AudioToolbox.AudioQueueBuffer* audioQueueBuffer);
member this.AllocateBuffer : int *  -> AudioToolbox.AudioQueueStatus

Parameters

bufferSize
Int32

The audio buffer size to allocate (in bytes).

audioQueueBuffer
AudioQueueBuffer*

Returns the allocated buffer as an unsafe AudioQueueBuffer pointer.

Returns

AudioQueueStatus.Ok on success, otherwise the error.

Remarks

Use FreeBuffer(IntPtr) to dispose the buffer.

Applies to

AllocateBuffer(Int32, IntPtr)

Allocates an audio buffer associated with this AudioQueue, used for fixed bit rate buffers.

public AudioToolbox.AudioQueueStatus AllocateBuffer (int bufferSize, out IntPtr audioQueueBuffer);
member this.AllocateBuffer : int *  -> AudioToolbox.AudioQueueStatus

Parameters

bufferSize
Int32

The audio buffer size to allocate (in bytes).

audioQueueBuffer
IntPtr

nativeint

Returns the pointer to the allocated buffer as an IntPtr.

Returns

AudioQueueStatus.Ok on success, otherwise the error.

Remarks

Use the AllocateBufferWithPacketDescriptors(Int32, Int32, IntPtr) to allocate buffers that will be used with variable bit rate encodings.

Use FreeBuffer(IntPtr) to dispose the buffer.

Applies to