OLD | NEW |
1 /* | 1 /* |
2 * libjingle | 2 * libjingle |
3 * Copyright 2014 Google Inc. | 3 * Copyright 2014 Google Inc. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are met: | 6 * modification, are permitted provided that the following conditions are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright notice, | 8 * 1. Redistributions of source code must retain the above copyright notice, |
9 * this list of conditions and the following disclaimer. | 9 * this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright notice, | 10 * 2. Redistributions in binary form must reproduce the above copyright notice, |
(...skipping 1750 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1761 CreateVideoEncoderConfig(last_dimensions_, codec_settings.codec); | 1761 CreateVideoEncoderConfig(last_dimensions_, codec_settings.codec); |
1762 RTC_DCHECK(!parameters_.encoder_config.streams.empty()); | 1762 RTC_DCHECK(!parameters_.encoder_config.streams.empty()); |
1763 | 1763 |
1764 format_ = VideoFormat(codec_settings.codec.width, | 1764 format_ = VideoFormat(codec_settings.codec.width, |
1765 codec_settings.codec.height, | 1765 codec_settings.codec.height, |
1766 VideoFormat::FpsToInterval(30), | 1766 VideoFormat::FpsToInterval(30), |
1767 FOURCC_I420); | 1767 FOURCC_I420); |
1768 | 1768 |
1769 AllocatedEncoder new_encoder = CreateVideoEncoder(codec_settings.codec); | 1769 AllocatedEncoder new_encoder = CreateVideoEncoder(codec_settings.codec); |
1770 parameters_.config.encoder_settings.encoder = new_encoder.encoder; | 1770 parameters_.config.encoder_settings.encoder = new_encoder.encoder; |
| 1771 parameters_.config.encoder_settings.full_overuse_time = new_encoder.external; |
1771 parameters_.config.encoder_settings.payload_name = codec_settings.codec.name; | 1772 parameters_.config.encoder_settings.payload_name = codec_settings.codec.name; |
1772 parameters_.config.encoder_settings.payload_type = codec_settings.codec.id; | 1773 parameters_.config.encoder_settings.payload_type = codec_settings.codec.id; |
1773 if (new_encoder.external) { | 1774 if (new_encoder.external) { |
1774 webrtc::VideoCodecType type = CodecTypeFromName(codec_settings.codec.name); | 1775 webrtc::VideoCodecType type = CodecTypeFromName(codec_settings.codec.name); |
1775 parameters_.config.encoder_settings.internal_source = | 1776 parameters_.config.encoder_settings.internal_source = |
1776 external_encoder_factory_->EncoderTypeHasInternalSource(type); | 1777 external_encoder_factory_->EncoderTypeHasInternalSource(type); |
1777 } | 1778 } |
1778 parameters_.config.rtp.fec = codec_settings.fec; | 1779 parameters_.config.rtp.fec = codec_settings.fec; |
1779 | 1780 |
1780 // Set RTX payload type if RTX is enabled. | 1781 // Set RTX payload type if RTX is enabled. |
(...skipping 746 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2527 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; | 2528 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; |
2528 } | 2529 } |
2529 } | 2530 } |
2530 | 2531 |
2531 return video_codecs; | 2532 return video_codecs; |
2532 } | 2533 } |
2533 | 2534 |
2534 } // namespace cricket | 2535 } // namespace cricket |
2535 | 2536 |
2536 #endif // HAVE_WEBRTC_VIDEO | 2537 #endif // HAVE_WEBRTC_VIDEO |
OLD | NEW |