mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 16:50:47 +00:00
ext/cdio/: Fix build for libcdio versions >= 76; give slightly lower rank than cdparanoia.
Original commit message from CVS: * ext/cdio/gstcdio.c: (gst_cdio_add_cdtext_field), (plugin_init): * ext/cdio/gstcdio.h: * ext/cdio/gstcdiocddasrc.c: (gst_cdio_cdda_src_get_cdtext): Fix build for libcdio versions >= 76; give slightly lower rank than cdparanoia.
This commit is contained in:
parent
16333549fd
commit
82e24850a2
3 changed files with 9 additions and 10 deletions
|
@ -37,7 +37,7 @@ gst_cdio_add_cdtext_field (GstObject * src, cdtext_t * cdtext,
|
|||
{
|
||||
const gchar *txt;
|
||||
|
||||
txt = cdtext_get_const (cdtext, field);
|
||||
txt = cdtext_get_const (field, cdtext);
|
||||
if (txt == NULL || *txt == '\0') {
|
||||
GST_DEBUG_OBJECT (src, "empty CD-TEXT field %u (%s)", field, gst_tag);
|
||||
return;
|
||||
|
@ -73,7 +73,7 @@ gst_cdio_log_handler (cdio_log_level_t level, const char *msg)
|
|||
static gboolean
|
||||
plugin_init (GstPlugin * plugin)
|
||||
{
|
||||
if (!gst_element_register (plugin, "cdiocddasrc", GST_RANK_PRIMARY,
|
||||
if (!gst_element_register (plugin, "cdiocddasrc", GST_RANK_SECONDARY - 1,
|
||||
GST_TYPE_CDIO_CDDA_SRC))
|
||||
return FALSE;
|
||||
|
||||
|
|
|
@ -21,7 +21,8 @@
|
|||
#ifndef __GST_CDIO_H__
|
||||
#define __GST_CDIO_H__
|
||||
|
||||
#include <gst/gstinfo.h>
|
||||
#include <gst/gst.h>
|
||||
#include <cdio/version.h>
|
||||
|
||||
GST_DEBUG_CATEGORY_EXTERN (gst_cdio_debug);
|
||||
#define GST_CAT_DEFAULT gst_cdio_debug
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "gstcdio.h"
|
||||
#include "gstcdiocddasrc.h"
|
||||
|
||||
#include <gst/gst.h>
|
||||
|
@ -161,8 +162,7 @@ static GstTagList *
|
|||
gst_cdio_cdda_src_get_cdtext (GstCdioCddaSrc * src, track_t i_track)
|
||||
{
|
||||
GstTagList *tags = NULL;
|
||||
const gchar *artist;
|
||||
const gchar *title;
|
||||
GstObject *obj;
|
||||
cdtext_t *t;
|
||||
|
||||
t = cdio_get_cdtext (src->cdio, i_track);
|
||||
|
@ -171,11 +171,9 @@ gst_cdio_cdda_src_get_cdtext (GstCdioCddaSrc * src, track_t i_track)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
gst_cdio_cdda_src_add_cdtext_field (src, t, CDTEXT_PERFOMER,
|
||||
GST_TAG_ARTIST, &tags);
|
||||
|
||||
gst_cdio_cdda_src_add_cdtext_field (src, t, CDTEXT_TITLE,
|
||||
GST_TAG_TITLE, &tags);
|
||||
obj = GST_OBJECT (src);
|
||||
gst_cdio_add_cdtext_field (obj, t, CDTEXT_PERFORMER, GST_TAG_ARTIST, &tags);
|
||||
gst_cdio_add_cdtext_field (obj, t, CDTEXT_TITLE, GST_TAG_TITLE, &tags);
|
||||
|
||||
return tags;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue