videoparsers: Only fail to initialize the plugin if all parsers can't be registered

This commit is contained in:
Sebastian Dröge 2011-10-04 12:31:05 +02:00
parent 21653a793a
commit 8e2c5833f1

View File

@ -30,15 +30,15 @@
static gboolean static gboolean
plugin_init (GstPlugin * plugin) plugin_init (GstPlugin * plugin)
{ {
gboolean ret; gboolean ret = FALSE;
ret = gst_element_register (plugin, "h263parse", ret |= gst_element_register (plugin, "h263parse",
GST_RANK_PRIMARY + 1, GST_TYPE_H263_PARSE); GST_RANK_PRIMARY + 1, GST_TYPE_H263_PARSE);
ret = gst_element_register (plugin, "h264parse", ret |= gst_element_register (plugin, "h264parse",
GST_RANK_PRIMARY + 1, GST_TYPE_H264_PARSE); GST_RANK_PRIMARY + 1, GST_TYPE_H264_PARSE);
ret = gst_element_register (plugin, "diracparse", ret |= gst_element_register (plugin, "diracparse",
GST_RANK_NONE, GST_TYPE_DIRAC_PARSE); GST_RANK_NONE, GST_TYPE_DIRAC_PARSE);
ret = gst_element_register (plugin, "mpegvideoparse", ret |= gst_element_register (plugin, "mpegvideoparse",
GST_RANK_PRIMARY + 1, GST_TYPE_MPEGVIDEO_PARSE); GST_RANK_PRIMARY + 1, GST_TYPE_MPEGVIDEO_PARSE);
return ret; return ret;