When VAAPI based encoder is used it's likely that also VAAPI based
conversion is available (using the vaapipostproc element).
Moving to autovideoconvert will automatically choose a suitable
convert element according to elements availability (e.g. in the
VAAPI case it would select vaapipostproc due to its high rank).

Signed-off-by: Snir Sheriber <[email protected]>
Acked-by: Frediano Ziglio <[email protected]>
---
Basically Acked, for the record I'm sending it again with the minor changes
---
 src/gst-plugin.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/gst-plugin.cpp b/src/gst-plugin.cpp
index 0dd7796..3887b47 100644
--- a/src/gst-plugin.cpp
+++ b/src/gst-plugin.cpp
@@ -216,9 +216,9 @@ void GstreamerFrameCapture::pipeline_init(const 
GstreamerEncoderSettings &settin
     if (!capture) {
         throw std::runtime_error("Gstreamer's capture element cannot be 
created");
     }
-    GstObjectUPtr<GstElement> convert(gst_element_factory_make("videoconvert", 
"convert"));
+    GstObjectUPtr<GstElement> 
convert(gst_element_factory_make("autovideoconvert", "convert"));
     if (!convert) {
-        throw std::runtime_error("Gstreamer's 'videoconvert' element cannot be 
created");
+        throw std::runtime_error("Gstreamer's 'autovideoconvert' element 
cannot be created");
     }
     GstCapsUPtr sink_caps;
     GstObjectUPtr<GstElement> encoder(get_encoder_plugin(settings, sink_caps));
-- 
2.21.0

_______________________________________________
Spice-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/spice-devel

Reply via email to