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 1876 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1887 if (parameters_.encoder_config.streams.empty()) | 1887 if (parameters_.encoder_config.streams.empty()) |
1888 return; | 1888 return; |
1889 | 1889 |
1890 format_ = VideoFormat(codec_settings.codec.width, | 1890 format_ = VideoFormat(codec_settings.codec.width, |
1891 codec_settings.codec.height, | 1891 codec_settings.codec.height, |
1892 VideoFormat::FpsToInterval(30), | 1892 VideoFormat::FpsToInterval(30), |
1893 FOURCC_I420); | 1893 FOURCC_I420); |
1894 | 1894 |
1895 AllocatedEncoder new_encoder = CreateVideoEncoder(codec_settings.codec); | 1895 AllocatedEncoder new_encoder = CreateVideoEncoder(codec_settings.codec); |
1896 parameters_.config.encoder_settings.encoder = new_encoder.encoder; | 1896 parameters_.config.encoder_settings.encoder = new_encoder.encoder; |
| 1897 parameters_.config.encoder_settings.full_overuse_time = new_encoder.external; |
1897 parameters_.config.encoder_settings.payload_name = codec_settings.codec.name; | 1898 parameters_.config.encoder_settings.payload_name = codec_settings.codec.name; |
1898 parameters_.config.encoder_settings.payload_type = codec_settings.codec.id; | 1899 parameters_.config.encoder_settings.payload_type = codec_settings.codec.id; |
1899 if (new_encoder.external) { | 1900 if (new_encoder.external) { |
1900 webrtc::VideoCodecType type = CodecTypeFromName(codec_settings.codec.name); | 1901 webrtc::VideoCodecType type = CodecTypeFromName(codec_settings.codec.name); |
1901 parameters_.config.encoder_settings.internal_source = | 1902 parameters_.config.encoder_settings.internal_source = |
1902 external_encoder_factory_->EncoderTypeHasInternalSource(type); | 1903 external_encoder_factory_->EncoderTypeHasInternalSource(type); |
1903 } | 1904 } |
1904 parameters_.config.rtp.fec = codec_settings.fec; | 1905 parameters_.config.rtp.fec = codec_settings.fec; |
1905 | 1906 |
1906 // Set RTX payload type if RTX is enabled. | 1907 // Set RTX payload type if RTX is enabled. |
(...skipping 756 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2663 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; | 2664 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; |
2664 } | 2665 } |
2665 } | 2666 } |
2666 | 2667 |
2667 return video_codecs; | 2668 return video_codecs; |
2668 } | 2669 } |
2669 | 2670 |
2670 } // namespace cricket | 2671 } // namespace cricket |
2671 | 2672 |
2672 #endif // HAVE_WEBRTC_VIDEO | 2673 #endif // HAVE_WEBRTC_VIDEO |
OLD | NEW |