Tag copying and c-bindings

Tuomas Peippo tuomas.peippo at 2ndpoint.fi
Fri Feb 4 22:17:36 CET 2005


I have been trying to copy tags from file to another one. I didn't find
anything about this in docs so I did it like this:

TagLib::MPEG::File::File f( "foo.mp3");
TagLib::MPEG::File::File g( "bar.mp3");

TagLib::ID3v2::FrameList::Iterator iter;

        f.ID3v2Tag(true)->removeFrame( *iter, false );
        g.ID3v2Tag(true)->addFrame( *iter );

and it works though it doesnt seem to copy the 'year' field correctly. I
was just wondering if there were some better way to do this? function like
clone() would be nice :).

I'm also coding with C so it's not possible to use c++ library and
C-bindings seems to only exists for those general types. Is it possible to
copy tags from other file to another using only those C functions?

Tuomas Peippo

More information about the taglib-devel mailing list