【WebRTC---源码篇】(二:三)视频消费者VideoSinkInterfacee

作用:这是一个视频消费的基类,所有需要使用视频帧数据的类都需要继承它

cpp 复制代码
namespace rtc {
//VideoSinkInterface是WebRTC中用于接收和处理视频帧数据的接口类。
//通过实现该接口,可以实现自定义的视频数据处理逻辑。
template <typename VideoFrameT>
class VideoSinkInterface {
 public:
  virtual ~VideoSinkInterface() = default;

  virtual void OnFrame(const VideoFrameT& frame) = 0;

  // Should be called by the source when it discards the frame due to rate
  // limiting.
  virtual void OnDiscardedFrame() {}
};

}  // namespace rtc

看看哪些类继承了它

class Renderer : public rtc::VideoSinkInterface<VideoFrame>

class VideoRtcpAndSyncObserver : public test::RtpRtcpObserver,

public rtc::VideoSinkInterface<VideoFrame>

相关推荐
好家伙VCC3 天前
### WebRTC技术:实时通信的革新与实现####webRTC(Web Real-TimeComm
java·前端·python·webrtc
XHW___0013 天前
webrtc 关键模块创建的时机
网络·音视频·webrtc
我真会写代码3 天前
WebSocket:告别轮询,实现Web实时通信 WebRTC:无需插件,实现浏览器端实时音视频通信
网络·websocket·网络协议·webrtc·实时音视频
又是忙碌的一天3 天前
SpringBoot+Vue+Netty+WebSocket+WebRTC 视频聊天实现
websocket·音视频·webrtc
柒.梧.4 天前
理解WebRTC:浏览器原生实时音视频通信
webrtc·实时音视频
XHW___0014 天前
webrtc中音频3A处理开关配置
音视频·webrtc
sin22014 天前
WebRTC--流程
spring boot·webrtc
runner365.git5 天前
webrtc服务端如何录像
webrtc·录像·fmp4·mpegts
大佐不会说日语~7 天前
WebRTC技术实现简易直播平台
webrtc
YRYDZFtyVKg9 天前
光伏MPPT仿真之扰动观察法探索
webrtc