#pragma once
#include <memory>
#include <vector>
#include "api/environment/environment.h"
#include "api/video_codecs/sdp_video_format.h"
#include "api/video_codecs/video_encoder.h"
#include "api/video_codecs/video_encoder_factory.h"
namespace livekit_ffi {
class PassthroughVideoEncoderFactory : public webrtc::VideoEncoderFactory {
public:
PassthroughVideoEncoderFactory();
~PassthroughVideoEncoderFactory() override = default;
std::vector<webrtc::SdpVideoFormat> GetSupportedFormats() const override;
std::vector<webrtc::SdpVideoFormat> GetImplementations() const override;
CodecSupport QueryCodecSupport(
const webrtc::SdpVideoFormat& format,
std::optional<std::string> scalability_mode) const override;
std::unique_ptr<webrtc::VideoEncoder> Create(
const webrtc::Environment& env,
const webrtc::SdpVideoFormat& format) override;
private:
std::vector<webrtc::SdpVideoFormat> supported_formats_;
};
}