Calls: Use vp8depay.wait-for-keyframe only with GStreamer 1.16+

This commit is contained in:
Marvin W 2021-05-11 22:10:17 +02:00
parent d71604913d
commit 3bfd407843
No known key found for this signature in database
GPG Key ID: 072E9235DB996F2A
1 changed files with 3 additions and 1 deletions

View File

@ -206,7 +206,9 @@ public class Dino.Plugins.Rtp.CodecUtil {
}
public static string? get_depay_args(string media, string codec, string encode, JingleRtp.PayloadType? payload_type) {
#if GST_1_16
if (codec == "vp8") return " wait-for-keyframe=true";
#endif
return null;
}
@ -271,7 +273,7 @@ public class Dino.Plugins.Rtp.CodecUtil {
public Gst.Element? get_decode_bin(string media, JingleRtp.PayloadType payload_type, string? name = null) {
string? codec = get_codec_from_payload(media, payload_type);
string base_name = name ?? @"encode-$codec-$(Random.next_int())";
string base_name = name ?? @"decode_$(codec)_$(Random.next_int())";
string? desc = get_decode_bin_description(media, codec, payload_type, null, base_name);
if (desc == null) return null;
debug("Pipeline to decode %s %s: %s", media, codec, desc);