chromium/third_party/webrtc/pc/rtp_transmission_manager.cc

/*
 *  Copyright 2020 The WebRTC project authors. All Rights Reserved.
 *
 *  Use of this source code is governed by a BSD-style license
 *  that can be found in the LICENSE file in the root of the source
 *  tree. An additional intellectual property rights grant can be found
 *  in the file PATENTS.  All contributing project authors may
 *  be found in the AUTHORS file in the root of the source tree.
 */

#include "pc/rtp_transmission_manager.h"

#include <type_traits>
#include <utility>

#include "absl/types/optional.h"
#include "api/peer_connection_interface.h"
#include "api/rtp_transceiver_direction.h"
#include "pc/audio_rtp_receiver.h"
#include "pc/channel_interface.h"
#include "pc/legacy_stats_collector_interface.h"
#include "pc/video_rtp_receiver.h"
#include "rtc_base/checks.h"
#include "rtc_base/crypto_random.h"
#include "rtc_base/logging.h"

namespace webrtc {

namespace {

static const char kDefaultAudioSenderId[] =;
static const char kDefaultVideoSenderId[] =;

}  // namespace

RtpTransmissionManager::RtpTransmissionManager(
    bool is_unified_plan,
    ConnectionContext* context,
    UsagePattern* usage_pattern,
    PeerConnectionObserver* observer,
    LegacyStatsCollectorInterface* legacy_stats,
    std::function<void()> on_negotiation_needed)
    :{}

void RtpTransmissionManager::Close() {}

// Implementation of SetStreamsObserver
void RtpTransmissionManager::OnSetStreams() {}

// Function to call back to the PeerConnection when negotiation is needed
void RtpTransmissionManager::OnNegotiationNeeded() {}

// Function that returns the currently valid observer
PeerConnectionObserver* RtpTransmissionManager::Observer() const {}

cricket::VoiceMediaSendChannelInterface*
RtpTransmissionManager::voice_media_send_channel() const {}

cricket::VideoMediaSendChannelInterface*
RtpTransmissionManager::video_media_send_channel() const {}
cricket::VoiceMediaReceiveChannelInterface*
RtpTransmissionManager::voice_media_receive_channel() const {}

cricket::VideoMediaReceiveChannelInterface*
RtpTransmissionManager::video_media_receive_channel() const {}

RTCErrorOr<rtc::scoped_refptr<RtpSenderInterface>>
RtpTransmissionManager::AddTrack(
    rtc::scoped_refptr<MediaStreamTrackInterface> track,
    const std::vector<std::string>& stream_ids,
    const std::vector<RtpEncodingParameters>* init_send_encodings) {}

RTCErrorOr<rtc::scoped_refptr<RtpSenderInterface>>
RtpTransmissionManager::AddTrackPlanB(
    rtc::scoped_refptr<MediaStreamTrackInterface> track,
    const std::vector<std::string>& stream_ids,
    const std::vector<RtpEncodingParameters>* init_send_encodings) {}

RTCErrorOr<rtc::scoped_refptr<RtpSenderInterface>>
RtpTransmissionManager::AddTrackUnifiedPlan(
    rtc::scoped_refptr<MediaStreamTrackInterface> track,
    const std::vector<std::string>& stream_ids,
    const std::vector<RtpEncodingParameters>* init_send_encodings) {}

rtc::scoped_refptr<RtpSenderProxyWithInternal<RtpSenderInternal>>
RtpTransmissionManager::CreateSender(
    cricket::MediaType media_type,
    const std::string& id,
    rtc::scoped_refptr<MediaStreamTrackInterface> track,
    const std::vector<std::string>& stream_ids,
    const std::vector<RtpEncodingParameters>& send_encodings) {}

rtc::scoped_refptr<RtpReceiverProxyWithInternal<RtpReceiverInternal>>
RtpTransmissionManager::CreateReceiver(cricket::MediaType media_type,
                                       const std::string& receiver_id) {}

rtc::scoped_refptr<RtpTransceiverProxyWithInternal<RtpTransceiver>>
RtpTransmissionManager::CreateAndAddTransceiver(
    rtc::scoped_refptr<RtpSenderProxyWithInternal<RtpSenderInternal>> sender,
    rtc::scoped_refptr<RtpReceiverProxyWithInternal<RtpReceiverInternal>>
        receiver) {}

rtc::scoped_refptr<RtpTransceiverProxyWithInternal<RtpTransceiver>>
RtpTransmissionManager::FindFirstTransceiverForAddedTrack(
    rtc::scoped_refptr<MediaStreamTrackInterface> track,
    const std::vector<RtpEncodingParameters>* init_send_encodings) {}

std::vector<rtc::scoped_refptr<RtpSenderProxyWithInternal<RtpSenderInternal>>>
RtpTransmissionManager::GetSendersInternal() const {}

std::vector<
    rtc::scoped_refptr<RtpReceiverProxyWithInternal<RtpReceiverInternal>>>
RtpTransmissionManager::GetReceiversInternal() const {}

rtc::scoped_refptr<RtpTransceiverProxyWithInternal<RtpTransceiver>>
RtpTransmissionManager::GetAudioTransceiver() const {}

rtc::scoped_refptr<RtpTransceiverProxyWithInternal<RtpTransceiver>>
RtpTransmissionManager::GetVideoTransceiver() const {}

void RtpTransmissionManager::AddAudioTrack(AudioTrackInterface* track,
                                           MediaStreamInterface* stream) {}

// TODO(deadbeef): Don't destroy RtpSenders here; they should be kept around
// indefinitely, when we have unified plan SDP.
void RtpTransmissionManager::RemoveAudioTrack(AudioTrackInterface* track,
                                              MediaStreamInterface* stream) {}

void RtpTransmissionManager::AddVideoTrack(VideoTrackInterface* track,
                                           MediaStreamInterface* stream) {}

void RtpTransmissionManager::RemoveVideoTrack(VideoTrackInterface* track,
                                              MediaStreamInterface* stream) {}

void RtpTransmissionManager::CreateAudioReceiver(
    MediaStreamInterface* stream,
    const RtpSenderInfo& remote_sender_info) {}

void RtpTransmissionManager::CreateVideoReceiver(
    MediaStreamInterface* stream,
    const RtpSenderInfo& remote_sender_info) {}

// TODO(deadbeef): Keep RtpReceivers around even if track goes away in remote
// description.
rtc::scoped_refptr<RtpReceiverInterface>
RtpTransmissionManager::RemoveAndStopReceiver(
    const RtpSenderInfo& remote_sender_info) {}

void RtpTransmissionManager::OnRemoteSenderAdded(
    const RtpSenderInfo& sender_info,
    MediaStreamInterface* stream,
    cricket::MediaType media_type) {}

void RtpTransmissionManager::OnRemoteSenderRemoved(
    const RtpSenderInfo& sender_info,
    MediaStreamInterface* stream,
    cricket::MediaType media_type) {}

void RtpTransmissionManager::OnLocalSenderAdded(
    const RtpSenderInfo& sender_info,
    cricket::MediaType media_type) {}

void RtpTransmissionManager::OnLocalSenderRemoved(
    const RtpSenderInfo& sender_info,
    cricket::MediaType media_type) {}

std::vector<RtpSenderInfo>* RtpTransmissionManager::GetRemoteSenderInfos(
    cricket::MediaType media_type) {}

std::vector<RtpSenderInfo>* RtpTransmissionManager::GetLocalSenderInfos(
    cricket::MediaType media_type) {}

const RtpSenderInfo* RtpTransmissionManager::FindSenderInfo(
    const std::vector<RtpSenderInfo>& infos,
    const std::string& stream_id,
    const std::string& sender_id) const {}

rtc::scoped_refptr<RtpSenderProxyWithInternal<RtpSenderInternal>>
RtpTransmissionManager::FindSenderForTrack(
    MediaStreamTrackInterface* track) const {}

rtc::scoped_refptr<RtpSenderProxyWithInternal<RtpSenderInternal>>
RtpTransmissionManager::FindSenderById(const std::string& sender_id) const {}

rtc::scoped_refptr<RtpReceiverProxyWithInternal<RtpReceiverInternal>>
RtpTransmissionManager::FindReceiverById(const std::string& receiver_id) const {}

cricket::MediaEngineInterface* RtpTransmissionManager::media_engine() const {}

}  // namespace webrtc