Initializes a new discrete cosine transform instance.
- Parameter previous: a previous vDSP_DCT instance to share data with.
- Parameter count: the number of real elements to be transformed.
- Parameter transformType: Specifies the transform type (type II for forward and type III for inverse).
func transform<U, V>(_ vector: U, result: inout V) where U : AccelerateBuffer, V : AccelerateMutableBuffer, U.Element == Float, V.Element == Float
Computes an out-of-place single-precision real discrete cosine transform.
- Parameter input: Real input vector.
- Parameter output: Real output vector.
Omit the output parameters from the call. The result contains $ret and $out, with result inside $out.
method · iOS 13.0+
transform
TypeScript
transform(vector: Array<number>): Array<number>
Swift declaration
func transform<U>(_ vector: U) -> [Float] where U : AccelerateBuffer, U.Element == Float
Returns the single-precision real discrete cosine transform.
- Parameter input: Real input vector.
- Returns: Real output vector.