changeset 467:a3bf53abebf5 trunk

[svn] - implement mpgdec_metadata() - partial shoutcast streamtitle support
author nenolod
date Sun, 21 Jan 2007 01:49:43 -0800
parents 20657d994de8
children 2e4d10f3f9cb
files ChangeLog src/mpg123/common.c src/mpg123/mpg123.c
diffstat 3 files changed, 18 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sat Jan 20 23:31:12 2007 -0800
+++ b/ChangeLog	Sun Jan 21 01:49:43 2007 -0800
@@ -1,3 +1,12 @@
+2007-01-21 07:31:12 +0000  Daniel Barkalow <barkalow@iabervon.org>
+  revision [1018]
+  Handle inline metadata. Parsing of tags needs work before it will not crash on
+  occasion, so it's disabled for now.
+  
+  trunk/src/curl/curl.c |  171 +++++++++++++++++++++++++++++++++++++++++++++++---
+  1 file changed, 163 insertions(+), 8 deletions(-)
+
+
 2007-01-21 05:40:49 +0000  Daniel Barkalow <barkalow@iabervon.org>
   revision [1016]
   Provide "name" metadata when the url is a shoutcast stream.
--- a/src/mpg123/common.c	Sat Jan 20 23:31:12 2007 -0800
+++ b/src/mpg123/common.c	Sun Jan 21 01:49:43 2007 -0800
@@ -99,6 +99,14 @@
         }
 }
 
+gchar *mpgdec_metadata(const gchar *id)
+{
+	if (filept == NULL)
+		return NULL;
+
+	return vfs_get_metadata(filept, id);
+}
+
 /**************************************** 
  * HACK,HACK,HACK: step back <num> frames 
  * can only work if the 'stream' isn't a mpgdec_real stream but a file
--- a/src/mpg123/mpg123.c	Sat Jan 20 23:31:12 2007 -0800
+++ b/src/mpg123/mpg123.c	Sun Jan 21 01:49:43 2007 -0800
@@ -761,8 +761,7 @@
 	    }
         }
         else {
-            if (CHECK_STREAM_URI(filename))
-                mpgdec_title = mpgdec_http_get_title(filename);
+            mpgdec_title = mpgdec_metadata("stream-name");
 	    mpgdec_length = -1;
         }