blob: fd5085c336af690f9b5b89ca3c8d37a7486daa99 [file] [log] [blame]
Mirko Bonadei79eb4dd2018-07-19 08:39:301/*
2 * Copyright 2018 The WebRTC project authors. All Rights Reserved.
3 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
Steve Anton10542f22019-01-11 17:11:0011#include "api/rtp_transceiver_interface.h"
Mirko Bonadei79eb4dd2018-07-19 08:39:3012
Yves Gerey988cc082018-10-23 10:03:0113#include "rtc_base/checks.h"
14
Mirko Bonadei79eb4dd2018-07-19 08:39:3015namespace webrtc {
16
17RtpTransceiverInit::RtpTransceiverInit() = default;
18
Mirko Bonadei2ffed6d2018-07-20 09:09:3219RtpTransceiverInit::RtpTransceiverInit(const RtpTransceiverInit& rhs) = default;
20
Mirko Bonadei79eb4dd2018-07-19 08:39:3021RtpTransceiverInit::~RtpTransceiverInit() = default;
22
23absl::optional<RtpTransceiverDirection>
24RtpTransceiverInterface::fired_direction() const {
25 return absl::nullopt;
26}
27
Harald Alvestrand6060df52020-08-11 07:54:0228bool RtpTransceiverInterface::stopping() const {
29 return false;
30}
31
32void RtpTransceiverInterface::Stop() {
33 StopInternal();
34}
35
36RTCError RtpTransceiverInterface::StopStandard() {
37 RTC_NOTREACHED() << "DEBUG: RtpTransceiverInterface::StopStandard called";
38 return RTCError::OK();
39}
40
41void RtpTransceiverInterface::StopInternal() {
42 RTC_NOTREACHED() << "DEBUG: RtpTransceiverInterface::StopInternal called";
43}
44
Florent Castelli2d9d82e2019-04-23 17:25:5145RTCError RtpTransceiverInterface::SetCodecPreferences(
Florent Castelli38078972018-09-24 17:10:4046 rtc::ArrayView<RtpCodecCapability>) {
47 RTC_NOTREACHED() << "Not implemented";
Florent Castelli2d9d82e2019-04-23 17:25:5148 return {};
49}
50
51std::vector<RtpCodecCapability> RtpTransceiverInterface::codec_preferences()
52 const {
53 return {};
Florent Castelli38078972018-09-24 17:10:4054}
55
Markus Handell0357b3e2020-03-16 12:40:5156std::vector<RtpHeaderExtensionCapability>
57RtpTransceiverInterface::HeaderExtensionsToOffer() const {
58 return {};
59}
60
Markus Handell755c65d2020-06-23 23:06:1061webrtc::RTCError RtpTransceiverInterface::SetOfferedRtpHeaderExtensions(
62 rtc::ArrayView<const RtpHeaderExtensionCapability>
63 header_extensions_to_offer) {
64 return webrtc::RTCError(webrtc::RTCErrorType::UNSUPPORTED_OPERATION);
65}
66
Markus Handell5932fe12020-12-17 21:19:4067std::vector<RtpHeaderExtensionCapability>
68RtpTransceiverInterface::HeaderExtensionsNegotiated() const {
69 return {};
70}
71
Harald Alvestrand6060df52020-08-11 07:54:0272// TODO(bugs.webrtc.org/11839) Remove default implementations when clients
73// are updated.
74void RtpTransceiverInterface::SetDirection(
75 RtpTransceiverDirection new_direction) {
76 SetDirectionWithError(new_direction);
77}
78
79RTCError RtpTransceiverInterface::SetDirectionWithError(
80 RtpTransceiverDirection new_direction) {
81 RTC_NOTREACHED() << "Default implementation called";
82 return RTCError::OK();
83}
84
Mirko Bonadei79eb4dd2018-07-19 08:39:3085} // namespace webrtc