9#ifndef SKYWAY_MEDIA_V4L2_CAPTURER_VIDEO_SOURCE_HPP_
10#define SKYWAY_MEDIA_V4L2_CAPTURER_VIDEO_SOURCE_HPP_
12#include "skyway/media/interface/capturer_video_source.hpp"
18class V4l2CapturerVideoSource :
public interface::InternalCapturerVideoSource {
20 ~V4l2CapturerVideoSource();
22 static rtc::scoped_refptr<V4l2CapturerVideoSource> Create(
23 const std::string& device_unique_id, webrtc::VideoCaptureCapability device_capability);
26 bool is_screencast()
const override;
27 absl::optional<bool> needs_denoising()
const override;
28 webrtc::MediaSourceInterface::SourceState state()
const override;
29 bool remote()
const override;
32 void OnFrame(
const webrtc::VideoFrame& frame)
override;
35 V4l2CapturerVideoSource();
38 bool Init(
const std::string& device_unique_id,
39 webrtc::VideoCaptureCapability device_capability);
41 rtc::scoped_refptr<webrtc::VideoCaptureModule> vcm_;