[API]
RtlMoveMemory

[INCLUDE]
PeekS
CallFunction_Fast

[DEFINE]
Private ctSSLayer_ReadSongInfoInt As Long

Public Type ctSSLayerSongInfoStruct
  FormatOK As Long ' Boolean
  Format_Frequency As Long
  Format_BitRate As Long
  Format_Channels As Long
  Format_VBR As Long ' Boolean
  Format_QualityMulti As Single
  TagOK As Long 'Boolean
  Tag_Year As Long
  Tag_TrackID As Long
  Tag_Artist As String
  Tag_Title As String
  Tag_Album As String
  IR_Name As String
  IR_URL As String
  End Type

[CODE]
Public Function ctSSLayer_ReadSongInfo(ByVal SongPointer As Long, xSongInfo As ctSSLayerSongInfoStruct) As Boolean
  Dim xLongA1(13&) As Long

  ctSSLayer_ReadSongInfo = Not (CallFunction_Fast(ctSSLayer_ReadSongInfoInt, SongPointer, VarPtr(xLongA1(0))) = 0&)
  Call RtlMoveMemory(xSongInfo, ByVal VarPtr(xLongA1(0)), 36&)

  xSongInfo.Tag_Artist = PeekS(xLongA1(9&)) 'xType1.Tag_Artist)
  xSongInfo.Tag_Title = PeekS(xLongA1(10&)) 'xType1.Tag_Title)
  xSongInfo.Tag_Album = PeekS(xLongA1(11&)) 'xType1.Tag_Album)
  xSongInfo.IR_Name = PeekS(xLongA1(12&))
  xSongInfo.IR_URL = PeekS(xLongA1(13&))
  End Function
