mirror of
https://github.com/strawberrymusicplayer/strawberry
synced 2025-01-28 16:20:26 +01:00
Use directsoundsink by default because of buggy wasapi plugin
This commit is contained in:
parent
db312a7380
commit
e78bb1b29c
@ -61,6 +61,21 @@ void GstStartup::InitializeGStreamer() {
|
|||||||
gstfastspectrum_register_static();
|
gstfastspectrum_register_static();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef Q_OS_WIN32
|
||||||
|
// Use directsoundsink by default because of buggy wasapi plugin.
|
||||||
|
GstRegistry *reg = gst_registry_get();
|
||||||
|
if (reg) {
|
||||||
|
GstPluginFeature *directsoundsink = gst_registry_lookup_feature(reg, "directsoundsink");
|
||||||
|
GstPluginFeature *wasapisink = gst_registry_lookup_feature(reg, "wasapisink");
|
||||||
|
if (directsoundsink && wasapisink) {
|
||||||
|
gst_plugin_feature_set_rank(directsoundsink, GST_RANK_PRIMARY);
|
||||||
|
gst_plugin_feature_set_rank(wasapisink, GST_RANK_SECONDARY);
|
||||||
|
}
|
||||||
|
if (directsoundsink) gst_object_unref(directsoundsink);
|
||||||
|
if (wasapisink) gst_object_unref(wasapisink);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void GstStartup::SetEnvironment() {
|
void GstStartup::SetEnvironment() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user