diff --git a/ext/libav/gstavauddec.c b/ext/libav/gstavauddec.c index d01ae3510c..a7befb231d 100644 --- a/ext/libav/gstavauddec.c +++ b/ext/libav/gstavauddec.c @@ -775,7 +775,8 @@ gst_ffmpegauddec_register (GstPlugin * plugin) gchar *plugin_name; /* only decoders */ - if (!in_plugin->decode || in_plugin->type != AVMEDIA_TYPE_AUDIO) { + if (!av_codec_is_decoder (in_plugin) + || in_plugin->type != AVMEDIA_TYPE_AUDIO) { goto next; } diff --git a/ext/libav/gstavaudenc.c b/ext/libav/gstavaudenc.c index e7588b0a2c..635655960d 100644 --- a/ext/libav/gstavaudenc.c +++ b/ext/libav/gstavaudenc.c @@ -589,7 +589,7 @@ gst_ffmpegaudenc_register (GstPlugin * plugin) } /* only encoders */ - if (!in_plugin->encode2) { + if (!av_codec_is_encoder (in_plugin)) { goto next; } diff --git a/ext/libav/gstavviddec.c b/ext/libav/gstavviddec.c index b763f94426..279b74dbe1 100644 --- a/ext/libav/gstavviddec.c +++ b/ext/libav/gstavviddec.c @@ -1621,7 +1621,8 @@ gst_ffmpegviddec_register (GstPlugin * plugin) gchar *plugin_name; /* only video decoders */ - if (!in_plugin->decode || in_plugin->type != AVMEDIA_TYPE_VIDEO) + if (!av_codec_is_decoder (in_plugin) + || in_plugin->type != AVMEDIA_TYPE_VIDEO) goto next; /* no quasi-codecs, please */ diff --git a/ext/libav/gstavvidenc.c b/ext/libav/gstavvidenc.c index 8dd5a0db94..807da6854f 100644 --- a/ext/libav/gstavvidenc.c +++ b/ext/libav/gstavvidenc.c @@ -981,7 +981,8 @@ gst_ffmpegvidenc_register (GstPlugin * plugin) } /* only video encoders */ - if (!in_plugin->encode2 || in_plugin->type != AVMEDIA_TYPE_VIDEO) + if (!av_codec_is_encoder (in_plugin) + || in_plugin->type != AVMEDIA_TYPE_VIDEO) goto next; /* FIXME : We should have a method to know cheaply whether we have a mapping