diff options
Diffstat (limited to 'src/plugins/gstreamer/mediaplayer/qgstreamerplayerserviceplugin.cpp')
-rw-r--r-- | src/plugins/gstreamer/mediaplayer/qgstreamerplayerserviceplugin.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/plugins/gstreamer/mediaplayer/qgstreamerplayerserviceplugin.cpp b/src/plugins/gstreamer/mediaplayer/qgstreamerplayerserviceplugin.cpp index 004d561ae..b895c4d86 100644 --- a/src/plugins/gstreamer/mediaplayer/qgstreamerplayerserviceplugin.cpp +++ b/src/plugins/gstreamer/mediaplayer/qgstreamerplayerserviceplugin.cpp @@ -83,8 +83,15 @@ QMultimedia::SupportEstimate QGstreamerPlayerServicePlugin::hasSupport(const QSt static bool isDecoderOrDemuxer(GstElementFactory *factory) { +#if GST_CHECK_VERSION(0, 10 ,31) return gst_element_factory_list_is_type(factory, GST_ELEMENT_FACTORY_TYPE_DEMUXER) || gst_element_factory_list_is_type(factory, GST_ELEMENT_FACTORY_TYPE_DECODER); +#else + return (factory + && (qstrcmp(factory->details.klass, "Codec/Decoder/Audio") == 0 + || qstrcmp(factory->details.klass, "Codec/Decoder/Video") == 0 + || qstrcmp(factory->details.klass, "Codec/Demux") == 0 )); +#endif } void QGstreamerPlayerServicePlugin::updateSupportedMimeTypes() const |