Stream name, variable |
Please read foobar2000 Tech Support Forum Rules before posting and comply with all the points.
Failure to provide all the information pointed out in the above document in your post is considered wasting other people's time and in extreme cases will lead to your topic getting locked without a reply.
See also: Hydrogenaudio Terms of Service.
![]() ![]() |
Stream name, variable |
Feb 15 2009, 01:12
Post
#1
|
|
|
Group: Members Posts: 8 Joined: 24-October 08 Member No.: 60941 |
Hi!
What is the name of the variable that contains the name of the stream when you're listening to it? I can find the stream URL (which is in %path%), but I can't find the stream name variable. The wiki page that lists the variables doesn't say much about it too, in fact, when I ctrl+f with "stream", I don't get any results. Some documentation or help would be much appreciated. |
|
|
|
Feb 15 2009, 01:15
Post
#2
|
|
|
Group: Members Posts: 8 Joined: 24-October 08 Member No.: 60941 |
Found another topic with the same question, from 2004. But no useful answers... http://www.hydrogenaudio.org/forums/index....=0&p=202080
|
|
|
|
Feb 17 2009, 21:40
Post
#3
|
|
|
Group: Members Posts: 12 Joined: 10-May 08 Member No.: 53426 |
I don't know if this answers your question but for every stream I have a .asx file with the following content for example:
CODE <asx version="3.0"> <entry> <ref href="http://www.omroep.nl/live/radio3-breed.asx"/> <title>Radio 3fm</title> <author>Stream</author> </entry> </asx> When the stream is not playing, the name between the author tags is displayed as the artist in fobar. But when I play the stream. The fields become empty. |
|
|
|
Feb 18 2009, 02:32
Post
#4
|
|
![]() Group: Members Posts: 1535 Joined: 8-May 06 Member No.: 30546 |
For what it is worth, this thread lists all the tag information I could find for online streams in foobar. If you have more information please add it.
-------------------- http://www.ubuntu.com
|
|
|
|
Feb 18 2009, 08:30
Post
#5
|
|
|
Group: Members Posts: 581 Joined: 12-May 06 From: Colorado, USA Member No.: 30694 |
I'd really like to have access to the stream title, too.
Apparently when you play a SHOUTcast (ICY) stream which has metadata in it, %artist% and %title% are derived from the StreamTitle metadata, which normally contains the current artist and title and sometimes also the name of the station. It looks like foobar2000 splits the StreamTitle on the first "-", so if it's in a standard "Artist - Title" format and Artist contains a hyphen, then %artist% will be the part before the hyphen and %title% will be everything after, which of course is poo. I was hoping I could parse the data myself and split on the first " - " (spaces around the dash) via custom title formatting, but I don't see any variables where the raw StreamTitle is exposed. Also I had no luck using %url% in a custom column; I had to just use %path%. |
|
|
|
Feb 18 2009, 17:19
Post
#6
|
|
|
Group: Members Posts: 8 Joined: 24-October 08 Member No.: 60941 |
I'd really like to have access to the stream title, too. Apparently when you play a SHOUTcast (ICY) stream which has metadata in it, %artist% and %title% are derived from the StreamTitle metadata, which normally contains the current artist and title and sometimes also the name of the station. It looks like foobar2000 splits the StreamTitle on the first "-", so if it's in a standard "Artist - Title" format and Artist contains a hyphen, then %artist% will be the part before the hyphen and %title% will be everything after, which of course is poo. I was hoping I could parse the data myself and split on the first " - " (spaces around the dash) via custom title formatting, but I don't see any variables where the raw StreamTitle is exposed. Also I had no luck using %url% in a custom column; I had to just use %path%. Hm, here I only get the artist and title in resp. %artist% and %title%. I never see the the station's name pop up. Do you have "Enable dynamic track titles (may cause problems with some proxies)" checked in Preferences - Networking? |
|
|
|
Feb 20 2009, 04:47
Post
#7
|
|
|
Group: Members Posts: 581 Joined: 12-May 06 From: Colorado, USA Member No.: 30694 |
Hm, here I only get the artist and title in resp. %artist% and %title%. I never see the the station's name pop up. Right, same here. I was just saying that the 'StreamTitle' metadata embedded in the actual SHOUTcast stream contains usually only either:
It depends on how the stream source is configured. In any case given any of the above, fb2k seems to parse only the artist and title out of it when those subfields are available. Do you have "Enable dynamic track titles (may cause problems with some proxies)" checked in Preferences - Networking? I do. I assume that's the reason it's parsing StreamTitle at all. |
|
|
|
Feb 20 2009, 04:49
Post
#8
|
|
|
Group: Members Posts: 581 Joined: 12-May 06 From: Colorado, USA Member No.: 30694 |
Hm, here I only get the artist and title in resp. %artist% and %title%. I never see the the station's name pop up. Right, same here. I was just saying that the 'StreamTitle' metadata embedded in the actual SHOUTcast stream contains usually only either:
It depends on how the stream source is configured. In any case given any of the above, fb2k seems to parse only the artist and title out of it when those subfields are available. Do you have "Enable dynamic track titles (may cause problems with some proxies)" checked in Preferences - Networking? I do. I assume that's the reason it's parsing StreamTitle at all. |
|
|
|
Feb 25 2009, 22:24
Post
#9
|
|
|
Group: Members Posts: 8 Joined: 24-October 08 Member No.: 60941 |
Developers: Will this feature be implemented in a future version of Foobar?
I'd like to have the stream name in the %album%-variable. Also, I'd like to have a boolean variable %stream% so I can check if the track currently playing is a stream or not. |
|
|
|
Feb 26 2009, 10:24
Post
#10
|
|
![]() Group: Members Posts: 1535 Joined: 8-May 06 Member No.: 30546 |
Also, I'd like to have a boolean variable %stream% so I can check if the track currently playing is a stream or not. This can be accomplished with: CODE $if($strcmp($left(%path%,7),http$char(58)$char(47)$char(47)),IS A STREAM,IS NOT A STREAM) Similarly, you can test if the currently playing track is on an Audio CD with: CODE $if($strcmp($left(%path%,7),cdda$char(58)$char(47)$char(47)),IS A CD,IS NOT A CD) However, I would like to see more development for online streams. %title% will resolve to the name of the station if the station is not playing or has just begun to play, however it quickly changes to the name of the song as soon as stream information is received. Depending on what you are trying to accomplish, you can exploit this time window and display the station name with %title% if the data is only refreshed on a per-track bases. This post has been edited by Yotsuya: Feb 26 2009, 10:25 -------------------- http://www.ubuntu.com
|
|
|
|
Oct 22 2009, 08:05
Post
#11
|
|
![]() Group: Members Posts: 62 Joined: 22-September 09 Member No.: 73370 |
Is there now any workaround to display my own custom radio stations name and not the URL in playlists?
I know the option "enable dynamic track titles". But not all streams work with this option. sadly This post has been edited by Nixdagibts: Oct 22 2009, 08:14 |
|
|
|
Apr 18 2010, 06:27
Post
#12
|
|
|
Group: Members Posts: 3 Joined: 18-April 10 Member No.: 79952 |
Sorry to bump an old topic, but I was wondering if any progress was made on this. I'm sure it wouldn't be too hard to add a variable for the raw stream name, as Foobar2000 already has that data (since it gets the artist and title from it). All the radio stations I use send the "now playing" data in the format Artist - Title (Radio station name) so it shouldn't be too hard to get the name from inside the brackets.
|
|
|
|
Apr 18 2010, 06:48
Post
#13
|
|
![]() Group: Admin Posts: 4219 Joined: 15-December 02 Member No.: 4082 |
Actually, they only send Artist - Title. The station name is sent at connect time only.
|
|
|
|
Apr 18 2010, 08:54
Post
#14
|
|
|
Group: Members Posts: 3 Joined: 18-April 10 Member No.: 79952 |
Oh, I see. I wasn't aware of that. Winamp keeps showing the radio station name even when the song changes, so I assumed it was sent in every metadata update.
Well, in any case, Winamp has a variable for it (I believe), and even after receiving the artist and track name in Foobar, the radio station name is still available in the Metadata properties window (right-click -> metadata) as "Track title". Is it possible to pull through that title in a keyword like %original_title%? Edit: Seems it's sent as a icy-name header. Surely that'd be easy to save This post has been edited by Daniel15: Apr 18 2010, 09:23 |
|
|
|
Aug 6 2010, 08:17
Post
#15
|
|
|
Group: Members Posts: 2 Joined: 6-August 10 Member No.: 82870 |
New to foobar, but does anyone know of a component that could parse the stream metadata (dynamic track titles) and make it available? Ideally I'd like to use it with foo_run.
This post has been edited by YippeeKiYay: Aug 6 2010, 08:19 |
|
|
|
Mar 9 2013, 22:02
Post
#16
|
|
![]() Group: Members Posts: 407 Joined: 26-March 09 Member No.: 68400 |
Another request for a "station title" titleformat variable (eg. %stream_title% ?)
It's very frustrating that once playback begins you can no longer display what stream you are listening to. |
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 22nd May 2013 - 08:34 |