cinder::audio::dsp Namespace
Namespaces
Classes
-
class
-
class
-
class
-
class
-
class
Typedefs
-
RingBufferT< float >RingBuffer
Enumerations
Functions
-
CI_API voidmixBuffers (const Buffer *sourceBuffer, Buffer *destBuffer, size_t numFrames)
Mixes numFrames frames of sourceBuffer to destBuffer's layout, replacing its content. Channel up or down mixing is applied if necessary.
-
voidmixBuffers (const Buffer *sourceBuffer, Buffer *destBuffer)
Mixes sourceBuffer to destBuffer's layout, replacing its content. Channel up or down mixing is applied if necessary. Unequal frame counts are permitted (the minimum size will be used).
-
CI_API voidsumBuffers (const Buffer *sourceBuffer, Buffer *destBuffer, size_t numFrames)
Sums numFrames frames of sourceBuffer into destBuffer . Channel up or down mixing is applied if necessary.
-
voidsumBuffers (const Buffer *sourceBuffer, Buffer *destBuffer)
Sums sourceBuffer into destBuffer . Channel up or down mixing is applied if necessary. Unequal frame counts are permitted (the minimum size will be used).
-
voidconvert (const SourceT *sourceArray, DestT *destArray, size_t length)
Converts between two arrays of different precision (ex. float to double). length samples are converted.
-
voidconvert (const FloatT *sourceArray, int16_t *destArray, size_t length)
Converts a float or double array to int16_t.
-
voidconvert (const int16_t *sourceArray, FloatT *destArray, size_t length)
Converts an int16_t array to float or double.
-
voidconvertBuffer (const BufferT< SourceT > *sourceBuffer, BufferT< DestT > *destBuffer)
Converts between two BufferT 's of different precision (ex. float to double). The number of frames converted is the lesser of the two. The number of channels converted is the lesser of the two.
-
voidconvertInt24ToFloat (const char *sourceArray, FloatT *destArray, size_t length)
Converts the 24-bit int sourceArray to floating point precision, placing the result in destArray . length samples are converted.
-
voidconvertFloatToInt24 (const FloatT *sourceArray, char *destArray, size_t length)
Converts the floating point sourceArray to 24-bit int precision, placing the result in destArray . length samples are converted.
-
voidinterleave (const T *nonInterleavedSourceArray, T *interleavedDestArray, size_t numFramesPerChannel, size_t numChannels, size_t numCopyFrames)
Interleaves numCopyFrames of nonInterleavedSourceArray , placing the result in interleavedDestArray . numFramesPerChannel and numChannels describe the layout of the non-interleaved array.
-
voidinterleave (const FloatT *nonInterleavedFloatSourceArray, int16_t *interleavedInt16DestArray, size_t numFramesPerChannel, size_t numChannels, size_t numCopyFrames)
Interleaves numCopyFrames of nonInterleavedFloatSourceArray and converts from floating point to 16-bit int precision at the same time, placing the result in interleavedInt16DestArray . numFramesPerChannel and numChannels describe the layout of the non-interleaved array.
-
voiddeinterleave (const T *interleavedSourceArray, T *nonInterleavedDestArray, size_t numFramesPerChannel, size_t numChannels, size_t numCopyFrames)
De-interleaves numCopyFrames of interleavedSourceArray , placing the result in nonInterleavedDestArray . numFramesPerChannel and numChannels describe the layout of the non-interleaved array.
-
voiddeinterleave (const int16_t *interleavedInt16SourceArray, FloatT *nonInterleavedFloatDestArray, size_t numFramesPerChannel, size_t numChannels, size_t numCopyFrames)
De-interleaves numCopyFrames of interleavedInt16SourceArray and converts from 16-bit int to floating point precision at the same time, placing the result in nonInterleavedFloatDestArray . numFramesPerChannel and numChannels describe the layout of the non-interleaved array.
-
voiddeinterleaveInt24ToFloat (const char *interleavedInt24SourceArray, FloatT *nonInterleavedFloatDestArray, size_t numFramesPerChannel, size_t numChannels, size_t numCopyFrames)
De-interleaves numCopyFrames of interleavedInt24SourceArray and converts from 24-bit int to floating point precision at the same time, placing the result in nonInterleavedFloatDestArray . numFramesPerChannel and numChannels describe the layout of the non-interleaved array.
-
voidinterleaveBuffer (const BufferT< T > *nonInterleavedSource, BufferInterleavedT< T > *interleavedDest)
Interleaves nonInterleavedSource , placing the result in interleavedDest .
-
voiddeinterleaveBuffer (const BufferInterleavedT< T > *interleavedSource, BufferT< T > *nonInterleavedDest)
De-interleaves interleavedSource , placing the result in nonInterleavedDest .
-
voidinterleaveStereoBuffer (const BufferT< T > *nonInterleavedSource, BufferInterleavedT< T > *interleavedDest)
Interleaves nonInterleavedSource , placing the result in interleavedDest . This method is only slightly faster than interleaveBuffer() , which can handle an arbitrary number of channels.
-
voiddeinterleaveStereoBuffer (const BufferInterleavedT< T > *interleavedSource, BufferT< T > *nonInterleavedDest)
De-interleaves interleavedSource , placing the result in nonInterleavedDest . This method is only slightly faster than deinterleaveStereoBuffer() , which can handle an arbitrary number of channels.
-
CI_API voidgenerateBlackmanWindow (float *window, size_t length)
Fills length samples of window with a Blackmann windowing function.
-
CI_API voidgenerateHammingWindow (float *window, size_t length)
Fills length samples of window with a Hamming windowing function.
-
CI_API voidgenerateHannWindow (float *window, size_t length)
Fills length samples of window with a Hann windowing function.
-
CI_API voidgenerateWindow (WindowType windowType, float *window, size_t length)
fills window array with a windowing function specified by windowType
-
CI_API voidfill (float value, float *array, size_t length)
fills array with value value
-
CI_API voidadd (const float *array, float scalar, float *result, size_t length)
add scalar to array of length length , into result .
-
CI_API voidadd (const float *arrayA, const float *arrayB, float *result, size_t length)
add length elements of arrayA and arrayB (element-wise) into result .
-
CI_API voidsub (const float *array, float scalar, float *result, size_t length)
subtract scalar from array of length length , into result .
-
CI_API voidsub (const float *arrayA, const float *arrayB, float *result, size_t length)
subtract length elements of arrayB from arrayA (element-wise) into result .
-
CI_API voidmul (const float *array, float scalar, float *result, size_t length)
multiplies length elements of array by scalar and places the result at result .
-
CI_API voidmul (const float *arrayA, const float *arrayB, float *result, size_t length)
multiplies length elements of arrayA by arrayB and places the result at result .
-
CI_API voiddivide (const float *array, float scalar, float *result, size_t length)
divides length elements of array by scalar and places the result at result .
-
CI_API voiddivide (const float *arrayA, const float *arrayB, float *result, size_t length)
divides length elements of arrayA by arrayB and places the result at result .
-
CI_API voidaddMul (const float *arrayA, const float *arrayB, float scalar, float *result, size_t length)
sums length elements of arrayA by arrayB (element-wise), then scales by scalar and places the result at result .
-
CI_API floatsum (const float *array, size_t length)
returns the sum of array
-
CI_API floatrms (const float *array, size_t length)
returns the Root-Mean-Squared value of array
-
CI_API voidnormalize (float *array, size_t length, float maxValue=1)
normalizes array to maxValue (default = 1)
-
CI_API floatspectralCentroid (const float *magArray, size_t magArrayLength, size_t sampleRate)
returns the spectral centroid of the frequency magnitude spectrum in magArray , computed the provided sampleRate . magArrayLength is expected to be half of the FFT size used to compute the magnitude spectrum.