Platforms to show: All Mac Windows Linux Cross-Platform

Back to AVAudioPCMBufferMBS class.

AVAudioPCMBufferMBS.floatChannelData as Ptr

Type Topic Plugin Version macOS Windows Linux iOS Targets
property AVFoundationNode MBS AVFoundation Plugin 15.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The buffer's audio samples as floating point values.

The floatChannelData property returns pointers to the buffer’s audio samples, if the buffer’s format is 32-bit float. It returns nil if it is another format.

The returned pointer is to format.channelCount pointers to float. Each of these pointers is to frameLength valid samples, which are spaced by stride samples.

If the format is not interleaved, as with the standard deinterleaved float format, then the pointers will be to separate chunks of memory and the stride property value is 1.

If the format is interleaved, then the pointers will refer to the same buffer of interleaved samples, each offset by 1 frame, and the stride property value is the number of interleaved channels.
(Read only property)

AVAudioPCMBufferMBS.frameCapacity as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property AVFoundationNode MBS AVFoundation Plugin 15.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The buffer's capacity, in audio sample frames.

(Read only property)

Some examples using this property:

AVAudioPCMBufferMBS.frameLength as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property AVFoundationNode MBS AVFoundation Plugin 15.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The current number of valid sample frames in the buffer.

You may modify the length of the buffer as part of an operation that modifies its contents. The length must be less than or equal to the frameCapacity. Modifying frameLength will update the mDataByteSize field in each of the underlying AudioBufferList struct’s AudioBuffer struct correspondingly, and vice versa. Note that in the case of deinterleaved formats, the mDataByteSize field will refers the size of one channel’s worth of audio samples.

The length must be less than or equal to the frameCapacity. In the case of deinterleaved formats, frameCapacity will refer to the size of one channel’s worth of audio samples.
(Read and Write property)

Some examples using this property:

AVAudioPCMBufferMBS.int16ChannelData as Ptr

Type Topic Plugin Version macOS Windows Linux iOS Targets
property AVFoundationNode MBS AVFoundation Plugin 15.3 ✅ Yes ❌ No ❌ No ✅ Yes All
Access the buffer's 16bit integer audio samples.

The int16ChannelData property returns the buffer's audio samples if the buffer's format has 2-byte integer samples, or nil if it is another format.

See floatChannelData for more information.
(Read only property)

AVAudioPCMBufferMBS.int32ChannelData as Ptr

Type Topic Plugin Version macOS Windows Linux iOS Targets
property AVFoundationNode MBS AVFoundation Plugin 15.3 ✅ Yes ❌ No ❌ No ✅ Yes All
Access the buffer's 32-bit integer audio samples.

The int32ChannelData property returns the buffer's audio samples if the buffer's format has 4-byte integer samples, or nil if it is another format.

See floatChannelData for more information.
(Read only property)

AVAudioPCMBufferMBS.stride as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property AVFoundationNode MBS AVFoundation Plugin 15.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The buffer's number of interleaved channels.

(Read only property)

The items on this page are in the following plugins: MBS AVFoundation Plugin.


The biggest plugin in space...