X-Git-Url: https://git.stderr.nl/gitweb?a=blobdiff_plain;f=libchimara%2Fschannel.c;h=d2f88b80e1ed0aefb732065173adfd20673262eb;hb=10f6655d3991cd16366c7a5e2939b3e463df4dc2;hp=b30e1707096e7a213d132c1097e6ff42969ed046;hpb=1b067281939108ddb57ff521af71c7b829e55394;p=projects%2Fchimara%2Fchimara.git diff --git a/libchimara/schannel.c b/libchimara/schannel.c index b30e170..d2f88b8 100644 --- a/libchimara/schannel.c +++ b/libchimara/schannel.c @@ -155,7 +155,8 @@ on_type_found(GstElement *typefind, guint probability, GstCaps *caps, schanid_t WARNING(_("Could not link GStreamer elements")); goto finally; } - } else if(strcmp(type, "audio/x-mod") == 0) { + } else if(g_str_has_prefix(type, "audio/x-mod")) { + /* "audio/x-mod, type=(string)s3m" has been observed */ s->decode = gst_element_factory_make("modplug", NULL); if(!s->decode) { WARNING(_("Could not create 'modplug' GStreamer element")); @@ -763,13 +764,13 @@ glk_schannel_set_volume(schanid_t chan, glui32 vol) glk_schannel_set_volume_ext(chan, vol, 0, 0); } +#if defined(GSTREAMER_0_10_SOUND) || defined(GSTREAMER_1_0_SOUND) static double volume_glk_to_gstreamer(glui32 volume_glk) { return CLAMP(((double)volume_glk / 0x10000), 0.0, 10.0); } -#if defined(GSTREAMER_0_10_SOUND) || defined(GSTREAMER_1_0_SOUND) static gboolean volume_change_timeout(schanid_t chan) {