Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

< Previous PageNext Page > Hide TOC

Audio Buffer Structures

AudioBuffer

A single buffer and the associated data.

typedef struct AudioBuffer {
UInt32 mNumberChannels;
UInt32 mDataByteSize;
void* mData;
} AudioBuffer;

Discussion

This structure is not used on its own, but with AudioBufferList as one of its data members. An instance of AudioBuffer keeps track of the number of channels in the buffer, the size of the buffer, and a pointer to the buffer data.

Availability
Declared In
CoreAudioTypes.h

AudioBufferList

Keeps track of multiple buffers.

typedef struct AudioBufferList {
UInt32 mNumberBuffers;
AudioBuffer mBuffers[1];
} AudioBufferList;

Discussion

When audio data is interleaved, only one buffer is needed in the AudioBufferList; when dealing with multiple mono channels, each will need its own buffer. This is accomplished by allocating the needed space and pointing mBuffers to it.

Availability
Declared In
CoreAudioTypes.h

< Previous PageNext Page > Hide TOC


Last updated: 2004-03-25




Did this document help you?
Yes: Tell us what works for you.

It’s good, but: Report typos, inaccuracies, and so forth.

It wasn’t helpful: Tell us what would have helped.
Get information on Apple products.
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Copyright © 2007 Apple Inc.
All rights reserved. | Terms of use | Privacy Notice