#ifndef _AUDIO_H_ #define _AUDIO_H_ #include #include #include #include typedef struct audio_t { PaStream *stream; OpusEncoder *opusEnc; OpusDecoder *opusDec; uint8_t *opusBuf; size_t opusBufSz; } audio_t; int audio_default_callback(const void *input, void *output, unsigned long frameCount, const PaStreamCallbackTimeInfo *timeInfo, PaStreamCallbackFlags statusFlags, void *userData); int audio_init_default(audio_t *aud, int channels, int sampleRate, int frameSize, PaStreamCallback *callback); int audio_destroy(audio_t *aud); #endif /* _AUDIO_H_ */