Reading Meta-Tags Error

Please discuss here all the defects you've found in the RadioSure.
Post Reply
MrF
Posts: 1
Joined: 17 Jan 2020, 10:38

Reading Meta-Tags Error

Post by MrF » 17 Jan 2020, 10:46

Hello,

i found an error in your player. You are using the BASS_TAG_HTTP not correct.
Unbenannt.png
Unbenannt.png (73.54 KiB) Viewed 10659 times
From bass.chm:
BASS_TAG_HTTP:
HTTP headers, only available when streaming from a HTTP server. A pointer to a series of null-terminated strings is returned, the final string ending with a double null.
You show the pointers not the Tags. Simple do it like this:

Code: Select all

LPCSTR tag = BASS_ChannelGetTags(Stream, BASS_TAG_HTTP);
if (tag)
{
	LPCSTR p = tag;
	std::vector<std::string> list;
	do {
		list.push_back(std::string(p));
		OutputDebugStringA(p);
		OutputDebugStringA("\r\n");
		p += list.back().size() + 1;
	} while (strlen(p) > 0);
}
Best Regards, MrF.

Post Reply