#include "FakeInterface.h" #include "api/video_codecs/builtin_video_encoder_factory.h" #include "api/video_codecs/builtin_video_decoder_factory.h" //#include "api/video_track_source_proxy.h" namespace tgcalls { std::unique_ptr FakeInterface::makeVideoEncoderFactory(bool preferHardwareEncoding, bool isScreencast) { return webrtc::CreateBuiltinVideoEncoderFactory(); } std::unique_ptr FakeInterface::makeVideoDecoderFactory() { return webrtc::CreateBuiltinVideoDecoderFactory(); } rtc::scoped_refptr FakeInterface::makeVideoSource(rtc::Thread *signalingThread, rtc::Thread *workerThread) { return nullptr; } bool FakeInterface::supportsEncoding(const std::string &codecName) { return false; //return (codecName == cricket::kH264CodecName) || (codecName == cricket::kVp8CodecName); } void FakeInterface::adaptVideoSource(rtc::scoped_refptr videoSource, int width, int height, int fps) { } std::unique_ptr FakeInterface::makeVideoCapturer( rtc::scoped_refptr source, std::string deviceId, std::function stateUpdated, std::function captureInfoUpdated, std::shared_ptr platformContext, std::pair &outResolution) { return nullptr; //return std::make_unique(source, deviceId, stateUpdated, outResolution); } std::unique_ptr CreatePlatformInterface() { return std::make_unique(); } } // namespace tgcalls