OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2014 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 1571 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1582 if (flexfec_enabled) { | 1582 if (flexfec_enabled) { |
1583 LOG(LS_INFO) << "Multiple FlexFEC streams proposed by remote, but " | 1583 LOG(LS_INFO) << "Multiple FlexFEC streams proposed by remote, but " |
1584 "our implementation only supports a single FlexFEC " | 1584 "our implementation only supports a single FlexFEC " |
1585 "stream. Will not enable FlexFEC for proposed " | 1585 "stream. Will not enable FlexFEC for proposed " |
1586 "stream with SSRC: " | 1586 "stream with SSRC: " |
1587 << flexfec_ssrc << "."; | 1587 << flexfec_ssrc << "."; |
1588 continue; | 1588 continue; |
1589 } | 1589 } |
1590 | 1590 |
1591 flexfec_enabled = true; | 1591 flexfec_enabled = true; |
1592 parameters_.config.rtp.flexfec.flexfec_ssrc = flexfec_ssrc; | 1592 parameters_.config.rtp.flexfec.ssrc = flexfec_ssrc; |
1593 parameters_.config.rtp.flexfec.protected_media_ssrcs = {primary_ssrc}; | 1593 parameters_.config.rtp.flexfec.protected_media_ssrcs = {primary_ssrc}; |
1594 } | 1594 } |
1595 } | 1595 } |
1596 } | 1596 } |
1597 | 1597 |
1598 parameters_.config.rtp.c_name = sp.cname; | 1598 parameters_.config.rtp.c_name = sp.cname; |
1599 if (rtp_extensions) { | 1599 if (rtp_extensions) { |
1600 parameters_.config.rtp.extensions = *rtp_extensions; | 1600 parameters_.config.rtp.extensions = *rtp_extensions; |
1601 } | 1601 } |
1602 parameters_.config.rtp.rtcp_mode = send_params.rtcp.reduced_size | 1602 parameters_.config.rtp.rtcp_mode = send_params.rtcp.reduced_size |
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1770 parameters_.config.encoder_settings.payload_name = codec_settings.codec.name; | 1770 parameters_.config.encoder_settings.payload_name = codec_settings.codec.name; |
1771 parameters_.config.encoder_settings.payload_type = codec_settings.codec.id; | 1771 parameters_.config.encoder_settings.payload_type = codec_settings.codec.id; |
1772 if (new_encoder.external) { | 1772 if (new_encoder.external) { |
1773 webrtc::VideoCodecType type = | 1773 webrtc::VideoCodecType type = |
1774 webrtc::PayloadNameToCodecType(codec_settings.codec.name) | 1774 webrtc::PayloadNameToCodecType(codec_settings.codec.name) |
1775 .value_or(webrtc::kVideoCodecUnknown); | 1775 .value_or(webrtc::kVideoCodecUnknown); |
1776 parameters_.config.encoder_settings.internal_source = | 1776 parameters_.config.encoder_settings.internal_source = |
1777 external_encoder_factory_->EncoderTypeHasInternalSource(type); | 1777 external_encoder_factory_->EncoderTypeHasInternalSource(type); |
1778 } | 1778 } |
1779 parameters_.config.rtp.ulpfec = codec_settings.ulpfec; | 1779 parameters_.config.rtp.ulpfec = codec_settings.ulpfec; |
1780 parameters_.config.rtp.flexfec.flexfec_payload_type = | 1780 parameters_.config.rtp.flexfec.payload_type = |
1781 codec_settings.flexfec_payload_type; | 1781 codec_settings.flexfec_payload_type; |
1782 | 1782 |
1783 // Set RTX payload type if RTX is enabled. | 1783 // Set RTX payload type if RTX is enabled. |
1784 if (!parameters_.config.rtp.rtx.ssrcs.empty()) { | 1784 if (!parameters_.config.rtp.rtx.ssrcs.empty()) { |
1785 if (codec_settings.rtx_payload_type == -1) { | 1785 if (codec_settings.rtx_payload_type == -1) { |
1786 LOG(LS_WARNING) << "RTX SSRCs configured but there's no configured RTX " | 1786 LOG(LS_WARNING) << "RTX SSRCs configured but there's no configured RTX " |
1787 "payload type. Ignoring."; | 1787 "payload type. Ignoring."; |
1788 parameters_.config.rtp.rtx.ssrcs.clear(); | 1788 parameters_.config.rtp.rtx.ssrcs.clear(); |
1789 } else { | 1789 } else { |
1790 parameters_.config.rtp.rtx.payload_type = codec_settings.rtx_payload_type; | 1790 parameters_.config.rtp.rtx.payload_type = codec_settings.rtx_payload_type; |
(...skipping 786 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2577 rtx_mapping[video_codecs[i].codec.id] != | 2577 rtx_mapping[video_codecs[i].codec.id] != |
2578 ulpfec_config.red_payload_type) { | 2578 ulpfec_config.red_payload_type) { |
2579 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; | 2579 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; |
2580 } | 2580 } |
2581 } | 2581 } |
2582 | 2582 |
2583 return video_codecs; | 2583 return video_codecs; |
2584 } | 2584 } |
2585 | 2585 |
2586 } // namespace cricket | 2586 } // namespace cricket |
OLD | NEW |