OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 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 | 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 | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 23 matching lines...) Expand all Loading... | |
34 SdpAudioFormat(const char* name, | 34 SdpAudioFormat(const char* name, |
35 int clockrate_hz, | 35 int clockrate_hz, |
36 size_t num_channels, | 36 size_t num_channels, |
37 const Parameters& param); | 37 const Parameters& param); |
38 SdpAudioFormat(const std::string& name, | 38 SdpAudioFormat(const std::string& name, |
39 int clockrate_hz, | 39 int clockrate_hz, |
40 size_t num_channels, | 40 size_t num_channels, |
41 const Parameters& param); | 41 const Parameters& param); |
42 ~SdpAudioFormat(); | 42 ~SdpAudioFormat(); |
43 | 43 |
44 // Returns true if this format is compatible with |o|. In SDP terminology, | |
the sun
2017/04/26 07:44:10
super nit: end in ":", not ","
oh well... :)
Taylor Brandstetter
2017/04/26 23:04:40
Done.
| |
45 // would it represent the same codec between an offer and an answer? As | |
46 // opposed to operator==, this method disregards codec parameters. | |
47 bool Matches(const SdpAudioFormat& o) const; | |
the sun
2017/04/26 07:44:09
More importantly though, can we deprecate operator
Taylor Brandstetter
2017/04/26 23:04:40
It has some existing uses (decoder_database.cc and
| |
48 | |
44 SdpAudioFormat& operator=(const SdpAudioFormat&); | 49 SdpAudioFormat& operator=(const SdpAudioFormat&); |
45 SdpAudioFormat& operator=(SdpAudioFormat&&); | 50 SdpAudioFormat& operator=(SdpAudioFormat&&); |
46 | 51 |
47 friend bool operator==(const SdpAudioFormat& a, const SdpAudioFormat& b); | 52 friend bool operator==(const SdpAudioFormat& a, const SdpAudioFormat& b); |
48 friend bool operator!=(const SdpAudioFormat& a, const SdpAudioFormat& b) { | 53 friend bool operator!=(const SdpAudioFormat& a, const SdpAudioFormat& b) { |
49 return !(a == b); | 54 return !(a == b); |
50 } | 55 } |
51 | 56 |
52 std::string name; | 57 std::string name; |
53 int clockrate_hz; | 58 int clockrate_hz; |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
124 | 129 |
125 bool operator!=(const AudioCodecSpec& b) const { return !(*this == b); } | 130 bool operator!=(const AudioCodecSpec& b) const { return !(*this == b); } |
126 | 131 |
127 SdpAudioFormat format; | 132 SdpAudioFormat format; |
128 AudioCodecInfo info; | 133 AudioCodecInfo info; |
129 }; | 134 }; |
130 | 135 |
131 } // namespace webrtc | 136 } // namespace webrtc |
132 | 137 |
133 #endif // WEBRTC_API_AUDIO_CODECS_AUDIO_FORMAT_H_ | 138 #endif // WEBRTC_API_AUDIO_CODECS_AUDIO_FORMAT_H_ |
OLD | NEW |