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 11 #ifndef API_MEDIA_TYPES_H_ 12 #define API_MEDIA_TYPES_H_ 13 14 #include <string> 15 16 #include "rtc_base/system/rtc_export.h" 17 18 // The cricket and webrtc have separate definitions for what a media type is. 19 // They're not compatible. Watch out for this. 20 21 namespace cricket { 22 23 enum MediaType { 24 MEDIA_TYPE_AUDIO, 25 MEDIA_TYPE_VIDEO, 26 MEDIA_TYPE_DATA, 27 MEDIA_TYPE_UNSUPPORTED 28 }; 29 30 extern const char kMediaTypeAudio[]; 31 extern const char kMediaTypeVideo[]; 32 extern const char kMediaTypeData[]; 33 34 RTC_EXPORT std::string MediaTypeToString(MediaType type); 35 36 } // namespace cricket 37 38 namespace webrtc { 39 40 enum class MediaType { ANY, AUDIO, VIDEO, DATA }; 41 42 } // namespace webrtc 43 44 #endif // API_MEDIA_TYPES_H_ 45