SignalWrapper¶
Wrapper of a signal with its associated AudioInfo.
Only rawSignal or wavSignal are not null, depending on the format of the data.
If wavSignal exists, then a wavBase64Signal can also be read (in text format).
Properties¶
public let audioInfo: AudioInfo
Information of the audio recorded so far.
public let rawSignal: [Double]?
Signal in raw format.
public let wavSignal: [UInt8]?
Signal in wav format.
private(set) public lazy var wavBase64Signal: String?
Readonly
Wav signal in Base64 format.
Public Methods¶
convenience init(_ audioInfo: AudioInfo, _ rawSignal: [Double])
Convenience constructor of the class. The main constructor is private.
-
Parameters:
- audioInfo: information of the audio recorded so far.
- rawSignal: signal in raw format.
convenience init(_ audioInfo: AudioInfo, _ wavSignal: [UInt8])
Convenience constructor of the class. The main constructor is private.
-
Parameters:
- audioInfo: information of the audio recorded so far.
- wavSignal: signal in wav format.