[ID3 Dev] First byte of the first frame: the inevitable byte

Tom Sorensen tsorensen at gmail.com
Wed Jan 25 11:17:49 PST 2006


If you really want to reinvent the wheel you can -- you have to determine
how long the ID3v2 tag is, skip that, then read the rest of the file
(excepting the last 256 bytes if it has an ID3V1 tag). How you do this
depends entirely on the library (if any) you use. Note that if all you do is
a byte-by-byte comparison then you still won't detect dupes if the files
were encoded by different encoders, or at different bitrates, or various
other issues.

If you don't want to reinvent the wheel, then go take a look at
musicbrainz.org -- they've already done this. And taken care of the various
issues I listed above.

On 1/25/06, Silas Pradetto <silas at sonoroussound.com> wrote:
>
> I recently became added to this system of emails, and I am trying to write
> a program to find duplicates in MP3's. I wish to only take into
> consideration the actual song data, not bytes of any tags. Therefore, how do
> I find the first byte in the file of actual song data, ie the first byte of
> the first frame? I want to be able to detect duplicates that have different
> tags but are the exact same audio information. Also, to make the program
> faster, I would like to know where to find certain info such as bitrate,
> length in seconds, etc, so when I am scanning my 100000 song library I don't
> have to check bytes if the songs are obviously dissimilar. Thanks very much.
> Oh, and I mostly do VB 6, though I do know some C++, so if you are going to
> talk about file I/O stuff please refer to VB if you can.
>
> Silas
> --------------------------------------------------------------------- To
> unsubscribe, e-mail: id3v2-unsubscribe at id3.org For additional commands,
> e-mail: id3v2-help at id3.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.id3.org/pipermail/id3v2/attachments/20060125/e615fa0c/attachment.html>


More information about the ID3v2 mailing list