blob: 620f1ca1727c7e3761f3f8cd08761f79602f4f1c [file] [log] [blame]
perkj@webrtc.org81134d02015-01-12 08:30:16 +00001/*
kjellanderb24317b2016-02-10 07:54:43 -08002 * Copyright 2014 The WebRTC project authors. All Rights Reserved.
perkj@webrtc.org81134d02015-01-12 08:30:16 +00003 *
kjellanderb24317b2016-02-10 07:54:43 -08004 * 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.
perkj@webrtc.org81134d02015-01-12 08:30:16 +00009 */
jlmiller@webrtc.org5f93d0a2015-01-20 21:36:13 +000010
Steve Anton10542f22019-01-11 09:11:00 -080011#ifndef API_PEER_CONNECTION_FACTORY_PROXY_H_
12#define API_PEER_CONNECTION_FACTORY_PROXY_H_
perkj@webrtc.org81134d02015-01-12 08:30:16 +000013
kwibergd1fe2812016-04-27 06:47:29 -070014#include <memory>
perkj@webrtc.org81134d02015-01-12 08:30:16 +000015#include <string>
kwiberg0eb15ed2015-12-17 03:04:15 -080016#include <utility>
perkj@webrtc.org81134d02015-01-12 08:30:16 +000017
Steve Anton10542f22019-01-11 09:11:00 -080018#include "api/peer_connection_interface.h"
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020019#include "api/proxy.h"
20#include "rtc_base/bind.h"
perkj@webrtc.org81134d02015-01-12 08:30:16 +000021
22namespace webrtc {
23
deadbeefb10f32f2017-02-08 01:38:21 -080024// TODO(deadbeef): Move this to .cc file and out of api/. What threads methods
25// are called on is an implementation detail.
nisse72c8d2b2016-04-15 03:49:07 -070026BEGIN_SIGNALING_PROXY_MAP(PeerConnectionFactory)
Yves Gerey665174f2018-06-19 15:03:05 +020027PROXY_SIGNALING_THREAD_DESTRUCTOR()
Yves Gerey665174f2018-06-19 15:03:05 +020028PROXY_METHOD1(void, SetOptions, const Options&)
Yves Gerey665174f2018-06-19 15:03:05 +020029PROXY_METHOD4(rtc::scoped_refptr<PeerConnectionInterface>,
30 CreatePeerConnection,
31 const PeerConnectionInterface::RTCConfiguration&,
32 std::unique_ptr<cricket::PortAllocator>,
33 std::unique_ptr<rtc::RTCCertificateGeneratorInterface>,
Nico Weber22f99252019-02-20 10:13:16 -050034 PeerConnectionObserver*)
Yves Gerey665174f2018-06-19 15:03:05 +020035PROXY_METHOD2(rtc::scoped_refptr<PeerConnectionInterface>,
36 CreatePeerConnection,
37 const PeerConnectionInterface::RTCConfiguration&,
Nico Weber22f99252019-02-20 10:13:16 -050038 PeerConnectionDependencies)
Florent Castelli72b751a2018-06-28 14:09:33 +020039PROXY_CONSTMETHOD1(webrtc::RtpCapabilities,
40 GetRtpSenderCapabilities,
Nico Weber22f99252019-02-20 10:13:16 -050041 cricket::MediaType)
Florent Castelli72b751a2018-06-28 14:09:33 +020042PROXY_CONSTMETHOD1(webrtc::RtpCapabilities,
43 GetRtpReceiverCapabilities,
Nico Weber22f99252019-02-20 10:13:16 -050044 cricket::MediaType)
Yves Gerey665174f2018-06-19 15:03:05 +020045PROXY_METHOD1(rtc::scoped_refptr<MediaStreamInterface>,
46 CreateLocalMediaStream,
47 const std::string&)
48PROXY_METHOD1(rtc::scoped_refptr<AudioSourceInterface>,
49 CreateAudioSource,
50 const cricket::AudioOptions&)
Yves Gerey665174f2018-06-19 15:03:05 +020051PROXY_METHOD2(rtc::scoped_refptr<VideoTrackInterface>,
52 CreateVideoTrack,
53 const std::string&,
54 VideoTrackSourceInterface*)
55PROXY_METHOD2(rtc::scoped_refptr<AudioTrackInterface>,
56 CreateAudioTrack,
57 const std::string&,
58 AudioSourceInterface*)
59PROXY_METHOD2(bool, StartAecDump, rtc::PlatformFile, int64_t)
60PROXY_METHOD0(void, StopAecDump)
deadbeefd99a2002017-01-18 08:55:23 -080061END_PROXY_MAP()
perkj@webrtc.org81134d02015-01-12 08:30:16 +000062
63} // namespace webrtc
64
Steve Anton10542f22019-01-11 09:11:00 -080065#endif // API_PEER_CONNECTION_FACTORY_PROXY_H_