AKTable

@objc public class AKTable: NSObject, MutableCollection

A table of values accessible as a waveform or lookup mechanism

  • Phase of the table

    Declaration

    Swift

    public var phase: Float
  • Declaration

    Swift

    public var startIndex: Index
  • Declaration

    Swift

    public var endIndex: Index
  • Declaration

    Swift

    public var count: IndexDistance
  • Initialize and set up the default table

    Declaration

    Swift

    public init(_ type: AKTableType = .sine,
                    phase: Float = 0,
                    count: IndexDistance = 4_096)

    Parameters

    type

    AKTableType of the new table

    phase

    Phase offset

    count

    Size of the table (multiple of 2)

  • Create table from audio file

    Declaration

    Swift

    public convenience init(file: AKAudioFile)
  • Offset of the phase

    Declaration

    Swift

    public var phaseOffset: Int
  • Declaration

    Swift

    public func index(before i: Index) -> Index

    Parameters

    i
  • Declaration

    Swift

    public func index(after i: Index) -> Index

    Parameters

    i
  • Declaration

    Swift

    public func index(_ i: Index, offsetBy n: IndexDistance) -> Index

    Parameters

    i
    n
  • Declaration

    Swift

    public func formIndex(after i: inout Index)

    Parameters

    i
  • Declaration

    Swift

    public func distance(from start: Index, to end: Index) -> IndexDistance

    Parameters

    start
    end