[Spice-devel] [PATCH 1/2] gstreamer-encoder: Use NV12 as the default vpp conversion format

Vivek Kasireddy vivek.kasireddy at intel.com
Fri Sep 15 00:12:11 UTC 2023


From: Hazwan Arif Mazlan <hazwan.arif.mazlan at intel.com>

Using NV12 as the output format for the videoconvert element would
allow us to pair a s/w based encoder with a h/w based decoder for
decoding the stream as most h/w based decoders only accept NV12 as
the input format given its popularity.

Cc: Frediano Ziglio <freddy77 at gmail.com>
Cc: Dongwon Kim <dongwon.kim at intel.com>
Signed-off-by: Hazwan Arif Mazlan <hazwan.arif.mazlan at intel.com>
Signed-off-by: Jin Chung Teng <jin.chung.teng at intel.com>
Signed-off-by: Vivek Kasireddy <vivek.kasireddy at intel.com>
---
 server/gstreamer-encoder.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/server/gstreamer-encoder.c b/server/gstreamer-encoder.c
index d8af91f1..057509b5 100644
--- a/server/gstreamer-encoder.c
+++ b/server/gstreamer-encoder.c
@@ -918,7 +918,7 @@ static gboolean create_pipeline(SpiceGstEncoder *encoder)
 #ifdef HAVE_GSTREAMER_0_10
     const gchar *converter = "ffmpegcolorspace";
 #else
-    const gchar *converter = "videoconvert";
+    const gchar *converter = "videoconvert ! video/x-raw,format=NV12";
 #endif
     const gchar* gstenc_name = get_gst_codec_name(encoder);
     if (!gstenc_name) {
-- 
2.39.2



More information about the Spice-devel mailing list