mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-08-08 08:31:13 +00:00
Moved public API classes into namespace tgvoip (CVoIPController -> tgvoip::VoIPController, CVoIPServerConfig -> tgvoip::ServerConfig) Endpoint is now a class instead of a struct; also, IP addresses are now wrapped into objects instead of relying on in_addr and in6_addr Full Windows port (Win32 threading + Winsock + WaveOut/WaveIn) Added support for ALSA audio I/O on Linux (closes #2) Abstracted away low-level networking to make it more portable Minor bugfixes
33 lines
761 B
C++
33 lines
761 B
C++
//
|
|
// libtgvoip is free and unencumbered public domain software.
|
|
// For more information, see http://unlicense.org or the UNLICENSE file
|
|
// you should have received with this source code distribution.
|
|
//
|
|
|
|
#ifndef LIBTGVOIP_AUDIOOUTPUT_H
|
|
#define LIBTGVOIP_AUDIOOUTPUT_H
|
|
|
|
#include <stdint.h>
|
|
#include "../MediaStreamItf.h"
|
|
|
|
class CAudioOutput : public CMediaStreamItf{
|
|
public:
|
|
CAudioOutput();
|
|
virtual ~CAudioOutput();
|
|
virtual void Configure(uint32_t sampleRate, uint32_t bitsPerSample, uint32_t channels)=0;
|
|
virtual bool IsPlaying()=0;
|
|
virtual float GetLevel();
|
|
static CAudioOutput* Create();
|
|
static int32_t GetEstimatedDelay();
|
|
|
|
#if defined(__ANDROID__)
|
|
static int systemVersion;
|
|
#endif
|
|
|
|
protected:
|
|
bool failed;
|
|
};
|
|
|
|
|
|
#endif //LIBTGVOIP_AUDIOOUTPUT_H
|