ossu | 7bb87ee | 2017-01-23 04:56:25 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2016 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 Anton | 10542f2 | 2019-01-11 09:11:00 -0800 | [diff] [blame] | 11 | #ifndef API_MEDIA_TYPES_H_ |
| 12 | #define API_MEDIA_TYPES_H_ |
ossu | 7bb87ee | 2017-01-23 04:56:25 -0800 | [diff] [blame] | 13 | |
| 14 | #include <string> |
| 15 | |
Mirko Bonadei | 66e7679 | 2019-04-02 11:33:59 +0200 | [diff] [blame] | 16 | #include "rtc_base/system/rtc_export.h" |
| 17 | |
Patrik Höglund | b6b29e0 | 2018-06-21 16:58:01 +0200 | [diff] [blame] | 18 | // The cricket and webrtc have separate definitions for what a media type is. |
| 19 | // They're not compatible. Watch out for this. |
| 20 | |
ossu | 7bb87ee | 2017-01-23 04:56:25 -0800 | [diff] [blame] | 21 | namespace cricket { |
| 22 | |
Yves Gerey | 665174f | 2018-06-19 15:03:05 +0200 | [diff] [blame] | 23 | enum MediaType { MEDIA_TYPE_AUDIO, MEDIA_TYPE_VIDEO, MEDIA_TYPE_DATA }; |
ossu | 7bb87ee | 2017-01-23 04:56:25 -0800 | [diff] [blame] | 24 | |
Niels Möller | 6dcd4dc | 2019-08-26 10:45:28 +0200 | [diff] [blame] | 25 | extern const char kMediaTypeAudio[]; |
| 26 | extern const char kMediaTypeVideo[]; |
| 27 | extern const char kMediaTypeData[]; |
| 28 | |
Mirko Bonadei | 66e7679 | 2019-04-02 11:33:59 +0200 | [diff] [blame] | 29 | RTC_EXPORT std::string MediaTypeToString(MediaType type); |
ossu | 7bb87ee | 2017-01-23 04:56:25 -0800 | [diff] [blame] | 30 | |
| 31 | } // namespace cricket |
| 32 | |
Patrik Höglund | b6b29e0 | 2018-06-21 16:58:01 +0200 | [diff] [blame] | 33 | namespace webrtc { |
| 34 | |
| 35 | enum class MediaType { ANY, AUDIO, VIDEO, DATA }; |
| 36 | |
| 37 | } // namespace webrtc |
| 38 | |
Steve Anton | 10542f2 | 2019-01-11 09:11:00 -0800 | [diff] [blame] | 39 | #endif // API_MEDIA_TYPES_H_ |