BASS.NET API for the Un4seen BASS Audio LibraryBassBASS_ChannelGetTagsID3V1 Method BASS.NET API for the Un4seen BASS Audio Library
Retrieves the ID3v1 tags from a channel, if they are available.

This special helper method already evaluates the 128-byte ID3v3 data block.

Namespace: Un4seen.Bass
Assembly: Bass.Net (in Bass.Net.dll) Version: 2.4.12.0
Syntax

public static string[] BASS_ChannelGetTagsID3V1(
	int handle
)

Parameters

handle
Type: SystemInt32
The channel handle...a HSTREAM.

Return Value

Type: String
or an array of strings with exactly 7 elements:

string[0] = 'song title' (max. 30 chars)

string[1] = 'artist' (max. 30 chars)

string[2] = 'album' (max. 30 chars)

string[3] = 'year' (yyyy)

string[4] = 'comment' (max. 28 chars)

string[5] = 'genre-id'

string[6] = 'track' (0-255)

Remarks

ID3v1 tags are located at the end of the file, so when streaming an MPEG file with ID3v1 tags from the internet, the tags will not be available until the download is complete. A BASS_SYNC_DOWNLOAD sync can be set via BASS_ChannelSetSync(Int32, BASSSync, Int64, SYNCPROC, IntPtr), to be informed of when the download is complete.

In addition you might also use the BassTags class, which provides extended TAG reading support.

ERROR CODEDescription
BASS_ERROR_HANDLEhandle is not valid.
BASS_ERROR_NOTAVAILThe requested tags are not available.

Examples

VB
Dim stream As Integer = Bass.BASS_StreamCreateFile("test.mp3", 0, 0, BASSFlag.BASS_DEFAULT)
Dim tags As String() = Bass.BASS_ChannelGetTagsID3V1(stream)
Dim tag As String
For Each tag In tags
  Console.WriteLine(tag)
Next tag
int stream = Bass.BASS_StreamCreateFile("test.mp3", 0, 0, BASSFlag.BASS_DEFAULT);
string[] tags = Bass.BASS_ChannelGetTagsID3V1(stream);
foreach (string tag in tags)
  Console.WriteLine(tag);
See Also

Reference