mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-06-25 03:02:22 +08:00
整理webrtc相关代码命名空间
This commit is contained in:
@@ -11,13 +11,14 @@
|
||||
#include "WebRtcPusher.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace mediakit;
|
||||
|
||||
namespace mediakit {
|
||||
|
||||
WebRtcPusher::Ptr WebRtcPusher::create(const EventPoller::Ptr &poller,
|
||||
const RtspMediaSourceImp::Ptr &src,
|
||||
const std::shared_ptr<void> &ownership,
|
||||
const MediaInfo &info,
|
||||
const mediakit::ProtocolOption &option) {
|
||||
const ProtocolOption &option) {
|
||||
WebRtcPusher::Ptr ret(new WebRtcPusher(poller, src, ownership, info, option), [](WebRtcPusher *ptr) {
|
||||
ptr->onDestory();
|
||||
delete ptr;
|
||||
@@ -30,7 +31,7 @@ WebRtcPusher::WebRtcPusher(const EventPoller::Ptr &poller,
|
||||
const RtspMediaSourceImp::Ptr &src,
|
||||
const std::shared_ptr<void> &ownership,
|
||||
const MediaInfo &info,
|
||||
const mediakit::ProtocolOption &option) : WebRtcTransportImp(poller) {
|
||||
const ProtocolOption &option) : WebRtcTransportImp(poller) {
|
||||
_media_info = info;
|
||||
_push_src = src;
|
||||
_push_src_ownership = ownership;
|
||||
@@ -142,7 +143,7 @@ void WebRtcPusher::onRtcConfigure(RtcConfigure &configure) const {
|
||||
configure.audio.direction = configure.video.direction = RtpDirection::recvonly;
|
||||
}
|
||||
|
||||
float WebRtcPusher::getLossRate(MediaSource &sender,mediakit::TrackType type){
|
||||
float WebRtcPusher::getLossRate(MediaSource &sender,TrackType type){
|
||||
return WebRtcTransportImp::getLossRate(type);
|
||||
}
|
||||
|
||||
@@ -155,4 +156,6 @@ void WebRtcPusher::OnDtlsTransportClosed(const RTC::DtlsTransport *dtlsTransport
|
||||
void WebRtcPusher::onRtcpBye(){
|
||||
_push_src = nullptr;
|
||||
WebRtcTransportImp::onRtcpBye();
|
||||
}
|
||||
}
|
||||
|
||||
}// namespace mediakit
|
||||
Reference in New Issue
Block a user