Populate sdp_fmtp_line and channels of RTCCodecStats

Change RtpCodecCapability::parameters and RtpCodecParameters::parameters
to map from unordered_map to get welldefined FMTP lines.

Bug: webrtc:7061
Change-Id: Ie61f76bbab915d72369e36e3f40ea11838827940
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/168190
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Johannes Kron <kron@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#30512}
This commit is contained in:
Johannes Kron
2020-02-10 14:05:55 +01:00
committed by Commit Bot
parent b28e57e725
commit 72d6915d5f
8 changed files with 65 additions and 43 deletions

View File

@ -13,8 +13,8 @@
#include <stdint.h>
#include <map>
#include <string>
#include <unordered_map>
#include <vector>
#include "absl/types/optional.h"
@ -157,12 +157,12 @@ struct RTC_EXPORT RtpCodecCapability {
// Contrary to ORTC, these parameters are named using all lowercase strings.
// This helps make the mapping to SDP simpler, if an application is using SDP.
// Boolean values are represented by the string "1".
std::unordered_map<std::string, std::string> parameters;
std::map<std::string, std::string> parameters;
// Codec-specific parameters that may optionally be signaled to the remote
// party.
// TODO(deadbeef): Not implemented.
std::unordered_map<std::string, std::string> options;
std::map<std::string, std::string> options;
// Maximum number of temporal layer extensions supported by this codec.
// For example, a value of 1 indicates that 2 total layers are supported.
@ -500,7 +500,7 @@ struct RTC_EXPORT RtpCodecParameters {
// Contrary to ORTC, these parameters are named using all lowercase strings.
// This helps make the mapping to SDP simpler, if an application is using SDP.
// Boolean values are represented by the string "1".
std::unordered_map<std::string, std::string> parameters;
std::map<std::string, std::string> parameters;
bool operator==(const RtpCodecParameters& o) const {
return name == o.name && kind == o.kind && payload_type == o.payload_type &&