Mirko Bonadei | 3cf8f3e | 2018-11-19 09:17:51 +0100 | [diff] [blame] | 1 | /* |
| 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 | |
| 11 | #ifndef API_CREATE_PEERCONNECTION_FACTORY_H_ |
| 12 | #define API_CREATE_PEERCONNECTION_FACTORY_H_ |
| 13 | |
Mirko Bonadei | 2ff3f49 | 2018-11-22 09:00:13 +0100 | [diff] [blame] | 14 | #include <memory> |
| 15 | |
| 16 | #include "api/audio/audio_mixer.h" |
| 17 | #include "api/audio_codecs/audio_decoder_factory.h" |
| 18 | #include "api/audio_codecs/audio_encoder_factory.h" |
Steve Anton | 10542f2 | 2019-01-11 09:11:00 -0800 | [diff] [blame] | 19 | #include "api/peer_connection_interface.h" |
Mirko Bonadei | d970807 | 2019-01-25 20:26:48 +0100 | [diff] [blame] | 20 | #include "api/scoped_refptr.h" |
Danil Chapovalov | 5bf5806 | 2019-06-18 16:43:37 +0200 | [diff] [blame] | 21 | #include "api/video_codecs/video_decoder_factory.h" |
| 22 | #include "api/video_codecs/video_encoder_factory.h" |
Mirko Bonadei | 2ff3f49 | 2018-11-22 09:00:13 +0100 | [diff] [blame] | 23 | |
Mirko Bonadei | c5095e5 | 2018-11-26 19:25:05 +0100 | [diff] [blame] | 24 | namespace rtc { |
| 25 | // TODO(bugs.webrtc.org/9987): Move rtc::Thread to api/ or expose a better |
| 26 | // type. At the moment, rtc::Thread is not part of api/ so it cannot be |
| 27 | // included in order to avoid to leak internal types. |
| 28 | class Thread; |
| 29 | } // namespace rtc |
| 30 | |
Mirko Bonadei | 2ff3f49 | 2018-11-22 09:00:13 +0100 | [diff] [blame] | 31 | namespace webrtc { |
| 32 | |
| 33 | class AudioDeviceModule; |
| 34 | class AudioProcessing; |
Mirko Bonadei | 2ff3f49 | 2018-11-22 09:00:13 +0100 | [diff] [blame] | 35 | |
Mirko Bonadei | 2ff3f49 | 2018-11-22 09:00:13 +0100 | [diff] [blame] | 36 | // Create a new instance of PeerConnectionFactoryInterface with optional video |
| 37 | // codec factories. These video factories represents all video codecs, i.e. no |
| 38 | // extra internal video codecs will be added. |
Mirko Bonadei | 2ff3f49 | 2018-11-22 09:00:13 +0100 | [diff] [blame] | 39 | RTC_EXPORT rtc::scoped_refptr<PeerConnectionFactoryInterface> |
| 40 | CreatePeerConnectionFactory( |
| 41 | rtc::Thread* network_thread, |
| 42 | rtc::Thread* worker_thread, |
| 43 | rtc::Thread* signaling_thread, |
| 44 | rtc::scoped_refptr<AudioDeviceModule> default_adm, |
| 45 | rtc::scoped_refptr<AudioEncoderFactory> audio_encoder_factory, |
| 46 | rtc::scoped_refptr<AudioDecoderFactory> audio_decoder_factory, |
| 47 | std::unique_ptr<VideoEncoderFactory> video_encoder_factory, |
| 48 | std::unique_ptr<VideoDecoderFactory> video_decoder_factory, |
| 49 | rtc::scoped_refptr<AudioMixer> audio_mixer, |
| 50 | rtc::scoped_refptr<AudioProcessing> audio_processing); |
| 51 | |
Mirko Bonadei | 2ff3f49 | 2018-11-22 09:00:13 +0100 | [diff] [blame] | 52 | } // namespace webrtc |
Mirko Bonadei | 3cf8f3e | 2018-11-19 09:17:51 +0100 | [diff] [blame] | 53 | |
| 54 | #endif // API_CREATE_PEERCONNECTION_FACTORY_H_ |