I need to encode raw audio into ogg packets with opus codec.
I get the raw audio like that:
input.installTapOnBus(0, bufferSize: 2048, format: input.inputFormatForBus(0)) { (buffer: AVAudioPCMBuffer!, time: AVAudioTime!) -> Void in
// Encode buffer to Ogg
}
I have Ogg.framework and libopus.a in my project. I don't seem to understand the documentation how to actually use Opus with Ogg. And I didn't find any example that replicates what I need.
Any help appreciated!