mIRC Homepage
Posted By: Seifer DLL Request. - 29/07/04 03:28 AM
I'm in need of a DLL which reads and writes M3U files. I am not talking about just saving a text file with the .m3u extention,
I mean a proper M3U playlist with the following layout:
Code:
#EXTINF:<track time in secs>,<artist - track 1> [color:green];ID3 infomation for track 1[/color]
track 1.mp3 [color:green];file name[/color]

I'm working on a script which does this, but as you can imagine it's rather slow on a large number of MP3s.
I don't want to use Winamp or any other program for writing M3U files. Any work will be much appreciated.
Posted By: useful Re: DLL Request. - 29/07/04 08:10 AM
open the file and only read what you need to, if your using code from someone else most likely its loading the whole file and then showing you the tags
Posted By: Seifer Re: DLL Request. - 29/07/04 11:27 AM
I think you're missing the point...
Posted By: tidy_trax Re: DLL Request. - 29/07/04 03:28 PM
Use file handling so you don't have to open and close a file handle for each song you write, eg:

Code:
alias m3uopen { .fopen -n m3u $1- }
alias m3uwrite { .fwrite -n m3u $1- }
alias m3uclose { .fclose m3u }


/m3uopen <m3u file>
/m3uwrite <data>
/m3uwrite <more data>
/m3uwrite <even more data>
/m3uclose
Posted By: Soul_Eater Re: DLL Request. - 30/07/04 04:35 AM
all an .m3u is is a
/write playlist.m3u <filename>

thats it. nothing else added to it will make a difference.
© mIRC Discussion Forums