This class represents synchronized lyrics that accompanies a media file.
Namespace:
Aurigma.GraphicsMill.Codecs
Assembly:
Aurigma.GraphicsMill.Codecs.MediaProcessor (in Aurigma.GraphicsMill.Codecs.MediaProcessor.dll)
Public NotInheritable Class ID3SynchronisedLyrics _
Inherits MetadataDictionary
public sealed class ID3SynchronisedLyrics : MetadataDictionary
Synchronized lyrics are words, said or sung lyrics, or event descriptions, that are in sync with the audio. This ID3 field contains headers which can be used to identify the exact format of the lyrics. Values of the headers can be read via properties ContentType and TimestampFormat.
To read synchronized lyrics from some file, you should first read its MediaProcessorMetadataDictionary collection and then get the ID3SynchronisedLyrics which is contained there.
'Get synchronized lyrics
Private Sub GetLyrics(ByVal metadata As MediaProcessorMetadataDictionary)
'Check if lyrics are present
If metadata.Contains(MediaProcessorMetadataDictionary.SynchronizedLyrics) Then
Dim lyrics As ID3SynchronisedLyrics = CType(metadata _
(MediaProcessorMetadataDictionary.SynchronizedLyrics), _
ID3SynchronisedLyrics)
'Process lyrics
'...
Return
End If
MessageBox.Show("Lyrics are absent", "Error", MessageBoxButtons.OK, _
MessageBoxIcon.Error)
End Sub
//Get synchronized lyrics
private void GetLyrics(MediaProcessorMetadataDictionary metadata)
{
//Check if lyrics are present
if (metadata.Contains(MediaProcessorMetadataDictionary.SynchronizedLyrics))
{
ID3SynchronisedLyrics lyrics = (ID3SynchronisedLyrics)metadata
[MediaProcessorMetadataDictionary.SynchronizedLyrics];
//Process lyrics
//...
return;
}
MessageBox.Show("Lyrics are absent", "Error", MessageBoxButtons.OK,
MessageBoxIcon.Error);
}