wasapi: Increase rank to prefer over directsoundsrc
authorNirbheek Chauhan <nirbheek@centricular.com>
Thu, 1 Mar 2018 09:59:27 +0000 (15:29 +0530)
committerNirbheek Chauhan <nirbheek@centricular.com>
Thu, 1 Mar 2018 10:03:18 +0000 (15:33 +0530)
Directsoundsrc/sink have multiple issues, most of which cannot be
fixed at all because the API is deprecated and is implemented as a
compatibility wrapper around WASAPI since Vista.

Users and developers should now use the wasapisrc/sink elements, and
future development efforts should go towards that.

sys/directsound/gstdirectsoundplugin.c
sys/wasapi/gstwasapi.c

index 66d6c40..1c0f410 100644 (file)
@@ -35,7 +35,7 @@
 static gboolean
 plugin_init (GstPlugin * plugin)
 {
-  if (!gst_element_register (plugin, "directsoundsrc", GST_RANK_PRIMARY,
+  if (!gst_element_register (plugin, "directsoundsrc", GST_RANK_SECONDARY,
           GST_TYPE_DIRECTSOUND_SRC))
     return FALSE;
 
index 6669797..72ebd53 100644 (file)
@@ -1,5 +1,7 @@
 /*
  * Copyright (C) 2008 Ole André Vadla Ravnås <ole.andre.ravnas@tandberg.com>
+ * Copyright (C) 2018 Centricular Ltd.
+ *   Author: Nirbheek Chauhan <nirbheek@centricular.com>
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Library General Public
@@ -30,11 +32,11 @@ GST_DEBUG_CATEGORY (gst_wasapi_debug);
 static gboolean
 plugin_init (GstPlugin * plugin)
 {
-  if (!gst_element_register (plugin, "wasapisink", GST_RANK_NONE,
+  if (!gst_element_register (plugin, "wasapisink", GST_RANK_PRIMARY,
           GST_TYPE_WASAPI_SINK))
     return FALSE;
 
-  if (!gst_element_register (plugin, "wasapisrc", GST_RANK_NONE,
+  if (!gst_element_register (plugin, "wasapisrc", GST_RANK_PRIMARY,
           GST_TYPE_WASAPI_SRC))
     return FALSE;