blob: 8ed32f63da37c449899ae269109f56e05edda653 [file] [log] [blame]
Markus Handelle93fe6c2021-05-20 20:46:311/*
2 * Copyright 2021 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
11#ifndef PC_RTP_SENDER_PROXY_H_
12#define PC_RTP_SENDER_PROXY_H_
13
Jonas Oreland65455162022-06-08 09:25:4614#include <memory>
Markus Handelle93fe6c2021-05-20 20:46:3115#include <string>
16#include <vector>
17
Markus Handelle93fe6c2021-05-20 20:46:3118#include "api/rtp_sender_interface.h"
Markus Handella1b82012021-05-26 16:56:3019#include "pc/proxy.h"
Markus Handelle93fe6c2021-05-20 20:46:3120
21namespace webrtc {
22
23// Define proxy for RtpSenderInterface.
24// TODO(deadbeef): Move this to .cc file. What threads methods are called on is
25// an implementation detail.
26BEGIN_PRIMARY_PROXY_MAP(RtpSender)
27PROXY_PRIMARY_THREAD_DESTRUCTOR()
28PROXY_METHOD1(bool, SetTrack, MediaStreamTrackInterface*)
29PROXY_CONSTMETHOD0(rtc::scoped_refptr<MediaStreamTrackInterface>, track)
30PROXY_CONSTMETHOD0(rtc::scoped_refptr<DtlsTransportInterface>, dtls_transport)
31PROXY_CONSTMETHOD0(uint32_t, ssrc)
32BYPASS_PROXY_CONSTMETHOD0(cricket::MediaType, media_type)
33BYPASS_PROXY_CONSTMETHOD0(std::string, id)
34PROXY_CONSTMETHOD0(std::vector<std::string>, stream_ids)
35PROXY_CONSTMETHOD0(std::vector<RtpEncodingParameters>, init_send_encodings)
36PROXY_CONSTMETHOD0(RtpParameters, GetParameters)
37PROXY_METHOD1(RTCError, SetParameters, const RtpParameters&)
Florent Castelliacabb362022-10-18 15:05:1638PROXY_METHOD2(void,
39 SetParametersAsync,
40 const RtpParameters&,
41 SetParametersCallback)
Markus Handelle93fe6c2021-05-20 20:46:3142PROXY_CONSTMETHOD0(rtc::scoped_refptr<DtmfSenderInterface>, GetDtmfSender)
43PROXY_METHOD1(void,
44 SetFrameEncryptor,
45 rtc::scoped_refptr<FrameEncryptorInterface>)
46PROXY_CONSTMETHOD0(rtc::scoped_refptr<FrameEncryptorInterface>,
47 GetFrameEncryptor)
48PROXY_METHOD1(void, SetStreams, const std::vector<std::string>&)
49PROXY_METHOD1(void,
Harald Alvestrandb0e70572024-04-23 14:04:1850 SetFrameTransformer,
Markus Handelle93fe6c2021-05-20 20:46:3151 rtc::scoped_refptr<FrameTransformerInterface>)
Jonas Oreland65455162022-06-08 09:25:4652PROXY_METHOD1(void,
53 SetEncoderSelector,
54 std::unique_ptr<VideoEncoderFactory::EncoderSelectorInterface>)
Markus Handell3d46d0b2021-05-27 19:42:5755END_PROXY_MAP(RtpSender)
Markus Handelle93fe6c2021-05-20 20:46:3156
57} // namespace webrtc
58
59#endif // PC_RTP_SENDER_PROXY_H_