d3d11videoprocessor: Disable auto processing mode explicitly
authorSeungha Yang <seungha@centricular.com>
Tue, 2 Mar 2021 09:07:36 +0000 (18:07 +0900)
committerSeungha Yang <seungha@centricular.com>
Tue, 2 Mar 2021 14:10:47 +0000 (23:10 +0900)
Don't allow auto processing (e.g., denoising), as it might result
in unexpected output.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2051>

sys/d3d11/gstd3d11videoprocessor.c

index 380e5d2..4cf54af 100644 (file)
@@ -130,6 +130,13 @@ gst_d3d11_video_processor_new (GstD3D11Device * device, guint in_width,
   }
 #endif
 
+  /* Setting up default options */
+  gst_d3d11_device_lock (self->device);
+  /* We don't want auto processing by driver */
+  ID3D11VideoContext_VideoProcessorSetStreamAutoProcessingMode
+      (self->video_context, self->processor, 0, FALSE);
+  gst_d3d11_device_unlock (self->device);
+
   return self;
 
 fail: