[gnome-network-displays] wfd: Allow both baseline and constrained-baseline
- From: Benjamin Berg <bberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-network-displays] wfd: Allow both baseline and constrained-baseline
- Date: Thu, 8 Apr 2021 11:45:53 +0000 (UTC)
commit bff09df2bff9f555b9e3e9c51e998ad20baf172d
Author: Benjamin Berg <bberg redhat com>
Date: Wed Apr 7 16:21:14 2021 +0200
wfd: Allow both baseline and constrained-baseline
The "baseline" H264 profile may not be implemented by all encoders. Be
flexible, and permit both baseline and constrained-baseline.
Closes: #180
src/wfd/wfd-media-factory.c | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
---
diff --git a/src/wfd/wfd-media-factory.c b/src/wfd/wfd-media-factory.c
index 874d8de..88e783d 100644
--- a/src/wfd/wfd-media-factory.c
+++ b/src/wfd/wfd-media-factory.c
@@ -300,6 +300,10 @@ wfd_media_factory_create_element (GstRTSPMediaFactory *factory, const GstRTSPUrl
"config-interval", (gint) - 1,
NULL);
+ /* Permit both constrained-baseline and baseline. Would constrained-baseline be sufficient? */
+ caps = gst_caps_from_string
("video/x-h264,alignment=nal,stream-format=byte-stream,profile=constrained-baseline");
+ gst_caps_append (caps,
+ gst_caps_from_string
("video/x-h264,alignment=nal,stream-format=byte-stream,profile=baseline"));
caps = gst_caps_from_string ("video/x-h264,alignment=nal,stream-format=byte-stream,profile=baseline");
codecfilter = gst_element_factory_make ("capsfilter", "wfd-codecfilter");
g_object_set (codecfilter,
@@ -643,9 +647,16 @@ wfd_configure_media_element (GstBin *bin, WfdParams *params)
}
if (profile == WFD_H264_PROFILE_HIGH)
- caps_codecfilter = gst_caps_from_string
("video/x-h264,alignment=nal,stream-format=byte-stream,profile=high");
+ {
+ caps_codecfilter = gst_caps_from_string
("video/x-h264,alignment=nal,stream-format=byte-stream,profile=high");
+ }
else
- caps_codecfilter = gst_caps_from_string
("video/x-h264,alignment=nal,stream-format=byte-stream,profile=baseline");
+ {
+ /* Permit both constrained-baseline and baseline. Would constrained-baseline be sufficient? */
+ caps_codecfilter = gst_caps_from_string
("video/x-h264,alignment=nal,stream-format=byte-stream,profile=constrained-baseline");
+ gst_caps_append (caps_codecfilter,
+ gst_caps_from_string
("video/x-h264,alignment=nal,stream-format=byte-stream,profile=baseline"));
+ }
codecfilter = gst_bin_get_by_name (bin, "wfd-codecfilter");
g_object_set (codecfilter,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]