diff --git a/Frameworks/TagLib/TagLib.xcodeproj/project.pbxproj b/Frameworks/TagLib/TagLib.xcodeproj/project.pbxproj index b2bc5d499..679728a92 100644 --- a/Frameworks/TagLib/TagLib.xcodeproj/project.pbxproj +++ b/Frameworks/TagLib/TagLib.xcodeproj/project.pbxproj @@ -7,215 +7,362 @@ objects = { /* Begin PBXBuildFile section */ + 177A12A10CC570B800E06D16 /* apefooter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11E80CC570B700E06D16 /* apefooter.cpp */; }; + 177A12A20CC570B800E06D16 /* apefooter.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11E90CC570B700E06D16 /* apefooter.h */; }; + 177A12A30CC570B800E06D16 /* apeitem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11EA0CC570B700E06D16 /* apeitem.cpp */; }; + 177A12A40CC570B800E06D16 /* apeitem.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11EB0CC570B700E06D16 /* apeitem.h */; }; + 177A12A50CC570B800E06D16 /* apetag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11EC0CC570B700E06D16 /* apetag.cpp */; }; + 177A12A60CC570B800E06D16 /* apetag.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11ED0CC570B700E06D16 /* apetag.h */; }; + 177A12A70CC570B800E06D16 /* audioproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11EE0CC570B700E06D16 /* audioproperties.cpp */; }; + 177A12A80CC570B800E06D16 /* audioproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11EF0CC570B700E06D16 /* audioproperties.h */; }; + 177A12A90CC570B800E06D16 /* fileref.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11F00CC570B700E06D16 /* fileref.cpp */; }; + 177A12AA0CC570B800E06D16 /* fileref.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11F10CC570B700E06D16 /* fileref.h */; }; + 177A12AB0CC570B800E06D16 /* flacfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11F30CC570B700E06D16 /* flacfile.cpp */; }; + 177A12AC0CC570B800E06D16 /* flacfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11F40CC570B700E06D16 /* flacfile.h */; }; + 177A12AD0CC570B800E06D16 /* flacproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11F50CC570B700E06D16 /* flacproperties.cpp */; }; + 177A12AE0CC570B800E06D16 /* flacproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11F60CC570B700E06D16 /* flacproperties.h */; }; + 177A12AF0CC570B800E06D16 /* flactag.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11F70CC570B700E06D16 /* flactag.h */; }; + 177A12B00CC570B800E06D16 /* boxfactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11F90CC570B700E06D16 /* boxfactory.cpp */; }; + 177A12B10CC570B800E06D16 /* boxfactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11FA0CC570B700E06D16 /* boxfactory.h */; }; + 177A12B20CC570B800E06D16 /* itunesalbbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11FB0CC570B700E06D16 /* itunesalbbox.cpp */; }; + 177A12B30CC570B800E06D16 /* itunesalbbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11FC0CC570B700E06D16 /* itunesalbbox.h */; }; + 177A12B40CC570B800E06D16 /* itunesartbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11FD0CC570B700E06D16 /* itunesartbox.cpp */; }; + 177A12B50CC570B800E06D16 /* itunesartbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A11FE0CC570B700E06D16 /* itunesartbox.h */; }; + 177A12B60CC570B800E06D16 /* itunescmtbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A11FF0CC570B700E06D16 /* itunescmtbox.cpp */; }; + 177A12B70CC570B800E06D16 /* itunescmtbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12000CC570B700E06D16 /* itunescmtbox.h */; }; + 177A12B80CC570B800E06D16 /* itunescvrbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12010CC570B700E06D16 /* itunescvrbox.cpp */; }; + 177A12B90CC570B800E06D16 /* itunescvrbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12020CC570B700E06D16 /* itunescvrbox.h */; }; + 177A12BA0CC570B800E06D16 /* itunesdatabox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12030CC570B700E06D16 /* itunesdatabox.cpp */; }; + 177A12BB0CC570B800E06D16 /* itunesdatabox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12040CC570B700E06D16 /* itunesdatabox.h */; }; + 177A12BC0CC570B800E06D16 /* itunesdaybox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12050CC570B700E06D16 /* itunesdaybox.cpp */; }; + 177A12BD0CC570B800E06D16 /* itunesdaybox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12060CC570B700E06D16 /* itunesdaybox.h */; }; + 177A12BE0CC570B800E06D16 /* itunesdiskbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12070CC570B700E06D16 /* itunesdiskbox.cpp */; }; + 177A12BF0CC570B800E06D16 /* itunesdiskbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12080CC570B700E06D16 /* itunesdiskbox.h */; }; + 177A12C00CC570B800E06D16 /* itunesgenbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12090CC570B700E06D16 /* itunesgenbox.cpp */; }; + 177A12C10CC570B800E06D16 /* itunesgenbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A120A0CC570B700E06D16 /* itunesgenbox.h */; }; + 177A12C20CC570B800E06D16 /* itunesgrpbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A120B0CC570B700E06D16 /* itunesgrpbox.cpp */; }; + 177A12C30CC570B800E06D16 /* itunesgrpbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A120C0CC570B700E06D16 /* itunesgrpbox.h */; }; + 177A12C40CC570B800E06D16 /* itunesnambox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A120D0CC570B700E06D16 /* itunesnambox.cpp */; }; + 177A12C50CC570B800E06D16 /* itunesnambox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A120E0CC570B700E06D16 /* itunesnambox.h */; }; + 177A12C60CC570B800E06D16 /* itunestmpobox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A120F0CC570B700E06D16 /* itunestmpobox.cpp */; }; + 177A12C70CC570B800E06D16 /* itunestmpobox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12100CC570B700E06D16 /* itunestmpobox.h */; }; + 177A12C80CC570B800E06D16 /* itunestrknbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12110CC570B700E06D16 /* itunestrknbox.cpp */; }; + 177A12C90CC570B800E06D16 /* itunestrknbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12120CC570B700E06D16 /* itunestrknbox.h */; }; + 177A12CA0CC570B800E06D16 /* ituneswrtbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12130CC570B700E06D16 /* ituneswrtbox.cpp */; }; + 177A12CB0CC570B800E06D16 /* ituneswrtbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12140CC570B700E06D16 /* ituneswrtbox.h */; }; + 177A12CC0CC570B800E06D16 /* mp4audioproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12150CC570B700E06D16 /* mp4audioproperties.cpp */; }; + 177A12CD0CC570B800E06D16 /* mp4audioproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12160CC570B700E06D16 /* mp4audioproperties.h */; }; + 177A12CE0CC570B800E06D16 /* mp4audiosampleentry.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12170CC570B700E06D16 /* mp4audiosampleentry.cpp */; }; + 177A12CF0CC570B800E06D16 /* mp4audiosampleentry.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12180CC570B700E06D16 /* mp4audiosampleentry.h */; }; + 177A12D00CC570B800E06D16 /* mp4file.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12190CC570B700E06D16 /* mp4file.cpp */; }; + 177A12D10CC570B800E06D16 /* mp4file.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A121A0CC570B700E06D16 /* mp4file.h */; }; + 177A12D20CC570B800E06D16 /* mp4fourcc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A121B0CC570B700E06D16 /* mp4fourcc.cpp */; }; + 177A12D30CC570B800E06D16 /* mp4fourcc.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A121C0CC570B700E06D16 /* mp4fourcc.h */; }; + 177A12D40CC570B800E06D16 /* mp4hdlrbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A121D0CC570B700E06D16 /* mp4hdlrbox.cpp */; }; + 177A12D50CC570B800E06D16 /* mp4hdlrbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A121E0CC570B700E06D16 /* mp4hdlrbox.h */; }; + 177A12D60CC570B800E06D16 /* mp4ilstbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A121F0CC570B700E06D16 /* mp4ilstbox.cpp */; }; + 177A12D70CC570B800E06D16 /* mp4ilstbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12200CC570B700E06D16 /* mp4ilstbox.h */; }; + 177A12D80CC570B800E06D16 /* mp4isobox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12210CC570B700E06D16 /* mp4isobox.cpp */; }; + 177A12D90CC570B800E06D16 /* mp4isobox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12220CC570B700E06D16 /* mp4isobox.h */; }; + 177A12DA0CC570B800E06D16 /* mp4isofullbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12230CC570B700E06D16 /* mp4isofullbox.cpp */; }; + 177A12DB0CC570B800E06D16 /* mp4isofullbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12240CC570B700E06D16 /* mp4isofullbox.h */; }; + 177A12DC0CC570B800E06D16 /* mp4itunestag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12250CC570B700E06D16 /* mp4itunestag.cpp */; }; + 177A12DD0CC570B800E06D16 /* mp4itunestag.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12260CC570B700E06D16 /* mp4itunestag.h */; }; + 177A12DE0CC570B800E06D16 /* mp4mdiabox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12270CC570B700E06D16 /* mp4mdiabox.cpp */; }; + 177A12DF0CC570B800E06D16 /* mp4mdiabox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12280CC570B700E06D16 /* mp4mdiabox.h */; }; + 177A12E00CC570B800E06D16 /* mp4metabox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12290CC570B700E06D16 /* mp4metabox.cpp */; }; + 177A12E10CC570B800E06D16 /* mp4metabox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A122A0CC570B700E06D16 /* mp4metabox.h */; }; + 177A12E20CC570B800E06D16 /* mp4minfbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A122B0CC570B700E06D16 /* mp4minfbox.cpp */; }; + 177A12E30CC570B800E06D16 /* mp4minfbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A122C0CC570B700E06D16 /* mp4minfbox.h */; }; + 177A12E40CC570B800E06D16 /* mp4moovbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A122D0CC570B700E06D16 /* mp4moovbox.cpp */; }; + 177A12E50CC570B800E06D16 /* mp4moovbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A122E0CC570B700E06D16 /* mp4moovbox.h */; }; + 177A12E60CC570B800E06D16 /* mp4mvhdbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A122F0CC570B700E06D16 /* mp4mvhdbox.cpp */; }; + 177A12E70CC570B800E06D16 /* mp4mvhdbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12300CC570B700E06D16 /* mp4mvhdbox.h */; }; + 177A12E80CC570B800E06D16 /* mp4propsproxy.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12310CC570B700E06D16 /* mp4propsproxy.cpp */; }; + 177A12E90CC570B800E06D16 /* mp4propsproxy.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12320CC570B700E06D16 /* mp4propsproxy.h */; }; + 177A12EA0CC570B800E06D16 /* mp4sampleentry.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12330CC570B700E06D16 /* mp4sampleentry.cpp */; }; + 177A12EB0CC570B800E06D16 /* mp4sampleentry.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12340CC570B700E06D16 /* mp4sampleentry.h */; }; + 177A12EC0CC570B800E06D16 /* mp4skipbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12350CC570B700E06D16 /* mp4skipbox.cpp */; }; + 177A12ED0CC570B800E06D16 /* mp4skipbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12360CC570B700E06D16 /* mp4skipbox.h */; }; + 177A12EE0CC570B800E06D16 /* mp4stblbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12370CC570B700E06D16 /* mp4stblbox.cpp */; }; + 177A12EF0CC570B800E06D16 /* mp4stblbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12380CC570B700E06D16 /* mp4stblbox.h */; }; + 177A12F00CC570B800E06D16 /* mp4stsdbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12390CC570B700E06D16 /* mp4stsdbox.cpp */; }; + 177A12F10CC570B800E06D16 /* mp4stsdbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A123A0CC570B700E06D16 /* mp4stsdbox.h */; }; + 177A12F20CC570B800E06D16 /* mp4tagsproxy.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A123B0CC570B700E06D16 /* mp4tagsproxy.cpp */; }; + 177A12F30CC570B800E06D16 /* mp4tagsproxy.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A123C0CC570B700E06D16 /* mp4tagsproxy.h */; }; + 177A12F40CC570B800E06D16 /* mp4trakbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A123D0CC570B700E06D16 /* mp4trakbox.cpp */; }; + 177A12F50CC570B800E06D16 /* mp4trakbox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A123E0CC570B700E06D16 /* mp4trakbox.h */; }; + 177A12F60CC570B800E06D16 /* mp4udtabox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A123F0CC570B700E06D16 /* mp4udtabox.cpp */; }; + 177A12F70CC570B800E06D16 /* mp4udtabox.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12400CC570B700E06D16 /* mp4udtabox.h */; }; + 177A12F80CC570B800E06D16 /* combinedtag.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12420CC570B700E06D16 /* combinedtag.h */; }; + 177A12F90CC570B800E06D16 /* mpcfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12430CC570B700E06D16 /* mpcfile.cpp */; }; + 177A12FA0CC570B800E06D16 /* mpcfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12440CC570B700E06D16 /* mpcfile.h */; }; + 177A12FB0CC570B800E06D16 /* mpcproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12450CC570B700E06D16 /* mpcproperties.cpp */; }; + 177A12FC0CC570B800E06D16 /* mpcproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12460CC570B700E06D16 /* mpcproperties.h */; }; + 177A12FD0CC570B800E06D16 /* id3v1genres.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12490CC570B700E06D16 /* id3v1genres.cpp */; }; + 177A12FE0CC570B800E06D16 /* id3v1genres.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A124A0CC570B700E06D16 /* id3v1genres.h */; }; + 177A12FF0CC570B800E06D16 /* id3v1tag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A124B0CC570B700E06D16 /* id3v1tag.cpp */; }; + 177A13000CC570B800E06D16 /* id3v1tag.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A124C0CC570B700E06D16 /* id3v1tag.h */; }; + 177A13010CC570B800E06D16 /* attachedpictureframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A124F0CC570B700E06D16 /* attachedpictureframe.cpp */; }; + 177A13020CC570B800E06D16 /* attachedpictureframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12500CC570B700E06D16 /* attachedpictureframe.h */; }; + 177A13030CC570B800E06D16 /* commentsframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12510CC570B700E06D16 /* commentsframe.cpp */; }; + 177A13040CC570B800E06D16 /* commentsframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12520CC570B700E06D16 /* commentsframe.h */; }; + 177A13050CC570B800E06D16 /* generalencapsulatedobjectframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12530CC570B700E06D16 /* generalencapsulatedobjectframe.cpp */; }; + 177A13060CC570B800E06D16 /* generalencapsulatedobjectframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12540CC570B700E06D16 /* generalencapsulatedobjectframe.h */; }; + 177A13070CC570B800E06D16 /* relativevolumeframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12550CC570B700E06D16 /* relativevolumeframe.cpp */; }; + 177A13080CC570B800E06D16 /* relativevolumeframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12560CC570B700E06D16 /* relativevolumeframe.h */; }; + 177A13090CC570B800E06D16 /* textidentificationframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12570CC570B700E06D16 /* textidentificationframe.cpp */; }; + 177A130A0CC570B800E06D16 /* textidentificationframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12580CC570B700E06D16 /* textidentificationframe.h */; }; + 177A130B0CC570B800E06D16 /* uniquefileidentifierframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12590CC570B700E06D16 /* uniquefileidentifierframe.cpp */; }; + 177A130C0CC570B800E06D16 /* uniquefileidentifierframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A125A0CC570B700E06D16 /* uniquefileidentifierframe.h */; }; + 177A130D0CC570B800E06D16 /* unknownframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A125B0CC570B700E06D16 /* unknownframe.cpp */; }; + 177A130E0CC570B800E06D16 /* unknownframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A125C0CC570B700E06D16 /* unknownframe.h */; }; + 177A13110CC570B800E06D16 /* id3v2extendedheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A125F0CC570B700E06D16 /* id3v2extendedheader.cpp */; }; + 177A13120CC570B800E06D16 /* id3v2extendedheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12600CC570B700E06D16 /* id3v2extendedheader.h */; }; + 177A13130CC570B800E06D16 /* id3v2footer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12610CC570B700E06D16 /* id3v2footer.cpp */; }; + 177A13140CC570B800E06D16 /* id3v2footer.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12620CC570B700E06D16 /* id3v2footer.h */; }; + 177A13150CC570B800E06D16 /* id3v2frame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12630CC570B700E06D16 /* id3v2frame.cpp */; }; + 177A13160CC570B800E06D16 /* id3v2frame.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12640CC570B700E06D16 /* id3v2frame.h */; }; + 177A13170CC570B800E06D16 /* id3v2framefactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12650CC570B700E06D16 /* id3v2framefactory.cpp */; }; + 177A13180CC570B800E06D16 /* id3v2framefactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12660CC570B700E06D16 /* id3v2framefactory.h */; }; + 177A13190CC570B800E06D16 /* id3v2header.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12670CC570B700E06D16 /* id3v2header.cpp */; }; + 177A131A0CC570B800E06D16 /* id3v2header.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12680CC570B700E06D16 /* id3v2header.h */; }; + 177A131B0CC570B800E06D16 /* id3v2synchdata.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12690CC570B700E06D16 /* id3v2synchdata.cpp */; }; + 177A131C0CC570B800E06D16 /* id3v2synchdata.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A126A0CC570B700E06D16 /* id3v2synchdata.h */; }; + 177A131D0CC570B800E06D16 /* id3v2tag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A126B0CC570B700E06D16 /* id3v2tag.cpp */; }; + 177A131E0CC570B800E06D16 /* id3v2tag.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A126C0CC570B700E06D16 /* id3v2tag.h */; }; + 177A131F0CC570B800E06D16 /* mpegfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A126D0CC570B700E06D16 /* mpegfile.cpp */; }; + 177A13200CC570B800E06D16 /* mpegfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A126E0CC570B700E06D16 /* mpegfile.h */; }; + 177A13210CC570B800E06D16 /* mpegheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A126F0CC570B700E06D16 /* mpegheader.cpp */; }; + 177A13220CC570B800E06D16 /* mpegheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12700CC570B700E06D16 /* mpegheader.h */; }; + 177A13230CC570B800E06D16 /* mpegproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12710CC570B700E06D16 /* mpegproperties.cpp */; }; + 177A13240CC570B800E06D16 /* mpegproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12720CC570B700E06D16 /* mpegproperties.h */; }; + 177A13250CC570B800E06D16 /* xingheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12730CC570B700E06D16 /* xingheader.cpp */; }; + 177A13260CC570B800E06D16 /* xingheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12740CC570B700E06D16 /* xingheader.h */; }; + 177A13270CC570B800E06D16 /* oggflacfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12770CC570B700E06D16 /* oggflacfile.cpp */; }; + 177A13280CC570B800E06D16 /* oggflacfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12780CC570B700E06D16 /* oggflacfile.h */; }; + 177A13290CC570B800E06D16 /* oggfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12790CC570B700E06D16 /* oggfile.cpp */; }; + 177A132A0CC570B800E06D16 /* oggfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A127A0CC570B700E06D16 /* oggfile.h */; }; + 177A132B0CC570B800E06D16 /* oggpage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A127B0CC570B700E06D16 /* oggpage.cpp */; }; + 177A132C0CC570B800E06D16 /* oggpage.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A127C0CC570B700E06D16 /* oggpage.h */; }; + 177A132D0CC570B800E06D16 /* oggpageheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A127D0CC570B700E06D16 /* oggpageheader.cpp */; }; + 177A132E0CC570B800E06D16 /* oggpageheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A127E0CC570B800E06D16 /* oggpageheader.h */; }; + 177A132F0CC570B800E06D16 /* vorbisfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12800CC570B800E06D16 /* vorbisfile.cpp */; }; + 177A13300CC570B800E06D16 /* vorbisfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12810CC570B800E06D16 /* vorbisfile.h */; }; + 177A13310CC570B800E06D16 /* vorbisproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12820CC570B800E06D16 /* vorbisproperties.cpp */; }; + 177A13320CC570B800E06D16 /* vorbisproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12830CC570B800E06D16 /* vorbisproperties.h */; }; + 177A13330CC570B800E06D16 /* xiphcomment.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12840CC570B800E06D16 /* xiphcomment.cpp */; }; + 177A13340CC570B800E06D16 /* xiphcomment.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12850CC570B800E06D16 /* xiphcomment.h */; }; + 177A13350CC570B800E06D16 /* tag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12860CC570B800E06D16 /* tag.cpp */; }; + 177A13360CC570B800E06D16 /* tag.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12870CC570B800E06D16 /* tag.h */; }; + 177A13370CC570B800E06D16 /* taglib_export.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12880CC570B800E06D16 /* taglib_export.h */; }; + 177A13380CC570B800E06D16 /* taglib.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A128A0CC570B800E06D16 /* taglib.h */; }; + 177A13390CC570B800E06D16 /* tbytevector.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A128B0CC570B800E06D16 /* tbytevector.cpp */; }; + 177A133A0CC570B800E06D16 /* tbytevector.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A128C0CC570B800E06D16 /* tbytevector.h */; }; + 177A133B0CC570B800E06D16 /* tbytevectorlist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A128D0CC570B800E06D16 /* tbytevectorlist.cpp */; }; + 177A133C0CC570B800E06D16 /* tbytevectorlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A128E0CC570B800E06D16 /* tbytevectorlist.h */; }; + 177A133D0CC570B800E06D16 /* tdebug.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A128F0CC570B800E06D16 /* tdebug.cpp */; }; + 177A133E0CC570B800E06D16 /* tdebug.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12900CC570B800E06D16 /* tdebug.h */; }; + 177A133F0CC570B800E06D16 /* tfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12910CC570B800E06D16 /* tfile.cpp */; }; + 177A13400CC570B800E06D16 /* tfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12920CC570B800E06D16 /* tfile.h */; }; + 177A13410CC570B800E06D16 /* tfileio.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12930CC570B800E06D16 /* tfileio.h */; }; + 177A13420CC570B800E06D16 /* tlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12940CC570B800E06D16 /* tlist.h */; }; + 177A13440CC570B800E06D16 /* tlocalfileio.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A12960CC570B800E06D16 /* tlocalfileio.cpp */; }; + 177A13450CC570B800E06D16 /* tlocalfileio.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12970CC570B800E06D16 /* tlocalfileio.h */; }; + 177A13460CC570B800E06D16 /* tmap.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A12980CC570B800E06D16 /* tmap.h */; }; + 177A13480CC570B800E06D16 /* tstring.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A129A0CC570B800E06D16 /* tstring.cpp */; }; + 177A13490CC570B800E06D16 /* tstring.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A129B0CC570B800E06D16 /* tstring.h */; }; + 177A134A0CC570B800E06D16 /* tstringlist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A129C0CC570B800E06D16 /* tstringlist.cpp */; }; + 177A134B0CC570B800E06D16 /* tstringlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A129D0CC570B800E06D16 /* tstringlist.h */; }; + 177A134C0CC570B800E06D16 /* unicode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A129E0CC570B800E06D16 /* unicode.cpp */; }; + 177A134D0CC570B800E06D16 /* unicode.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A129F0CC570B800E06D16 /* unicode.h */; }; + 177A13510CC570C100E06D16 /* tag_c.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 177A134F0CC570C100E06D16 /* tag_c.cpp */; }; + 177A13520CC570C100E06D16 /* tag_c.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A13500CC570C100E06D16 /* tag_c.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 177A137C0CC5719200E06D16 /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = 177A137B0CC5719200E06D16 /* config.h */; }; 8DC2EF530486A6940098B216 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C1666FE841158C02AAC07 /* InfoPlist.strings */; }; - 8E75709A09F319040080F1EE /* ape-tag-format.txt in Resources */ = {isa = PBXBuildFile; fileRef = 8E75701A09F319030080F1EE /* ape-tag-format.txt */; }; - 8E75709B09F319040080F1EE /* apefooter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75701B09F319030080F1EE /* apefooter.cpp */; }; - 8E75709C09F319040080F1EE /* apefooter.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75701C09F319030080F1EE /* apefooter.h */; }; - 8E75709D09F319040080F1EE /* apeitem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75701D09F319030080F1EE /* apeitem.cpp */; }; - 8E75709E09F319040080F1EE /* apeitem.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75701E09F319030080F1EE /* apeitem.h */; }; - 8E75709F09F319040080F1EE /* apetag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75701F09F319030080F1EE /* apetag.cpp */; }; - 8E7570A009F319040080F1EE /* apetag.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75702009F319030080F1EE /* apetag.h */; }; - 8E7570A309F319040080F1EE /* audioproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75702309F319030080F1EE /* audioproperties.cpp */; }; - 8E7570A409F319040080F1EE /* audioproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75702409F319030080F1EE /* audioproperties.h */; }; - 8E7570A509F319040080F1EE /* fileref.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75702509F319030080F1EE /* fileref.cpp */; }; - 8E7570A609F319040080F1EE /* fileref.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75702609F319030080F1EE /* fileref.h */; }; - 8E7570A709F319040080F1EE /* flacfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75702809F319030080F1EE /* flacfile.cpp */; }; - 8E7570A809F319040080F1EE /* flacfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75702909F319030080F1EE /* flacfile.h */; }; - 8E7570A909F319040080F1EE /* flacproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75702A09F319030080F1EE /* flacproperties.cpp */; }; - 8E7570AA09F319040080F1EE /* flacproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75702B09F319030080F1EE /* flacproperties.h */; }; - 8E7570AB09F319040080F1EE /* flactag.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75702C09F319030080F1EE /* flactag.h */; }; - 8E7570AE09F319040080F1EE /* combinedtag.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75703009F319030080F1EE /* combinedtag.h */; }; - 8E7570B109F319040080F1EE /* mpcfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75703309F319030080F1EE /* mpcfile.cpp */; }; - 8E7570B209F319040080F1EE /* mpcfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75703409F319030080F1EE /* mpcfile.h */; }; - 8E7570B309F319040080F1EE /* mpcproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75703509F319030080F1EE /* mpcproperties.cpp */; }; - 8E7570B409F319040080F1EE /* mpcproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75703609F319030080F1EE /* mpcproperties.h */; }; - 8E7570B509F319040080F1EE /* id3v1genres.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75703909F319030080F1EE /* id3v1genres.cpp */; }; - 8E7570B609F319040080F1EE /* id3v1genres.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75703A09F319030080F1EE /* id3v1genres.h */; }; - 8E7570B709F319040080F1EE /* id3v1tag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75703B09F319030080F1EE /* id3v1tag.cpp */; }; - 8E7570B809F319040080F1EE /* id3v1tag.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75703C09F319030080F1EE /* id3v1tag.h */; }; - 8E7570BB09F319040080F1EE /* attachedpictureframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75704109F319030080F1EE /* attachedpictureframe.cpp */; }; - 8E7570BC09F319040080F1EE /* attachedpictureframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75704209F319030080F1EE /* attachedpictureframe.h */; }; - 8E7570BD09F319040080F1EE /* commentsframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75704309F319030080F1EE /* commentsframe.cpp */; }; - 8E7570BE09F319040080F1EE /* commentsframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75704409F319030080F1EE /* commentsframe.h */; }; - 8E7570C109F319040080F1EE /* relativevolumeframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75704709F319030080F1EE /* relativevolumeframe.cpp */; }; - 8E7570C209F319040080F1EE /* relativevolumeframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75704809F319030080F1EE /* relativevolumeframe.h */; }; - 8E7570C309F319040080F1EE /* textidentificationframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75704909F319030080F1EE /* textidentificationframe.cpp */; }; - 8E7570C409F319040080F1EE /* textidentificationframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75704A09F319030080F1EE /* textidentificationframe.h */; }; - 8E7570C509F319040080F1EE /* uniquefileidentifierframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75704B09F319030080F1EE /* uniquefileidentifierframe.cpp */; }; - 8E7570C609F319040080F1EE /* uniquefileidentifierframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75704C09F319030080F1EE /* uniquefileidentifierframe.h */; }; - 8E7570C709F319040080F1EE /* unknownframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75704D09F319030080F1EE /* unknownframe.cpp */; }; - 8E7570C809F319040080F1EE /* unknownframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75704E09F319030080F1EE /* unknownframe.h */; }; - 8E7570C909F319040080F1EE /* id3v2.4.0-frames.txt in Resources */ = {isa = PBXBuildFile; fileRef = 8E75704F09F319030080F1EE /* id3v2.4.0-frames.txt */; }; - 8E7570CA09F319040080F1EE /* id3v2.4.0-structure.txt in Resources */ = {isa = PBXBuildFile; fileRef = 8E75705009F319030080F1EE /* id3v2.4.0-structure.txt */; }; - 8E7570CB09F319040080F1EE /* id3v2extendedheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75705109F319030080F1EE /* id3v2extendedheader.cpp */; }; - 8E7570CC09F319040080F1EE /* id3v2extendedheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75705209F319030080F1EE /* id3v2extendedheader.h */; }; - 8E7570CD09F319040080F1EE /* id3v2footer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75705309F319030080F1EE /* id3v2footer.cpp */; }; - 8E7570CE09F319040080F1EE /* id3v2footer.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75705409F319030080F1EE /* id3v2footer.h */; }; - 8E7570CF09F319040080F1EE /* id3v2frame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75705509F319030080F1EE /* id3v2frame.cpp */; }; - 8E7570D009F319040080F1EE /* id3v2frame.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75705609F319030080F1EE /* id3v2frame.h */; }; - 8E7570D109F319040080F1EE /* id3v2framefactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75705709F319030080F1EE /* id3v2framefactory.cpp */; }; - 8E7570D209F319040080F1EE /* id3v2framefactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75705809F319030080F1EE /* id3v2framefactory.h */; }; - 8E7570D309F319040080F1EE /* id3v2header.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75705909F319030080F1EE /* id3v2header.cpp */; }; - 8E7570D409F319040080F1EE /* id3v2header.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75705A09F319030080F1EE /* id3v2header.h */; }; - 8E7570D509F319040080F1EE /* id3v2synchdata.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75705B09F319030080F1EE /* id3v2synchdata.cpp */; }; - 8E7570D609F319040080F1EE /* id3v2synchdata.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75705C09F319030080F1EE /* id3v2synchdata.h */; }; - 8E7570D709F319040080F1EE /* id3v2tag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75705D09F319030080F1EE /* id3v2tag.cpp */; }; - 8E7570D809F319040080F1EE /* id3v2tag.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75705E09F319030080F1EE /* id3v2tag.h */; }; - 8E7570DD09F319040080F1EE /* mpegfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75706309F319040080F1EE /* mpegfile.cpp */; }; - 8E7570DE09F319040080F1EE /* mpegfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75706409F319040080F1EE /* mpegfile.h */; }; - 8E7570DF09F319040080F1EE /* mpegheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75706509F319040080F1EE /* mpegheader.cpp */; }; - 8E7570E009F319040080F1EE /* mpegheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75706609F319040080F1EE /* mpegheader.h */; }; - 8E7570E109F319040080F1EE /* mpegproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75706709F319040080F1EE /* mpegproperties.cpp */; }; - 8E7570E209F319040080F1EE /* mpegproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75706809F319040080F1EE /* mpegproperties.h */; }; - 8E7570E309F319040080F1EE /* xingheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75706909F319040080F1EE /* xingheader.cpp */; }; - 8E7570E409F319040080F1EE /* xingheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75706A09F319040080F1EE /* xingheader.h */; }; - 8E7570E709F319040080F1EE /* oggflacfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75706F09F319040080F1EE /* oggflacfile.cpp */; }; - 8E7570E809F319040080F1EE /* oggflacfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75707009F319040080F1EE /* oggflacfile.h */; }; - 8E7570EB09F319040080F1EE /* oggfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75707309F319040080F1EE /* oggfile.cpp */; }; - 8E7570EC09F319040080F1EE /* oggfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75707409F319040080F1EE /* oggfile.h */; }; - 8E7570ED09F319040080F1EE /* oggpage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75707509F319040080F1EE /* oggpage.cpp */; }; - 8E7570EE09F319040080F1EE /* oggpage.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75707609F319040080F1EE /* oggpage.h */; }; - 8E7570EF09F319040080F1EE /* oggpageheader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75707709F319040080F1EE /* oggpageheader.cpp */; }; - 8E7570F009F319040080F1EE /* oggpageheader.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75707809F319040080F1EE /* oggpageheader.h */; }; - 8E7570F309F319040080F1EE /* vorbisfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75707C09F319040080F1EE /* vorbisfile.cpp */; }; - 8E7570F409F319040080F1EE /* vorbisfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75707D09F319040080F1EE /* vorbisfile.h */; }; - 8E7570F509F319040080F1EE /* vorbisproperties.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75707E09F319040080F1EE /* vorbisproperties.cpp */; }; - 8E7570F609F319040080F1EE /* vorbisproperties.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75707F09F319040080F1EE /* vorbisproperties.h */; }; - 8E7570F709F319040080F1EE /* xiphcomment.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75708009F319040080F1EE /* xiphcomment.cpp */; }; - 8E7570F809F319040080F1EE /* xiphcomment.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75708109F319040080F1EE /* xiphcomment.h */; }; - 8E7570F909F319040080F1EE /* tag.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75708209F319040080F1EE /* tag.cpp */; }; - 8E7570FA09F319040080F1EE /* tag.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75708309F319040080F1EE /* tag.h */; }; - 8E7570FD09F319040080F1EE /* taglib.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75708709F319040080F1EE /* taglib.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 8E7570FE09F319040080F1EE /* tbytevector.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75708809F319040080F1EE /* tbytevector.cpp */; }; - 8E7570FF09F319040080F1EE /* tbytevector.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75708909F319040080F1EE /* tbytevector.h */; }; - 8E75710009F319040080F1EE /* tbytevectorlist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75708A09F319040080F1EE /* tbytevectorlist.cpp */; }; - 8E75710109F319040080F1EE /* tbytevectorlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75708B09F319040080F1EE /* tbytevectorlist.h */; }; - 8E75710209F319040080F1EE /* tdebug.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75708C09F319040080F1EE /* tdebug.cpp */; }; - 8E75710309F319040080F1EE /* tdebug.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75708D09F319040080F1EE /* tdebug.h */; }; - 8E75710409F319040080F1EE /* tfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75708E09F319040080F1EE /* tfile.cpp */; }; - 8E75710509F319040080F1EE /* tfile.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75708F09F319040080F1EE /* tfile.h */; }; - 8E75710609F319040080F1EE /* tlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75709009F319040080F1EE /* tlist.h */; }; - 8E75710709F319040080F1EE /* tlist.tcc in Resources */ = {isa = PBXBuildFile; fileRef = 8E75709109F319040080F1EE /* tlist.tcc */; }; - 8E75710809F319040080F1EE /* tmap.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75709209F319040080F1EE /* tmap.h */; }; - 8E75710909F319040080F1EE /* tmap.tcc in Resources */ = {isa = PBXBuildFile; fileRef = 8E75709309F319040080F1EE /* tmap.tcc */; }; - 8E75710A09F319040080F1EE /* tstring.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75709409F319040080F1EE /* tstring.cpp */; }; - 8E75710B09F319040080F1EE /* tstring.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75709509F319040080F1EE /* tstring.h */; }; - 8E75710C09F319040080F1EE /* tstringlist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75709609F319040080F1EE /* tstringlist.cpp */; }; - 8E75710D09F319040080F1EE /* tstringlist.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75709709F319040080F1EE /* tstringlist.h */; }; - 8E75710E09F319040080F1EE /* unicode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75709809F319040080F1EE /* unicode.cpp */; }; - 8E75710F09F319040080F1EE /* unicode.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75709909F319040080F1EE /* unicode.h */; }; - 8E75711309F3190D0080F1EE /* tag_c.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8E75711109F3190D0080F1EE /* tag_c.cpp */; }; - 8E75711409F3190D0080F1EE /* tag_c.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75711209F3190D0080F1EE /* tag_c.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 8E75712209F319570080F1EE /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = 8E75712109F319570080F1EE /* config.h */; }; - 8EE9CD4D0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8EE9CD4B0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.cpp */; }; - 8EE9CD4E0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.h in Headers */ = {isa = PBXBuildFile; fileRef = 8EE9CD4C0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.h */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ 089C1667FE841158C02AAC07 /* English */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = ""; }; + 177A11E70CC570B700E06D16 /* ape-tag-format.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = "ape-tag-format.txt"; sourceTree = ""; }; + 177A11E80CC570B700E06D16 /* apefooter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = apefooter.cpp; sourceTree = ""; }; + 177A11E90CC570B700E06D16 /* apefooter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = apefooter.h; sourceTree = ""; }; + 177A11EA0CC570B700E06D16 /* apeitem.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = apeitem.cpp; sourceTree = ""; }; + 177A11EB0CC570B700E06D16 /* apeitem.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = apeitem.h; sourceTree = ""; }; + 177A11EC0CC570B700E06D16 /* apetag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = apetag.cpp; sourceTree = ""; }; + 177A11ED0CC570B700E06D16 /* apetag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = apetag.h; sourceTree = ""; }; + 177A11EE0CC570B700E06D16 /* audioproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = audioproperties.cpp; path = taglib/taglib/audioproperties.cpp; sourceTree = ""; }; + 177A11EF0CC570B700E06D16 /* audioproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = audioproperties.h; path = taglib/taglib/audioproperties.h; sourceTree = ""; }; + 177A11F00CC570B700E06D16 /* fileref.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = fileref.cpp; path = taglib/taglib/fileref.cpp; sourceTree = ""; }; + 177A11F10CC570B700E06D16 /* fileref.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = fileref.h; path = taglib/taglib/fileref.h; sourceTree = ""; }; + 177A11F30CC570B700E06D16 /* flacfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = flacfile.cpp; sourceTree = ""; }; + 177A11F40CC570B700E06D16 /* flacfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = flacfile.h; sourceTree = ""; }; + 177A11F50CC570B700E06D16 /* flacproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = flacproperties.cpp; sourceTree = ""; }; + 177A11F60CC570B700E06D16 /* flacproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = flacproperties.h; sourceTree = ""; }; + 177A11F70CC570B700E06D16 /* flactag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = flactag.h; sourceTree = ""; }; + 177A11F90CC570B700E06D16 /* boxfactory.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = boxfactory.cpp; sourceTree = ""; }; + 177A11FA0CC570B700E06D16 /* boxfactory.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = boxfactory.h; sourceTree = ""; }; + 177A11FB0CC570B700E06D16 /* itunesalbbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesalbbox.cpp; sourceTree = ""; }; + 177A11FC0CC570B700E06D16 /* itunesalbbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesalbbox.h; sourceTree = ""; }; + 177A11FD0CC570B700E06D16 /* itunesartbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesartbox.cpp; sourceTree = ""; }; + 177A11FE0CC570B700E06D16 /* itunesartbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesartbox.h; sourceTree = ""; }; + 177A11FF0CC570B700E06D16 /* itunescmtbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunescmtbox.cpp; sourceTree = ""; }; + 177A12000CC570B700E06D16 /* itunescmtbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunescmtbox.h; sourceTree = ""; }; + 177A12010CC570B700E06D16 /* itunescvrbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunescvrbox.cpp; sourceTree = ""; }; + 177A12020CC570B700E06D16 /* itunescvrbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunescvrbox.h; sourceTree = ""; }; + 177A12030CC570B700E06D16 /* itunesdatabox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesdatabox.cpp; sourceTree = ""; }; + 177A12040CC570B700E06D16 /* itunesdatabox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesdatabox.h; sourceTree = ""; }; + 177A12050CC570B700E06D16 /* itunesdaybox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesdaybox.cpp; sourceTree = ""; }; + 177A12060CC570B700E06D16 /* itunesdaybox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesdaybox.h; sourceTree = ""; }; + 177A12070CC570B700E06D16 /* itunesdiskbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesdiskbox.cpp; sourceTree = ""; }; + 177A12080CC570B700E06D16 /* itunesdiskbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesdiskbox.h; sourceTree = ""; }; + 177A12090CC570B700E06D16 /* itunesgenbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesgenbox.cpp; sourceTree = ""; }; + 177A120A0CC570B700E06D16 /* itunesgenbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesgenbox.h; sourceTree = ""; }; + 177A120B0CC570B700E06D16 /* itunesgrpbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesgrpbox.cpp; sourceTree = ""; }; + 177A120C0CC570B700E06D16 /* itunesgrpbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesgrpbox.h; sourceTree = ""; }; + 177A120D0CC570B700E06D16 /* itunesnambox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunesnambox.cpp; sourceTree = ""; }; + 177A120E0CC570B700E06D16 /* itunesnambox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunesnambox.h; sourceTree = ""; }; + 177A120F0CC570B700E06D16 /* itunestmpobox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunestmpobox.cpp; sourceTree = ""; }; + 177A12100CC570B700E06D16 /* itunestmpobox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunestmpobox.h; sourceTree = ""; }; + 177A12110CC570B700E06D16 /* itunestrknbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = itunestrknbox.cpp; sourceTree = ""; }; + 177A12120CC570B700E06D16 /* itunestrknbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = itunestrknbox.h; sourceTree = ""; }; + 177A12130CC570B700E06D16 /* ituneswrtbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = ituneswrtbox.cpp; sourceTree = ""; }; + 177A12140CC570B700E06D16 /* ituneswrtbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = ituneswrtbox.h; sourceTree = ""; }; + 177A12150CC570B700E06D16 /* mp4audioproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4audioproperties.cpp; sourceTree = ""; }; + 177A12160CC570B700E06D16 /* mp4audioproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4audioproperties.h; sourceTree = ""; }; + 177A12170CC570B700E06D16 /* mp4audiosampleentry.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4audiosampleentry.cpp; sourceTree = ""; }; + 177A12180CC570B700E06D16 /* mp4audiosampleentry.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4audiosampleentry.h; sourceTree = ""; }; + 177A12190CC570B700E06D16 /* mp4file.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4file.cpp; sourceTree = ""; }; + 177A121A0CC570B700E06D16 /* mp4file.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4file.h; sourceTree = ""; }; + 177A121B0CC570B700E06D16 /* mp4fourcc.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4fourcc.cpp; sourceTree = ""; }; + 177A121C0CC570B700E06D16 /* mp4fourcc.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4fourcc.h; sourceTree = ""; }; + 177A121D0CC570B700E06D16 /* mp4hdlrbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4hdlrbox.cpp; sourceTree = ""; }; + 177A121E0CC570B700E06D16 /* mp4hdlrbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4hdlrbox.h; sourceTree = ""; }; + 177A121F0CC570B700E06D16 /* mp4ilstbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4ilstbox.cpp; sourceTree = ""; }; + 177A12200CC570B700E06D16 /* mp4ilstbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4ilstbox.h; sourceTree = ""; }; + 177A12210CC570B700E06D16 /* mp4isobox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4isobox.cpp; sourceTree = ""; }; + 177A12220CC570B700E06D16 /* mp4isobox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4isobox.h; sourceTree = ""; }; + 177A12230CC570B700E06D16 /* mp4isofullbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4isofullbox.cpp; sourceTree = ""; }; + 177A12240CC570B700E06D16 /* mp4isofullbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4isofullbox.h; sourceTree = ""; }; + 177A12250CC570B700E06D16 /* mp4itunestag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4itunestag.cpp; sourceTree = ""; }; + 177A12260CC570B700E06D16 /* mp4itunestag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4itunestag.h; sourceTree = ""; }; + 177A12270CC570B700E06D16 /* mp4mdiabox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4mdiabox.cpp; sourceTree = ""; }; + 177A12280CC570B700E06D16 /* mp4mdiabox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4mdiabox.h; sourceTree = ""; }; + 177A12290CC570B700E06D16 /* mp4metabox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4metabox.cpp; sourceTree = ""; }; + 177A122A0CC570B700E06D16 /* mp4metabox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4metabox.h; sourceTree = ""; }; + 177A122B0CC570B700E06D16 /* mp4minfbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4minfbox.cpp; sourceTree = ""; }; + 177A122C0CC570B700E06D16 /* mp4minfbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4minfbox.h; sourceTree = ""; }; + 177A122D0CC570B700E06D16 /* mp4moovbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4moovbox.cpp; sourceTree = ""; }; + 177A122E0CC570B700E06D16 /* mp4moovbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4moovbox.h; sourceTree = ""; }; + 177A122F0CC570B700E06D16 /* mp4mvhdbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4mvhdbox.cpp; sourceTree = ""; }; + 177A12300CC570B700E06D16 /* mp4mvhdbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4mvhdbox.h; sourceTree = ""; }; + 177A12310CC570B700E06D16 /* mp4propsproxy.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4propsproxy.cpp; sourceTree = ""; }; + 177A12320CC570B700E06D16 /* mp4propsproxy.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4propsproxy.h; sourceTree = ""; }; + 177A12330CC570B700E06D16 /* mp4sampleentry.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4sampleentry.cpp; sourceTree = ""; }; + 177A12340CC570B700E06D16 /* mp4sampleentry.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4sampleentry.h; sourceTree = ""; }; + 177A12350CC570B700E06D16 /* mp4skipbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4skipbox.cpp; sourceTree = ""; }; + 177A12360CC570B700E06D16 /* mp4skipbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4skipbox.h; sourceTree = ""; }; + 177A12370CC570B700E06D16 /* mp4stblbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4stblbox.cpp; sourceTree = ""; }; + 177A12380CC570B700E06D16 /* mp4stblbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4stblbox.h; sourceTree = ""; }; + 177A12390CC570B700E06D16 /* mp4stsdbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4stsdbox.cpp; sourceTree = ""; }; + 177A123A0CC570B700E06D16 /* mp4stsdbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4stsdbox.h; sourceTree = ""; }; + 177A123B0CC570B700E06D16 /* mp4tagsproxy.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4tagsproxy.cpp; sourceTree = ""; }; + 177A123C0CC570B700E06D16 /* mp4tagsproxy.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4tagsproxy.h; sourceTree = ""; }; + 177A123D0CC570B700E06D16 /* mp4trakbox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4trakbox.cpp; sourceTree = ""; }; + 177A123E0CC570B700E06D16 /* mp4trakbox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4trakbox.h; sourceTree = ""; }; + 177A123F0CC570B700E06D16 /* mp4udtabox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mp4udtabox.cpp; sourceTree = ""; }; + 177A12400CC570B700E06D16 /* mp4udtabox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mp4udtabox.h; sourceTree = ""; }; + 177A12420CC570B700E06D16 /* combinedtag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = combinedtag.h; sourceTree = ""; }; + 177A12430CC570B700E06D16 /* mpcfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpcfile.cpp; sourceTree = ""; }; + 177A12440CC570B700E06D16 /* mpcfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpcfile.h; sourceTree = ""; }; + 177A12450CC570B700E06D16 /* mpcproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpcproperties.cpp; sourceTree = ""; }; + 177A12460CC570B700E06D16 /* mpcproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpcproperties.h; sourceTree = ""; }; + 177A12490CC570B700E06D16 /* id3v1genres.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v1genres.cpp; sourceTree = ""; }; + 177A124A0CC570B700E06D16 /* id3v1genres.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v1genres.h; sourceTree = ""; }; + 177A124B0CC570B700E06D16 /* id3v1tag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v1tag.cpp; sourceTree = ""; }; + 177A124C0CC570B700E06D16 /* id3v1tag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v1tag.h; sourceTree = ""; }; + 177A124F0CC570B700E06D16 /* attachedpictureframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = attachedpictureframe.cpp; sourceTree = ""; }; + 177A12500CC570B700E06D16 /* attachedpictureframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = attachedpictureframe.h; sourceTree = ""; }; + 177A12510CC570B700E06D16 /* commentsframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = commentsframe.cpp; sourceTree = ""; }; + 177A12520CC570B700E06D16 /* commentsframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = commentsframe.h; sourceTree = ""; }; + 177A12530CC570B700E06D16 /* generalencapsulatedobjectframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = generalencapsulatedobjectframe.cpp; sourceTree = ""; }; + 177A12540CC570B700E06D16 /* generalencapsulatedobjectframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = generalencapsulatedobjectframe.h; sourceTree = ""; }; + 177A12550CC570B700E06D16 /* relativevolumeframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = relativevolumeframe.cpp; sourceTree = ""; }; + 177A12560CC570B700E06D16 /* relativevolumeframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = relativevolumeframe.h; sourceTree = ""; }; + 177A12570CC570B700E06D16 /* textidentificationframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = textidentificationframe.cpp; sourceTree = ""; }; + 177A12580CC570B700E06D16 /* textidentificationframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = textidentificationframe.h; sourceTree = ""; }; + 177A12590CC570B700E06D16 /* uniquefileidentifierframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = uniquefileidentifierframe.cpp; sourceTree = ""; }; + 177A125A0CC570B700E06D16 /* uniquefileidentifierframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = uniquefileidentifierframe.h; sourceTree = ""; }; + 177A125B0CC570B700E06D16 /* unknownframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = unknownframe.cpp; sourceTree = ""; }; + 177A125C0CC570B700E06D16 /* unknownframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = unknownframe.h; sourceTree = ""; }; + 177A125D0CC570B700E06D16 /* id3v2.4.0-frames.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = "id3v2.4.0-frames.txt"; sourceTree = ""; }; + 177A125E0CC570B700E06D16 /* id3v2.4.0-structure.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = "id3v2.4.0-structure.txt"; sourceTree = ""; }; + 177A125F0CC570B700E06D16 /* id3v2extendedheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2extendedheader.cpp; sourceTree = ""; }; + 177A12600CC570B700E06D16 /* id3v2extendedheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2extendedheader.h; sourceTree = ""; }; + 177A12610CC570B700E06D16 /* id3v2footer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2footer.cpp; sourceTree = ""; }; + 177A12620CC570B700E06D16 /* id3v2footer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2footer.h; sourceTree = ""; }; + 177A12630CC570B700E06D16 /* id3v2frame.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2frame.cpp; sourceTree = ""; }; + 177A12640CC570B700E06D16 /* id3v2frame.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2frame.h; sourceTree = ""; }; + 177A12650CC570B700E06D16 /* id3v2framefactory.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2framefactory.cpp; sourceTree = ""; }; + 177A12660CC570B700E06D16 /* id3v2framefactory.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2framefactory.h; sourceTree = ""; }; + 177A12670CC570B700E06D16 /* id3v2header.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2header.cpp; sourceTree = ""; }; + 177A12680CC570B700E06D16 /* id3v2header.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2header.h; sourceTree = ""; }; + 177A12690CC570B700E06D16 /* id3v2synchdata.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2synchdata.cpp; sourceTree = ""; }; + 177A126A0CC570B700E06D16 /* id3v2synchdata.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2synchdata.h; sourceTree = ""; }; + 177A126B0CC570B700E06D16 /* id3v2tag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2tag.cpp; sourceTree = ""; }; + 177A126C0CC570B700E06D16 /* id3v2tag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2tag.h; sourceTree = ""; }; + 177A126D0CC570B700E06D16 /* mpegfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpegfile.cpp; sourceTree = ""; }; + 177A126E0CC570B700E06D16 /* mpegfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpegfile.h; sourceTree = ""; }; + 177A126F0CC570B700E06D16 /* mpegheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpegheader.cpp; sourceTree = ""; }; + 177A12700CC570B700E06D16 /* mpegheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpegheader.h; sourceTree = ""; }; + 177A12710CC570B700E06D16 /* mpegproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpegproperties.cpp; sourceTree = ""; }; + 177A12720CC570B700E06D16 /* mpegproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpegproperties.h; sourceTree = ""; }; + 177A12730CC570B700E06D16 /* xingheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = xingheader.cpp; sourceTree = ""; }; + 177A12740CC570B700E06D16 /* xingheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = xingheader.h; sourceTree = ""; }; + 177A12770CC570B700E06D16 /* oggflacfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggflacfile.cpp; sourceTree = ""; }; + 177A12780CC570B700E06D16 /* oggflacfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggflacfile.h; sourceTree = ""; }; + 177A12790CC570B700E06D16 /* oggfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggfile.cpp; sourceTree = ""; }; + 177A127A0CC570B700E06D16 /* oggfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggfile.h; sourceTree = ""; }; + 177A127B0CC570B700E06D16 /* oggpage.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggpage.cpp; sourceTree = ""; }; + 177A127C0CC570B700E06D16 /* oggpage.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggpage.h; sourceTree = ""; }; + 177A127D0CC570B700E06D16 /* oggpageheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggpageheader.cpp; sourceTree = ""; }; + 177A127E0CC570B800E06D16 /* oggpageheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggpageheader.h; sourceTree = ""; }; + 177A12800CC570B800E06D16 /* vorbisfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = vorbisfile.cpp; sourceTree = ""; }; + 177A12810CC570B800E06D16 /* vorbisfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = vorbisfile.h; sourceTree = ""; }; + 177A12820CC570B800E06D16 /* vorbisproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = vorbisproperties.cpp; sourceTree = ""; }; + 177A12830CC570B800E06D16 /* vorbisproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = vorbisproperties.h; sourceTree = ""; }; + 177A12840CC570B800E06D16 /* xiphcomment.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = xiphcomment.cpp; sourceTree = ""; }; + 177A12850CC570B800E06D16 /* xiphcomment.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = xiphcomment.h; sourceTree = ""; }; + 177A12860CC570B800E06D16 /* tag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = tag.cpp; path = taglib/taglib/tag.cpp; sourceTree = ""; }; + 177A12870CC570B800E06D16 /* tag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = tag.h; path = taglib/taglib/tag.h; sourceTree = ""; }; + 177A12880CC570B800E06D16 /* taglib_export.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = taglib_export.h; path = taglib/taglib/taglib_export.h; sourceTree = ""; }; + 177A128A0CC570B800E06D16 /* taglib.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = taglib.h; sourceTree = ""; }; + 177A128B0CC570B800E06D16 /* tbytevector.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tbytevector.cpp; sourceTree = ""; }; + 177A128C0CC570B800E06D16 /* tbytevector.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tbytevector.h; sourceTree = ""; }; + 177A128D0CC570B800E06D16 /* tbytevectorlist.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tbytevectorlist.cpp; sourceTree = ""; }; + 177A128E0CC570B800E06D16 /* tbytevectorlist.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tbytevectorlist.h; sourceTree = ""; }; + 177A128F0CC570B800E06D16 /* tdebug.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tdebug.cpp; sourceTree = ""; }; + 177A12900CC570B800E06D16 /* tdebug.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tdebug.h; sourceTree = ""; }; + 177A12910CC570B800E06D16 /* tfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tfile.cpp; sourceTree = ""; }; + 177A12920CC570B800E06D16 /* tfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tfile.h; sourceTree = ""; }; + 177A12930CC570B800E06D16 /* tfileio.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tfileio.h; sourceTree = ""; }; + 177A12940CC570B800E06D16 /* tlist.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tlist.h; sourceTree = ""; }; + 177A12950CC570B800E06D16 /* tlist.tcc */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tlist.tcc; sourceTree = ""; }; + 177A12960CC570B800E06D16 /* tlocalfileio.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tlocalfileio.cpp; sourceTree = ""; }; + 177A12970CC570B800E06D16 /* tlocalfileio.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tlocalfileio.h; sourceTree = ""; }; + 177A12980CC570B800E06D16 /* tmap.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tmap.h; sourceTree = ""; }; + 177A12990CC570B800E06D16 /* tmap.tcc */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tmap.tcc; sourceTree = ""; }; + 177A129A0CC570B800E06D16 /* tstring.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tstring.cpp; sourceTree = ""; }; + 177A129B0CC570B800E06D16 /* tstring.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tstring.h; sourceTree = ""; }; + 177A129C0CC570B800E06D16 /* tstringlist.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tstringlist.cpp; sourceTree = ""; }; + 177A129D0CC570B800E06D16 /* tstringlist.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tstringlist.h; sourceTree = ""; }; + 177A129E0CC570B800E06D16 /* unicode.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = unicode.cpp; sourceTree = ""; }; + 177A129F0CC570B800E06D16 /* unicode.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = unicode.h; sourceTree = ""; }; + 177A134F0CC570C100E06D16 /* tag_c.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tag_c.cpp; sourceTree = ""; }; + 177A13500CC570C100E06D16 /* tag_c.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tag_c.h; sourceTree = ""; }; + 177A137B0CC5719200E06D16 /* config.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = config.h; path = taglib/config.h; sourceTree = ""; }; 8DC2EF5A0486A6940098B216 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist; path = Info.plist; sourceTree = ""; }; 8DC2EF5B0486A6940098B216 /* TagLib.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = TagLib.framework; sourceTree = BUILT_PRODUCTS_DIR; }; - 8E75701A09F319030080F1EE /* ape-tag-format.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = "ape-tag-format.txt"; sourceTree = ""; }; - 8E75701B09F319030080F1EE /* apefooter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = apefooter.cpp; sourceTree = ""; }; - 8E75701C09F319030080F1EE /* apefooter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = apefooter.h; sourceTree = ""; }; - 8E75701D09F319030080F1EE /* apeitem.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = apeitem.cpp; sourceTree = ""; }; - 8E75701E09F319030080F1EE /* apeitem.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = apeitem.h; sourceTree = ""; }; - 8E75701F09F319030080F1EE /* apetag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = apetag.cpp; sourceTree = ""; }; - 8E75702009F319030080F1EE /* apetag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = apetag.h; sourceTree = ""; }; - 8E75702309F319030080F1EE /* audioproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = audioproperties.cpp; path = Files/taglib/audioproperties.cpp; sourceTree = ""; }; - 8E75702409F319030080F1EE /* audioproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = audioproperties.h; path = Files/taglib/audioproperties.h; sourceTree = ""; }; - 8E75702509F319030080F1EE /* fileref.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = fileref.cpp; path = Files/taglib/fileref.cpp; sourceTree = ""; }; - 8E75702609F319030080F1EE /* fileref.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = fileref.h; path = Files/taglib/fileref.h; sourceTree = ""; }; - 8E75702809F319030080F1EE /* flacfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = flacfile.cpp; sourceTree = ""; }; - 8E75702909F319030080F1EE /* flacfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = flacfile.h; sourceTree = ""; }; - 8E75702A09F319030080F1EE /* flacproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = flacproperties.cpp; sourceTree = ""; }; - 8E75702B09F319030080F1EE /* flacproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = flacproperties.h; sourceTree = ""; }; - 8E75702C09F319030080F1EE /* flactag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = flactag.h; sourceTree = ""; }; - 8E75703009F319030080F1EE /* combinedtag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = combinedtag.h; sourceTree = ""; }; - 8E75703309F319030080F1EE /* mpcfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpcfile.cpp; sourceTree = ""; }; - 8E75703409F319030080F1EE /* mpcfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpcfile.h; sourceTree = ""; }; - 8E75703509F319030080F1EE /* mpcproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpcproperties.cpp; sourceTree = ""; }; - 8E75703609F319030080F1EE /* mpcproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpcproperties.h; sourceTree = ""; }; - 8E75703909F319030080F1EE /* id3v1genres.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v1genres.cpp; sourceTree = ""; }; - 8E75703A09F319030080F1EE /* id3v1genres.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v1genres.h; sourceTree = ""; }; - 8E75703B09F319030080F1EE /* id3v1tag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v1tag.cpp; sourceTree = ""; }; - 8E75703C09F319030080F1EE /* id3v1tag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v1tag.h; sourceTree = ""; }; - 8E75704109F319030080F1EE /* attachedpictureframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = attachedpictureframe.cpp; sourceTree = ""; }; - 8E75704209F319030080F1EE /* attachedpictureframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = attachedpictureframe.h; sourceTree = ""; }; - 8E75704309F319030080F1EE /* commentsframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = commentsframe.cpp; sourceTree = ""; }; - 8E75704409F319030080F1EE /* commentsframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = commentsframe.h; sourceTree = ""; }; - 8E75704709F319030080F1EE /* relativevolumeframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = relativevolumeframe.cpp; sourceTree = ""; }; - 8E75704809F319030080F1EE /* relativevolumeframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = relativevolumeframe.h; sourceTree = ""; }; - 8E75704909F319030080F1EE /* textidentificationframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = textidentificationframe.cpp; sourceTree = ""; }; - 8E75704A09F319030080F1EE /* textidentificationframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = textidentificationframe.h; sourceTree = ""; }; - 8E75704B09F319030080F1EE /* uniquefileidentifierframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = uniquefileidentifierframe.cpp; sourceTree = ""; }; - 8E75704C09F319030080F1EE /* uniquefileidentifierframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = uniquefileidentifierframe.h; sourceTree = ""; }; - 8E75704D09F319030080F1EE /* unknownframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = unknownframe.cpp; sourceTree = ""; }; - 8E75704E09F319030080F1EE /* unknownframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = unknownframe.h; sourceTree = ""; }; - 8E75704F09F319030080F1EE /* id3v2.4.0-frames.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = "id3v2.4.0-frames.txt"; sourceTree = ""; }; - 8E75705009F319030080F1EE /* id3v2.4.0-structure.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = "id3v2.4.0-structure.txt"; sourceTree = ""; }; - 8E75705109F319030080F1EE /* id3v2extendedheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2extendedheader.cpp; sourceTree = ""; }; - 8E75705209F319030080F1EE /* id3v2extendedheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2extendedheader.h; sourceTree = ""; }; - 8E75705309F319030080F1EE /* id3v2footer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2footer.cpp; sourceTree = ""; }; - 8E75705409F319030080F1EE /* id3v2footer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2footer.h; sourceTree = ""; }; - 8E75705509F319030080F1EE /* id3v2frame.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2frame.cpp; sourceTree = ""; }; - 8E75705609F319030080F1EE /* id3v2frame.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2frame.h; sourceTree = ""; }; - 8E75705709F319030080F1EE /* id3v2framefactory.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2framefactory.cpp; sourceTree = ""; }; - 8E75705809F319030080F1EE /* id3v2framefactory.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2framefactory.h; sourceTree = ""; }; - 8E75705909F319030080F1EE /* id3v2header.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2header.cpp; sourceTree = ""; }; - 8E75705A09F319030080F1EE /* id3v2header.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2header.h; sourceTree = ""; }; - 8E75705B09F319030080F1EE /* id3v2synchdata.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2synchdata.cpp; sourceTree = ""; }; - 8E75705C09F319030080F1EE /* id3v2synchdata.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2synchdata.h; sourceTree = ""; }; - 8E75705D09F319030080F1EE /* id3v2tag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = id3v2tag.cpp; sourceTree = ""; }; - 8E75705E09F319030080F1EE /* id3v2tag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = id3v2tag.h; sourceTree = ""; }; - 8E75706309F319040080F1EE /* mpegfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpegfile.cpp; sourceTree = ""; }; - 8E75706409F319040080F1EE /* mpegfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpegfile.h; sourceTree = ""; }; - 8E75706509F319040080F1EE /* mpegheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpegheader.cpp; sourceTree = ""; }; - 8E75706609F319040080F1EE /* mpegheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpegheader.h; sourceTree = ""; }; - 8E75706709F319040080F1EE /* mpegproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = mpegproperties.cpp; sourceTree = ""; }; - 8E75706809F319040080F1EE /* mpegproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = mpegproperties.h; sourceTree = ""; }; - 8E75706909F319040080F1EE /* xingheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = xingheader.cpp; sourceTree = ""; }; - 8E75706A09F319040080F1EE /* xingheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = xingheader.h; sourceTree = ""; }; - 8E75706F09F319040080F1EE /* oggflacfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggflacfile.cpp; sourceTree = ""; }; - 8E75707009F319040080F1EE /* oggflacfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggflacfile.h; sourceTree = ""; }; - 8E75707309F319040080F1EE /* oggfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggfile.cpp; sourceTree = ""; }; - 8E75707409F319040080F1EE /* oggfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggfile.h; sourceTree = ""; }; - 8E75707509F319040080F1EE /* oggpage.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggpage.cpp; sourceTree = ""; }; - 8E75707609F319040080F1EE /* oggpage.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggpage.h; sourceTree = ""; }; - 8E75707709F319040080F1EE /* oggpageheader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = oggpageheader.cpp; sourceTree = ""; }; - 8E75707809F319040080F1EE /* oggpageheader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = oggpageheader.h; sourceTree = ""; }; - 8E75707C09F319040080F1EE /* vorbisfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = vorbisfile.cpp; sourceTree = ""; }; - 8E75707D09F319040080F1EE /* vorbisfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = vorbisfile.h; sourceTree = ""; }; - 8E75707E09F319040080F1EE /* vorbisproperties.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = vorbisproperties.cpp; sourceTree = ""; }; - 8E75707F09F319040080F1EE /* vorbisproperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = vorbisproperties.h; sourceTree = ""; }; - 8E75708009F319040080F1EE /* xiphcomment.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = xiphcomment.cpp; sourceTree = ""; }; - 8E75708109F319040080F1EE /* xiphcomment.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = xiphcomment.h; sourceTree = ""; }; - 8E75708209F319040080F1EE /* tag.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = tag.cpp; path = Files/taglib/tag.cpp; sourceTree = ""; }; - 8E75708309F319040080F1EE /* tag.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = tag.h; path = Files/taglib/tag.h; sourceTree = ""; }; - 8E75708709F319040080F1EE /* taglib.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = taglib.h; sourceTree = ""; }; - 8E75708809F319040080F1EE /* tbytevector.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tbytevector.cpp; sourceTree = ""; }; - 8E75708909F319040080F1EE /* tbytevector.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tbytevector.h; sourceTree = ""; }; - 8E75708A09F319040080F1EE /* tbytevectorlist.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tbytevectorlist.cpp; sourceTree = ""; }; - 8E75708B09F319040080F1EE /* tbytevectorlist.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tbytevectorlist.h; sourceTree = ""; }; - 8E75708C09F319040080F1EE /* tdebug.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tdebug.cpp; sourceTree = ""; }; - 8E75708D09F319040080F1EE /* tdebug.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tdebug.h; sourceTree = ""; }; - 8E75708E09F319040080F1EE /* tfile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tfile.cpp; sourceTree = ""; }; - 8E75708F09F319040080F1EE /* tfile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tfile.h; sourceTree = ""; }; - 8E75709009F319040080F1EE /* tlist.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tlist.h; sourceTree = ""; }; - 8E75709109F319040080F1EE /* tlist.tcc */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = tlist.tcc; sourceTree = ""; }; - 8E75709209F319040080F1EE /* tmap.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tmap.h; sourceTree = ""; }; - 8E75709309F319040080F1EE /* tmap.tcc */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; path = tmap.tcc; sourceTree = ""; }; - 8E75709409F319040080F1EE /* tstring.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tstring.cpp; sourceTree = ""; }; - 8E75709509F319040080F1EE /* tstring.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tstring.h; sourceTree = ""; }; - 8E75709609F319040080F1EE /* tstringlist.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tstringlist.cpp; sourceTree = ""; }; - 8E75709709F319040080F1EE /* tstringlist.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tstringlist.h; sourceTree = ""; }; - 8E75709809F319040080F1EE /* unicode.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = unicode.cpp; sourceTree = ""; }; - 8E75709909F319040080F1EE /* unicode.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = unicode.h; sourceTree = ""; }; - 8E75711109F3190D0080F1EE /* tag_c.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = tag_c.cpp; sourceTree = ""; }; - 8E75711209F3190D0080F1EE /* tag_c.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = tag_c.h; sourceTree = ""; }; - 8E75712109F319570080F1EE /* config.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = config.h; path = Files/config.h; sourceTree = ""; }; - 8EE9CD4B0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = generalencapsulatedobjectframe.cpp; sourceTree = ""; }; - 8EE9CD4C0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = generalencapsulatedobjectframe.h; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -280,215 +427,300 @@ name = "Other Frameworks"; sourceTree = ""; }; - 8E75700C09F318D70080F1EE /* Source */ = { + 177A11E60CC570B700E06D16 /* ape */ = { isa = PBXGroup; children = ( - 8E75712109F319570080F1EE /* config.h */, - 8E75711009F3190D0080F1EE /* c */, - 8E75701909F319030080F1EE /* ape */, - 8E75702309F319030080F1EE /* audioproperties.cpp */, - 8E75702409F319030080F1EE /* audioproperties.h */, - 8E75702509F319030080F1EE /* fileref.cpp */, - 8E75702609F319030080F1EE /* fileref.h */, - 8E75702709F319030080F1EE /* flac */, - 8E75702F09F319030080F1EE /* mpc */, - 8E75703709F319030080F1EE /* mpeg */, - 8E75706B09F319040080F1EE /* ogg */, - 8E75708209F319040080F1EE /* tag.cpp */, - 8E75708309F319040080F1EE /* tag.h */, - 8E75708409F319040080F1EE /* toolkit */, - ); - name = Source; - sourceTree = ""; - }; - 8E75701909F319030080F1EE /* ape */ = { - isa = PBXGroup; - children = ( - 8E75701A09F319030080F1EE /* ape-tag-format.txt */, - 8E75701B09F319030080F1EE /* apefooter.cpp */, - 8E75701C09F319030080F1EE /* apefooter.h */, - 8E75701D09F319030080F1EE /* apeitem.cpp */, - 8E75701E09F319030080F1EE /* apeitem.h */, - 8E75701F09F319030080F1EE /* apetag.cpp */, - 8E75702009F319030080F1EE /* apetag.h */, + 177A11E70CC570B700E06D16 /* ape-tag-format.txt */, + 177A11E80CC570B700E06D16 /* apefooter.cpp */, + 177A11E90CC570B700E06D16 /* apefooter.h */, + 177A11EA0CC570B700E06D16 /* apeitem.cpp */, + 177A11EB0CC570B700E06D16 /* apeitem.h */, + 177A11EC0CC570B700E06D16 /* apetag.cpp */, + 177A11ED0CC570B700E06D16 /* apetag.h */, ); name = ape; - path = Files/taglib/ape; + path = taglib/taglib/ape; sourceTree = ""; }; - 8E75702709F319030080F1EE /* flac */ = { + 177A11F20CC570B700E06D16 /* flac */ = { isa = PBXGroup; children = ( - 8E75702809F319030080F1EE /* flacfile.cpp */, - 8E75702909F319030080F1EE /* flacfile.h */, - 8E75702A09F319030080F1EE /* flacproperties.cpp */, - 8E75702B09F319030080F1EE /* flacproperties.h */, - 8E75702C09F319030080F1EE /* flactag.h */, + 177A11F30CC570B700E06D16 /* flacfile.cpp */, + 177A11F40CC570B700E06D16 /* flacfile.h */, + 177A11F50CC570B700E06D16 /* flacproperties.cpp */, + 177A11F60CC570B700E06D16 /* flacproperties.h */, + 177A11F70CC570B700E06D16 /* flactag.h */, ); name = flac; - path = Files/taglib/flac; + path = taglib/taglib/flac; sourceTree = ""; }; - 8E75702F09F319030080F1EE /* mpc */ = { + 177A11F80CC570B700E06D16 /* m4a */ = { isa = PBXGroup; children = ( - 8E75703009F319030080F1EE /* combinedtag.h */, - 8E75703309F319030080F1EE /* mpcfile.cpp */, - 8E75703409F319030080F1EE /* mpcfile.h */, - 8E75703509F319030080F1EE /* mpcproperties.cpp */, - 8E75703609F319030080F1EE /* mpcproperties.h */, + 177A11F90CC570B700E06D16 /* boxfactory.cpp */, + 177A11FA0CC570B700E06D16 /* boxfactory.h */, + 177A11FB0CC570B700E06D16 /* itunesalbbox.cpp */, + 177A11FC0CC570B700E06D16 /* itunesalbbox.h */, + 177A11FD0CC570B700E06D16 /* itunesartbox.cpp */, + 177A11FE0CC570B700E06D16 /* itunesartbox.h */, + 177A11FF0CC570B700E06D16 /* itunescmtbox.cpp */, + 177A12000CC570B700E06D16 /* itunescmtbox.h */, + 177A12010CC570B700E06D16 /* itunescvrbox.cpp */, + 177A12020CC570B700E06D16 /* itunescvrbox.h */, + 177A12030CC570B700E06D16 /* itunesdatabox.cpp */, + 177A12040CC570B700E06D16 /* itunesdatabox.h */, + 177A12050CC570B700E06D16 /* itunesdaybox.cpp */, + 177A12060CC570B700E06D16 /* itunesdaybox.h */, + 177A12070CC570B700E06D16 /* itunesdiskbox.cpp */, + 177A12080CC570B700E06D16 /* itunesdiskbox.h */, + 177A12090CC570B700E06D16 /* itunesgenbox.cpp */, + 177A120A0CC570B700E06D16 /* itunesgenbox.h */, + 177A120B0CC570B700E06D16 /* itunesgrpbox.cpp */, + 177A120C0CC570B700E06D16 /* itunesgrpbox.h */, + 177A120D0CC570B700E06D16 /* itunesnambox.cpp */, + 177A120E0CC570B700E06D16 /* itunesnambox.h */, + 177A120F0CC570B700E06D16 /* itunestmpobox.cpp */, + 177A12100CC570B700E06D16 /* itunestmpobox.h */, + 177A12110CC570B700E06D16 /* itunestrknbox.cpp */, + 177A12120CC570B700E06D16 /* itunestrknbox.h */, + 177A12130CC570B700E06D16 /* ituneswrtbox.cpp */, + 177A12140CC570B700E06D16 /* ituneswrtbox.h */, + 177A12150CC570B700E06D16 /* mp4audioproperties.cpp */, + 177A12160CC570B700E06D16 /* mp4audioproperties.h */, + 177A12170CC570B700E06D16 /* mp4audiosampleentry.cpp */, + 177A12180CC570B700E06D16 /* mp4audiosampleentry.h */, + 177A12190CC570B700E06D16 /* mp4file.cpp */, + 177A121A0CC570B700E06D16 /* mp4file.h */, + 177A121B0CC570B700E06D16 /* mp4fourcc.cpp */, + 177A121C0CC570B700E06D16 /* mp4fourcc.h */, + 177A121D0CC570B700E06D16 /* mp4hdlrbox.cpp */, + 177A121E0CC570B700E06D16 /* mp4hdlrbox.h */, + 177A121F0CC570B700E06D16 /* mp4ilstbox.cpp */, + 177A12200CC570B700E06D16 /* mp4ilstbox.h */, + 177A12210CC570B700E06D16 /* mp4isobox.cpp */, + 177A12220CC570B700E06D16 /* mp4isobox.h */, + 177A12230CC570B700E06D16 /* mp4isofullbox.cpp */, + 177A12240CC570B700E06D16 /* mp4isofullbox.h */, + 177A12250CC570B700E06D16 /* mp4itunestag.cpp */, + 177A12260CC570B700E06D16 /* mp4itunestag.h */, + 177A12270CC570B700E06D16 /* mp4mdiabox.cpp */, + 177A12280CC570B700E06D16 /* mp4mdiabox.h */, + 177A12290CC570B700E06D16 /* mp4metabox.cpp */, + 177A122A0CC570B700E06D16 /* mp4metabox.h */, + 177A122B0CC570B700E06D16 /* mp4minfbox.cpp */, + 177A122C0CC570B700E06D16 /* mp4minfbox.h */, + 177A122D0CC570B700E06D16 /* mp4moovbox.cpp */, + 177A122E0CC570B700E06D16 /* mp4moovbox.h */, + 177A122F0CC570B700E06D16 /* mp4mvhdbox.cpp */, + 177A12300CC570B700E06D16 /* mp4mvhdbox.h */, + 177A12310CC570B700E06D16 /* mp4propsproxy.cpp */, + 177A12320CC570B700E06D16 /* mp4propsproxy.h */, + 177A12330CC570B700E06D16 /* mp4sampleentry.cpp */, + 177A12340CC570B700E06D16 /* mp4sampleentry.h */, + 177A12350CC570B700E06D16 /* mp4skipbox.cpp */, + 177A12360CC570B700E06D16 /* mp4skipbox.h */, + 177A12370CC570B700E06D16 /* mp4stblbox.cpp */, + 177A12380CC570B700E06D16 /* mp4stblbox.h */, + 177A12390CC570B700E06D16 /* mp4stsdbox.cpp */, + 177A123A0CC570B700E06D16 /* mp4stsdbox.h */, + 177A123B0CC570B700E06D16 /* mp4tagsproxy.cpp */, + 177A123C0CC570B700E06D16 /* mp4tagsproxy.h */, + 177A123D0CC570B700E06D16 /* mp4trakbox.cpp */, + 177A123E0CC570B700E06D16 /* mp4trakbox.h */, + 177A123F0CC570B700E06D16 /* mp4udtabox.cpp */, + 177A12400CC570B700E06D16 /* mp4udtabox.h */, + ); + name = m4a; + path = taglib/taglib/m4a; + sourceTree = ""; + }; + 177A12410CC570B700E06D16 /* mpc */ = { + isa = PBXGroup; + children = ( + 177A12420CC570B700E06D16 /* combinedtag.h */, + 177A12430CC570B700E06D16 /* mpcfile.cpp */, + 177A12440CC570B700E06D16 /* mpcfile.h */, + 177A12450CC570B700E06D16 /* mpcproperties.cpp */, + 177A12460CC570B700E06D16 /* mpcproperties.h */, ); name = mpc; - path = Files/taglib/mpc; + path = taglib/taglib/mpc; sourceTree = ""; }; - 8E75703709F319030080F1EE /* mpeg */ = { + 177A12470CC570B700E06D16 /* mpeg */ = { isa = PBXGroup; children = ( - 8E75703809F319030080F1EE /* id3v1 */, - 8E75703F09F319030080F1EE /* id3v2 */, - 8E75706309F319040080F1EE /* mpegfile.cpp */, - 8E75706409F319040080F1EE /* mpegfile.h */, - 8E75706509F319040080F1EE /* mpegheader.cpp */, - 8E75706609F319040080F1EE /* mpegheader.h */, - 8E75706709F319040080F1EE /* mpegproperties.cpp */, - 8E75706809F319040080F1EE /* mpegproperties.h */, - 8E75706909F319040080F1EE /* xingheader.cpp */, - 8E75706A09F319040080F1EE /* xingheader.h */, + 177A12480CC570B700E06D16 /* id3v1 */, + 177A124D0CC570B700E06D16 /* id3v2 */, + 177A126D0CC570B700E06D16 /* mpegfile.cpp */, + 177A126E0CC570B700E06D16 /* mpegfile.h */, + 177A126F0CC570B700E06D16 /* mpegheader.cpp */, + 177A12700CC570B700E06D16 /* mpegheader.h */, + 177A12710CC570B700E06D16 /* mpegproperties.cpp */, + 177A12720CC570B700E06D16 /* mpegproperties.h */, + 177A12730CC570B700E06D16 /* xingheader.cpp */, + 177A12740CC570B700E06D16 /* xingheader.h */, ); name = mpeg; - path = Files/taglib/mpeg; + path = taglib/taglib/mpeg; sourceTree = ""; }; - 8E75703809F319030080F1EE /* id3v1 */ = { + 177A12480CC570B700E06D16 /* id3v1 */ = { isa = PBXGroup; children = ( - 8E75703909F319030080F1EE /* id3v1genres.cpp */, - 8E75703A09F319030080F1EE /* id3v1genres.h */, - 8E75703B09F319030080F1EE /* id3v1tag.cpp */, - 8E75703C09F319030080F1EE /* id3v1tag.h */, + 177A12490CC570B700E06D16 /* id3v1genres.cpp */, + 177A124A0CC570B700E06D16 /* id3v1genres.h */, + 177A124B0CC570B700E06D16 /* id3v1tag.cpp */, + 177A124C0CC570B700E06D16 /* id3v1tag.h */, ); path = id3v1; sourceTree = ""; }; - 8E75703F09F319030080F1EE /* id3v2 */ = { + 177A124D0CC570B700E06D16 /* id3v2 */ = { isa = PBXGroup; children = ( - 8E75704009F319030080F1EE /* frames */, - 8E75704F09F319030080F1EE /* id3v2.4.0-frames.txt */, - 8E75705009F319030080F1EE /* id3v2.4.0-structure.txt */, - 8E75705109F319030080F1EE /* id3v2extendedheader.cpp */, - 8E75705209F319030080F1EE /* id3v2extendedheader.h */, - 8E75705309F319030080F1EE /* id3v2footer.cpp */, - 8E75705409F319030080F1EE /* id3v2footer.h */, - 8E75705509F319030080F1EE /* id3v2frame.cpp */, - 8E75705609F319030080F1EE /* id3v2frame.h */, - 8E75705709F319030080F1EE /* id3v2framefactory.cpp */, - 8E75705809F319030080F1EE /* id3v2framefactory.h */, - 8E75705909F319030080F1EE /* id3v2header.cpp */, - 8E75705A09F319030080F1EE /* id3v2header.h */, - 8E75705B09F319030080F1EE /* id3v2synchdata.cpp */, - 8E75705C09F319030080F1EE /* id3v2synchdata.h */, - 8E75705D09F319030080F1EE /* id3v2tag.cpp */, - 8E75705E09F319030080F1EE /* id3v2tag.h */, + 177A124E0CC570B700E06D16 /* frames */, + 177A125D0CC570B700E06D16 /* id3v2.4.0-frames.txt */, + 177A125E0CC570B700E06D16 /* id3v2.4.0-structure.txt */, + 177A125F0CC570B700E06D16 /* id3v2extendedheader.cpp */, + 177A12600CC570B700E06D16 /* id3v2extendedheader.h */, + 177A12610CC570B700E06D16 /* id3v2footer.cpp */, + 177A12620CC570B700E06D16 /* id3v2footer.h */, + 177A12630CC570B700E06D16 /* id3v2frame.cpp */, + 177A12640CC570B700E06D16 /* id3v2frame.h */, + 177A12650CC570B700E06D16 /* id3v2framefactory.cpp */, + 177A12660CC570B700E06D16 /* id3v2framefactory.h */, + 177A12670CC570B700E06D16 /* id3v2header.cpp */, + 177A12680CC570B700E06D16 /* id3v2header.h */, + 177A12690CC570B700E06D16 /* id3v2synchdata.cpp */, + 177A126A0CC570B700E06D16 /* id3v2synchdata.h */, + 177A126B0CC570B700E06D16 /* id3v2tag.cpp */, + 177A126C0CC570B700E06D16 /* id3v2tag.h */, ); path = id3v2; sourceTree = ""; }; - 8E75704009F319030080F1EE /* frames */ = { + 177A124E0CC570B700E06D16 /* frames */ = { isa = PBXGroup; children = ( - 8EE9CD4B0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.cpp */, - 8EE9CD4C0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.h */, - 8E75704109F319030080F1EE /* attachedpictureframe.cpp */, - 8E75704209F319030080F1EE /* attachedpictureframe.h */, - 8E75704309F319030080F1EE /* commentsframe.cpp */, - 8E75704409F319030080F1EE /* commentsframe.h */, - 8E75704709F319030080F1EE /* relativevolumeframe.cpp */, - 8E75704809F319030080F1EE /* relativevolumeframe.h */, - 8E75704909F319030080F1EE /* textidentificationframe.cpp */, - 8E75704A09F319030080F1EE /* textidentificationframe.h */, - 8E75704B09F319030080F1EE /* uniquefileidentifierframe.cpp */, - 8E75704C09F319030080F1EE /* uniquefileidentifierframe.h */, - 8E75704D09F319030080F1EE /* unknownframe.cpp */, - 8E75704E09F319030080F1EE /* unknownframe.h */, + 177A124F0CC570B700E06D16 /* attachedpictureframe.cpp */, + 177A12500CC570B700E06D16 /* attachedpictureframe.h */, + 177A12510CC570B700E06D16 /* commentsframe.cpp */, + 177A12520CC570B700E06D16 /* commentsframe.h */, + 177A12530CC570B700E06D16 /* generalencapsulatedobjectframe.cpp */, + 177A12540CC570B700E06D16 /* generalencapsulatedobjectframe.h */, + 177A12550CC570B700E06D16 /* relativevolumeframe.cpp */, + 177A12560CC570B700E06D16 /* relativevolumeframe.h */, + 177A12570CC570B700E06D16 /* textidentificationframe.cpp */, + 177A12580CC570B700E06D16 /* textidentificationframe.h */, + 177A12590CC570B700E06D16 /* uniquefileidentifierframe.cpp */, + 177A125A0CC570B700E06D16 /* uniquefileidentifierframe.h */, + 177A125B0CC570B700E06D16 /* unknownframe.cpp */, + 177A125C0CC570B700E06D16 /* unknownframe.h */, ); path = frames; sourceTree = ""; }; - 8E75706B09F319040080F1EE /* ogg */ = { + 177A12750CC570B700E06D16 /* ogg */ = { isa = PBXGroup; children = ( - 8E75706C09F319040080F1EE /* flac */, - 8E75707309F319040080F1EE /* oggfile.cpp */, - 8E75707409F319040080F1EE /* oggfile.h */, - 8E75707509F319040080F1EE /* oggpage.cpp */, - 8E75707609F319040080F1EE /* oggpage.h */, - 8E75707709F319040080F1EE /* oggpageheader.cpp */, - 8E75707809F319040080F1EE /* oggpageheader.h */, - 8E75707909F319040080F1EE /* vorbis */, - 8E75708009F319040080F1EE /* xiphcomment.cpp */, - 8E75708109F319040080F1EE /* xiphcomment.h */, + 177A12760CC570B700E06D16 /* flac */, + 177A12790CC570B700E06D16 /* oggfile.cpp */, + 177A127A0CC570B700E06D16 /* oggfile.h */, + 177A127B0CC570B700E06D16 /* oggpage.cpp */, + 177A127C0CC570B700E06D16 /* oggpage.h */, + 177A127D0CC570B700E06D16 /* oggpageheader.cpp */, + 177A127E0CC570B800E06D16 /* oggpageheader.h */, + 177A127F0CC570B800E06D16 /* vorbis */, + 177A12840CC570B800E06D16 /* xiphcomment.cpp */, + 177A12850CC570B800E06D16 /* xiphcomment.h */, ); name = ogg; - path = Files/taglib/ogg; + path = taglib/taglib/ogg; sourceTree = ""; }; - 8E75706C09F319040080F1EE /* flac */ = { + 177A12760CC570B700E06D16 /* flac */ = { isa = PBXGroup; children = ( - 8E75706F09F319040080F1EE /* oggflacfile.cpp */, - 8E75707009F319040080F1EE /* oggflacfile.h */, + 177A12770CC570B700E06D16 /* oggflacfile.cpp */, + 177A12780CC570B700E06D16 /* oggflacfile.h */, ); path = flac; sourceTree = ""; }; - 8E75707909F319040080F1EE /* vorbis */ = { + 177A127F0CC570B800E06D16 /* vorbis */ = { isa = PBXGroup; children = ( - 8E75707C09F319040080F1EE /* vorbisfile.cpp */, - 8E75707D09F319040080F1EE /* vorbisfile.h */, - 8E75707E09F319040080F1EE /* vorbisproperties.cpp */, - 8E75707F09F319040080F1EE /* vorbisproperties.h */, + 177A12800CC570B800E06D16 /* vorbisfile.cpp */, + 177A12810CC570B800E06D16 /* vorbisfile.h */, + 177A12820CC570B800E06D16 /* vorbisproperties.cpp */, + 177A12830CC570B800E06D16 /* vorbisproperties.h */, ); path = vorbis; sourceTree = ""; }; - 8E75708409F319040080F1EE /* toolkit */ = { + 177A12890CC570B800E06D16 /* toolkit */ = { isa = PBXGroup; children = ( - 8E75708709F319040080F1EE /* taglib.h */, - 8E75708809F319040080F1EE /* tbytevector.cpp */, - 8E75708909F319040080F1EE /* tbytevector.h */, - 8E75708A09F319040080F1EE /* tbytevectorlist.cpp */, - 8E75708B09F319040080F1EE /* tbytevectorlist.h */, - 8E75708C09F319040080F1EE /* tdebug.cpp */, - 8E75708D09F319040080F1EE /* tdebug.h */, - 8E75708E09F319040080F1EE /* tfile.cpp */, - 8E75708F09F319040080F1EE /* tfile.h */, - 8E75709009F319040080F1EE /* tlist.h */, - 8E75709109F319040080F1EE /* tlist.tcc */, - 8E75709209F319040080F1EE /* tmap.h */, - 8E75709309F319040080F1EE /* tmap.tcc */, - 8E75709409F319040080F1EE /* tstring.cpp */, - 8E75709509F319040080F1EE /* tstring.h */, - 8E75709609F319040080F1EE /* tstringlist.cpp */, - 8E75709709F319040080F1EE /* tstringlist.h */, - 8E75709809F319040080F1EE /* unicode.cpp */, - 8E75709909F319040080F1EE /* unicode.h */, + 177A128A0CC570B800E06D16 /* taglib.h */, + 177A128B0CC570B800E06D16 /* tbytevector.cpp */, + 177A128C0CC570B800E06D16 /* tbytevector.h */, + 177A128D0CC570B800E06D16 /* tbytevectorlist.cpp */, + 177A128E0CC570B800E06D16 /* tbytevectorlist.h */, + 177A128F0CC570B800E06D16 /* tdebug.cpp */, + 177A12900CC570B800E06D16 /* tdebug.h */, + 177A12910CC570B800E06D16 /* tfile.cpp */, + 177A12920CC570B800E06D16 /* tfile.h */, + 177A12930CC570B800E06D16 /* tfileio.h */, + 177A12940CC570B800E06D16 /* tlist.h */, + 177A12950CC570B800E06D16 /* tlist.tcc */, + 177A12960CC570B800E06D16 /* tlocalfileio.cpp */, + 177A12970CC570B800E06D16 /* tlocalfileio.h */, + 177A12980CC570B800E06D16 /* tmap.h */, + 177A12990CC570B800E06D16 /* tmap.tcc */, + 177A129A0CC570B800E06D16 /* tstring.cpp */, + 177A129B0CC570B800E06D16 /* tstring.h */, + 177A129C0CC570B800E06D16 /* tstringlist.cpp */, + 177A129D0CC570B800E06D16 /* tstringlist.h */, + 177A129E0CC570B800E06D16 /* unicode.cpp */, + 177A129F0CC570B800E06D16 /* unicode.h */, ); name = toolkit; - path = Files/taglib/toolkit; + path = taglib/taglib/toolkit; sourceTree = ""; }; - 8E75711009F3190D0080F1EE /* c */ = { + 177A134E0CC570C100E06D16 /* c */ = { isa = PBXGroup; children = ( - 8E75711109F3190D0080F1EE /* tag_c.cpp */, - 8E75711209F3190D0080F1EE /* tag_c.h */, + 177A134F0CC570C100E06D16 /* tag_c.cpp */, + 177A13500CC570C100E06D16 /* tag_c.h */, ); name = c; - path = Files/bindings/c; + path = taglib/bindings/c; + sourceTree = ""; + }; + 8E75700C09F318D70080F1EE /* Source */ = { + isa = PBXGroup; + children = ( + 177A137B0CC5719200E06D16 /* config.h */, + 177A134E0CC570C100E06D16 /* c */, + 177A11E60CC570B700E06D16 /* ape */, + 177A11EE0CC570B700E06D16 /* audioproperties.cpp */, + 177A11EF0CC570B700E06D16 /* audioproperties.h */, + 177A11F00CC570B700E06D16 /* fileref.cpp */, + 177A11F10CC570B700E06D16 /* fileref.h */, + 177A11F20CC570B700E06D16 /* flac */, + 177A11F80CC570B700E06D16 /* m4a */, + 177A12410CC570B700E06D16 /* mpc */, + 177A12470CC570B700E06D16 /* mpeg */, + 177A12750CC570B700E06D16 /* ogg */, + 177A12860CC570B800E06D16 /* tag.cpp */, + 177A12870CC570B800E06D16 /* tag.h */, + 177A12880CC570B800E06D16 /* taglib_export.h */, + 177A12890CC570B800E06D16 /* toolkit */, + ); + name = Source; sourceTree = ""; }; /* End PBXGroup section */ @@ -498,57 +730,96 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( - 8E75709C09F319040080F1EE /* apefooter.h in Headers */, - 8E75709E09F319040080F1EE /* apeitem.h in Headers */, - 8E7570A009F319040080F1EE /* apetag.h in Headers */, - 8E7570A409F319040080F1EE /* audioproperties.h in Headers */, - 8E7570A609F319040080F1EE /* fileref.h in Headers */, - 8E7570A809F319040080F1EE /* flacfile.h in Headers */, - 8E7570AA09F319040080F1EE /* flacproperties.h in Headers */, - 8E7570AB09F319040080F1EE /* flactag.h in Headers */, - 8E7570AE09F319040080F1EE /* combinedtag.h in Headers */, - 8E7570B209F319040080F1EE /* mpcfile.h in Headers */, - 8E7570B409F319040080F1EE /* mpcproperties.h in Headers */, - 8E7570B609F319040080F1EE /* id3v1genres.h in Headers */, - 8E7570B809F319040080F1EE /* id3v1tag.h in Headers */, - 8E7570BC09F319040080F1EE /* attachedpictureframe.h in Headers */, - 8E7570BE09F319040080F1EE /* commentsframe.h in Headers */, - 8E7570C209F319040080F1EE /* relativevolumeframe.h in Headers */, - 8E7570C409F319040080F1EE /* textidentificationframe.h in Headers */, - 8E7570C609F319040080F1EE /* uniquefileidentifierframe.h in Headers */, - 8E7570C809F319040080F1EE /* unknownframe.h in Headers */, - 8E7570CC09F319040080F1EE /* id3v2extendedheader.h in Headers */, - 8E7570CE09F319040080F1EE /* id3v2footer.h in Headers */, - 8E7570D009F319040080F1EE /* id3v2frame.h in Headers */, - 8E7570D209F319040080F1EE /* id3v2framefactory.h in Headers */, - 8E7570D409F319040080F1EE /* id3v2header.h in Headers */, - 8E7570D609F319040080F1EE /* id3v2synchdata.h in Headers */, - 8E7570D809F319040080F1EE /* id3v2tag.h in Headers */, - 8E7570DE09F319040080F1EE /* mpegfile.h in Headers */, - 8E7570E009F319040080F1EE /* mpegheader.h in Headers */, - 8E7570E209F319040080F1EE /* mpegproperties.h in Headers */, - 8E7570E409F319040080F1EE /* xingheader.h in Headers */, - 8E7570E809F319040080F1EE /* oggflacfile.h in Headers */, - 8E7570EC09F319040080F1EE /* oggfile.h in Headers */, - 8E7570EE09F319040080F1EE /* oggpage.h in Headers */, - 8E7570F009F319040080F1EE /* oggpageheader.h in Headers */, - 8E7570F409F319040080F1EE /* vorbisfile.h in Headers */, - 8E7570F609F319040080F1EE /* vorbisproperties.h in Headers */, - 8E7570F809F319040080F1EE /* xiphcomment.h in Headers */, - 8E7570FA09F319040080F1EE /* tag.h in Headers */, - 8E7570FD09F319040080F1EE /* taglib.h in Headers */, - 8E7570FF09F319040080F1EE /* tbytevector.h in Headers */, - 8E75710109F319040080F1EE /* tbytevectorlist.h in Headers */, - 8E75710309F319040080F1EE /* tdebug.h in Headers */, - 8E75710509F319040080F1EE /* tfile.h in Headers */, - 8E75710609F319040080F1EE /* tlist.h in Headers */, - 8E75710809F319040080F1EE /* tmap.h in Headers */, - 8E75710B09F319040080F1EE /* tstring.h in Headers */, - 8E75710D09F319040080F1EE /* tstringlist.h in Headers */, - 8E75710F09F319040080F1EE /* unicode.h in Headers */, - 8E75711409F3190D0080F1EE /* tag_c.h in Headers */, - 8E75712209F319570080F1EE /* config.h in Headers */, - 8EE9CD4E0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.h in Headers */, + 177A12A20CC570B800E06D16 /* apefooter.h in Headers */, + 177A12A40CC570B800E06D16 /* apeitem.h in Headers */, + 177A12A60CC570B800E06D16 /* apetag.h in Headers */, + 177A12A80CC570B800E06D16 /* audioproperties.h in Headers */, + 177A12AA0CC570B800E06D16 /* fileref.h in Headers */, + 177A12AC0CC570B800E06D16 /* flacfile.h in Headers */, + 177A12AE0CC570B800E06D16 /* flacproperties.h in Headers */, + 177A12AF0CC570B800E06D16 /* flactag.h in Headers */, + 177A12B10CC570B800E06D16 /* boxfactory.h in Headers */, + 177A12B30CC570B800E06D16 /* itunesalbbox.h in Headers */, + 177A12B50CC570B800E06D16 /* itunesartbox.h in Headers */, + 177A12B70CC570B800E06D16 /* itunescmtbox.h in Headers */, + 177A12B90CC570B800E06D16 /* itunescvrbox.h in Headers */, + 177A12BB0CC570B800E06D16 /* itunesdatabox.h in Headers */, + 177A12BD0CC570B800E06D16 /* itunesdaybox.h in Headers */, + 177A12BF0CC570B800E06D16 /* itunesdiskbox.h in Headers */, + 177A12C10CC570B800E06D16 /* itunesgenbox.h in Headers */, + 177A12C30CC570B800E06D16 /* itunesgrpbox.h in Headers */, + 177A12C50CC570B800E06D16 /* itunesnambox.h in Headers */, + 177A12C70CC570B800E06D16 /* itunestmpobox.h in Headers */, + 177A12C90CC570B800E06D16 /* itunestrknbox.h in Headers */, + 177A12CB0CC570B800E06D16 /* ituneswrtbox.h in Headers */, + 177A12CD0CC570B800E06D16 /* mp4audioproperties.h in Headers */, + 177A12CF0CC570B800E06D16 /* mp4audiosampleentry.h in Headers */, + 177A12D10CC570B800E06D16 /* mp4file.h in Headers */, + 177A12D30CC570B800E06D16 /* mp4fourcc.h in Headers */, + 177A12D50CC570B800E06D16 /* mp4hdlrbox.h in Headers */, + 177A12D70CC570B800E06D16 /* mp4ilstbox.h in Headers */, + 177A12D90CC570B800E06D16 /* mp4isobox.h in Headers */, + 177A12DB0CC570B800E06D16 /* mp4isofullbox.h in Headers */, + 177A12DD0CC570B800E06D16 /* mp4itunestag.h in Headers */, + 177A12DF0CC570B800E06D16 /* mp4mdiabox.h in Headers */, + 177A12E10CC570B800E06D16 /* mp4metabox.h in Headers */, + 177A12E30CC570B800E06D16 /* mp4minfbox.h in Headers */, + 177A12E50CC570B800E06D16 /* mp4moovbox.h in Headers */, + 177A12E70CC570B800E06D16 /* mp4mvhdbox.h in Headers */, + 177A12E90CC570B800E06D16 /* mp4propsproxy.h in Headers */, + 177A12EB0CC570B800E06D16 /* mp4sampleentry.h in Headers */, + 177A12ED0CC570B800E06D16 /* mp4skipbox.h in Headers */, + 177A12EF0CC570B800E06D16 /* mp4stblbox.h in Headers */, + 177A12F10CC570B800E06D16 /* mp4stsdbox.h in Headers */, + 177A12F30CC570B800E06D16 /* mp4tagsproxy.h in Headers */, + 177A12F50CC570B800E06D16 /* mp4trakbox.h in Headers */, + 177A12F70CC570B800E06D16 /* mp4udtabox.h in Headers */, + 177A12F80CC570B800E06D16 /* combinedtag.h in Headers */, + 177A12FA0CC570B800E06D16 /* mpcfile.h in Headers */, + 177A12FC0CC570B800E06D16 /* mpcproperties.h in Headers */, + 177A12FE0CC570B800E06D16 /* id3v1genres.h in Headers */, + 177A13000CC570B800E06D16 /* id3v1tag.h in Headers */, + 177A13020CC570B800E06D16 /* attachedpictureframe.h in Headers */, + 177A13040CC570B800E06D16 /* commentsframe.h in Headers */, + 177A13060CC570B800E06D16 /* generalencapsulatedobjectframe.h in Headers */, + 177A13080CC570B800E06D16 /* relativevolumeframe.h in Headers */, + 177A130A0CC570B800E06D16 /* textidentificationframe.h in Headers */, + 177A130C0CC570B800E06D16 /* uniquefileidentifierframe.h in Headers */, + 177A130E0CC570B800E06D16 /* unknownframe.h in Headers */, + 177A13120CC570B800E06D16 /* id3v2extendedheader.h in Headers */, + 177A13140CC570B800E06D16 /* id3v2footer.h in Headers */, + 177A13160CC570B800E06D16 /* id3v2frame.h in Headers */, + 177A13180CC570B800E06D16 /* id3v2framefactory.h in Headers */, + 177A131A0CC570B800E06D16 /* id3v2header.h in Headers */, + 177A131C0CC570B800E06D16 /* id3v2synchdata.h in Headers */, + 177A131E0CC570B800E06D16 /* id3v2tag.h in Headers */, + 177A13200CC570B800E06D16 /* mpegfile.h in Headers */, + 177A13220CC570B800E06D16 /* mpegheader.h in Headers */, + 177A13240CC570B800E06D16 /* mpegproperties.h in Headers */, + 177A13260CC570B800E06D16 /* xingheader.h in Headers */, + 177A13280CC570B800E06D16 /* oggflacfile.h in Headers */, + 177A132A0CC570B800E06D16 /* oggfile.h in Headers */, + 177A132C0CC570B800E06D16 /* oggpage.h in Headers */, + 177A132E0CC570B800E06D16 /* oggpageheader.h in Headers */, + 177A13300CC570B800E06D16 /* vorbisfile.h in Headers */, + 177A13320CC570B800E06D16 /* vorbisproperties.h in Headers */, + 177A13340CC570B800E06D16 /* xiphcomment.h in Headers */, + 177A13360CC570B800E06D16 /* tag.h in Headers */, + 177A13370CC570B800E06D16 /* taglib_export.h in Headers */, + 177A13380CC570B800E06D16 /* taglib.h in Headers */, + 177A133A0CC570B800E06D16 /* tbytevector.h in Headers */, + 177A133C0CC570B800E06D16 /* tbytevectorlist.h in Headers */, + 177A133E0CC570B800E06D16 /* tdebug.h in Headers */, + 177A13400CC570B800E06D16 /* tfile.h in Headers */, + 177A13410CC570B800E06D16 /* tfileio.h in Headers */, + 177A13420CC570B800E06D16 /* tlist.h in Headers */, + 177A13450CC570B800E06D16 /* tlocalfileio.h in Headers */, + 177A13460CC570B800E06D16 /* tmap.h in Headers */, + 177A13490CC570B800E06D16 /* tstring.h in Headers */, + 177A134B0CC570B800E06D16 /* tstringlist.h in Headers */, + 177A134D0CC570B800E06D16 /* unicode.h in Headers */, + 177A13520CC570C100E06D16 /* tag_c.h in Headers */, + 177A137C0CC5719200E06D16 /* config.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -596,11 +867,6 @@ buildActionMask = 2147483647; files = ( 8DC2EF530486A6940098B216 /* InfoPlist.strings in Resources */, - 8E75709A09F319040080F1EE /* ape-tag-format.txt in Resources */, - 8E7570C909F319040080F1EE /* id3v2.4.0-frames.txt in Resources */, - 8E7570CA09F319040080F1EE /* id3v2.4.0-structure.txt in Resources */, - 8E75710709F319040080F1EE /* tlist.tcc in Resources */, - 8E75710909F319040080F1EE /* tmap.tcc in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -611,51 +877,88 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - 8E75709B09F319040080F1EE /* apefooter.cpp in Sources */, - 8E75709D09F319040080F1EE /* apeitem.cpp in Sources */, - 8E75709F09F319040080F1EE /* apetag.cpp in Sources */, - 8E7570A309F319040080F1EE /* audioproperties.cpp in Sources */, - 8E7570A509F319040080F1EE /* fileref.cpp in Sources */, - 8E7570A709F319040080F1EE /* flacfile.cpp in Sources */, - 8E7570A909F319040080F1EE /* flacproperties.cpp in Sources */, - 8E7570B109F319040080F1EE /* mpcfile.cpp in Sources */, - 8E7570B309F319040080F1EE /* mpcproperties.cpp in Sources */, - 8E7570B509F319040080F1EE /* id3v1genres.cpp in Sources */, - 8E7570B709F319040080F1EE /* id3v1tag.cpp in Sources */, - 8E7570BB09F319040080F1EE /* attachedpictureframe.cpp in Sources */, - 8E7570BD09F319040080F1EE /* commentsframe.cpp in Sources */, - 8E7570C109F319040080F1EE /* relativevolumeframe.cpp in Sources */, - 8E7570C309F319040080F1EE /* textidentificationframe.cpp in Sources */, - 8E7570C509F319040080F1EE /* uniquefileidentifierframe.cpp in Sources */, - 8E7570C709F319040080F1EE /* unknownframe.cpp in Sources */, - 8E7570CB09F319040080F1EE /* id3v2extendedheader.cpp in Sources */, - 8E7570CD09F319040080F1EE /* id3v2footer.cpp in Sources */, - 8E7570CF09F319040080F1EE /* id3v2frame.cpp in Sources */, - 8E7570D109F319040080F1EE /* id3v2framefactory.cpp in Sources */, - 8E7570D309F319040080F1EE /* id3v2header.cpp in Sources */, - 8E7570D509F319040080F1EE /* id3v2synchdata.cpp in Sources */, - 8E7570D709F319040080F1EE /* id3v2tag.cpp in Sources */, - 8E7570DD09F319040080F1EE /* mpegfile.cpp in Sources */, - 8E7570DF09F319040080F1EE /* mpegheader.cpp in Sources */, - 8E7570E109F319040080F1EE /* mpegproperties.cpp in Sources */, - 8E7570E309F319040080F1EE /* xingheader.cpp in Sources */, - 8E7570E709F319040080F1EE /* oggflacfile.cpp in Sources */, - 8E7570EB09F319040080F1EE /* oggfile.cpp in Sources */, - 8E7570ED09F319040080F1EE /* oggpage.cpp in Sources */, - 8E7570EF09F319040080F1EE /* oggpageheader.cpp in Sources */, - 8E7570F309F319040080F1EE /* vorbisfile.cpp in Sources */, - 8E7570F509F319040080F1EE /* vorbisproperties.cpp in Sources */, - 8E7570F709F319040080F1EE /* xiphcomment.cpp in Sources */, - 8E7570F909F319040080F1EE /* tag.cpp in Sources */, - 8E7570FE09F319040080F1EE /* tbytevector.cpp in Sources */, - 8E75710009F319040080F1EE /* tbytevectorlist.cpp in Sources */, - 8E75710209F319040080F1EE /* tdebug.cpp in Sources */, - 8E75710409F319040080F1EE /* tfile.cpp in Sources */, - 8E75710A09F319040080F1EE /* tstring.cpp in Sources */, - 8E75710C09F319040080F1EE /* tstringlist.cpp in Sources */, - 8E75710E09F319040080F1EE /* unicode.cpp in Sources */, - 8E75711309F3190D0080F1EE /* tag_c.cpp in Sources */, - 8EE9CD4D0C49B7ED00CD3E52 /* generalencapsulatedobjectframe.cpp in Sources */, + 177A12A10CC570B800E06D16 /* apefooter.cpp in Sources */, + 177A12A30CC570B800E06D16 /* apeitem.cpp in Sources */, + 177A12A50CC570B800E06D16 /* apetag.cpp in Sources */, + 177A12A70CC570B800E06D16 /* audioproperties.cpp in Sources */, + 177A12A90CC570B800E06D16 /* fileref.cpp in Sources */, + 177A12AB0CC570B800E06D16 /* flacfile.cpp in Sources */, + 177A12AD0CC570B800E06D16 /* flacproperties.cpp in Sources */, + 177A12B00CC570B800E06D16 /* boxfactory.cpp in Sources */, + 177A12B20CC570B800E06D16 /* itunesalbbox.cpp in Sources */, + 177A12B40CC570B800E06D16 /* itunesartbox.cpp in Sources */, + 177A12B60CC570B800E06D16 /* itunescmtbox.cpp in Sources */, + 177A12B80CC570B800E06D16 /* itunescvrbox.cpp in Sources */, + 177A12BA0CC570B800E06D16 /* itunesdatabox.cpp in Sources */, + 177A12BC0CC570B800E06D16 /* itunesdaybox.cpp in Sources */, + 177A12BE0CC570B800E06D16 /* itunesdiskbox.cpp in Sources */, + 177A12C00CC570B800E06D16 /* itunesgenbox.cpp in Sources */, + 177A12C20CC570B800E06D16 /* itunesgrpbox.cpp in Sources */, + 177A12C40CC570B800E06D16 /* itunesnambox.cpp in Sources */, + 177A12C60CC570B800E06D16 /* itunestmpobox.cpp in Sources */, + 177A12C80CC570B800E06D16 /* itunestrknbox.cpp in Sources */, + 177A12CA0CC570B800E06D16 /* ituneswrtbox.cpp in Sources */, + 177A12CC0CC570B800E06D16 /* mp4audioproperties.cpp in Sources */, + 177A12CE0CC570B800E06D16 /* mp4audiosampleentry.cpp in Sources */, + 177A12D00CC570B800E06D16 /* mp4file.cpp in Sources */, + 177A12D20CC570B800E06D16 /* mp4fourcc.cpp in Sources */, + 177A12D40CC570B800E06D16 /* mp4hdlrbox.cpp in Sources */, + 177A12D60CC570B800E06D16 /* mp4ilstbox.cpp in Sources */, + 177A12D80CC570B800E06D16 /* mp4isobox.cpp in Sources */, + 177A12DA0CC570B800E06D16 /* mp4isofullbox.cpp in Sources */, + 177A12DC0CC570B800E06D16 /* mp4itunestag.cpp in Sources */, + 177A12DE0CC570B800E06D16 /* mp4mdiabox.cpp in Sources */, + 177A12E00CC570B800E06D16 /* mp4metabox.cpp in Sources */, + 177A12E20CC570B800E06D16 /* mp4minfbox.cpp in Sources */, + 177A12E40CC570B800E06D16 /* mp4moovbox.cpp in Sources */, + 177A12E60CC570B800E06D16 /* mp4mvhdbox.cpp in Sources */, + 177A12E80CC570B800E06D16 /* mp4propsproxy.cpp in Sources */, + 177A12EA0CC570B800E06D16 /* mp4sampleentry.cpp in Sources */, + 177A12EC0CC570B800E06D16 /* mp4skipbox.cpp in Sources */, + 177A12EE0CC570B800E06D16 /* mp4stblbox.cpp in Sources */, + 177A12F00CC570B800E06D16 /* mp4stsdbox.cpp in Sources */, + 177A12F20CC570B800E06D16 /* mp4tagsproxy.cpp in Sources */, + 177A12F40CC570B800E06D16 /* mp4trakbox.cpp in Sources */, + 177A12F60CC570B800E06D16 /* mp4udtabox.cpp in Sources */, + 177A12F90CC570B800E06D16 /* mpcfile.cpp in Sources */, + 177A12FB0CC570B800E06D16 /* mpcproperties.cpp in Sources */, + 177A12FD0CC570B800E06D16 /* id3v1genres.cpp in Sources */, + 177A12FF0CC570B800E06D16 /* id3v1tag.cpp in Sources */, + 177A13010CC570B800E06D16 /* attachedpictureframe.cpp in Sources */, + 177A13030CC570B800E06D16 /* commentsframe.cpp in Sources */, + 177A13050CC570B800E06D16 /* generalencapsulatedobjectframe.cpp in Sources */, + 177A13070CC570B800E06D16 /* relativevolumeframe.cpp in Sources */, + 177A13090CC570B800E06D16 /* textidentificationframe.cpp in Sources */, + 177A130B0CC570B800E06D16 /* uniquefileidentifierframe.cpp in Sources */, + 177A130D0CC570B800E06D16 /* unknownframe.cpp in Sources */, + 177A13110CC570B800E06D16 /* id3v2extendedheader.cpp in Sources */, + 177A13130CC570B800E06D16 /* id3v2footer.cpp in Sources */, + 177A13150CC570B800E06D16 /* id3v2frame.cpp in Sources */, + 177A13170CC570B800E06D16 /* id3v2framefactory.cpp in Sources */, + 177A13190CC570B800E06D16 /* id3v2header.cpp in Sources */, + 177A131B0CC570B800E06D16 /* id3v2synchdata.cpp in Sources */, + 177A131D0CC570B800E06D16 /* id3v2tag.cpp in Sources */, + 177A131F0CC570B800E06D16 /* mpegfile.cpp in Sources */, + 177A13210CC570B800E06D16 /* mpegheader.cpp in Sources */, + 177A13230CC570B800E06D16 /* mpegproperties.cpp in Sources */, + 177A13250CC570B800E06D16 /* xingheader.cpp in Sources */, + 177A13270CC570B800E06D16 /* oggflacfile.cpp in Sources */, + 177A13290CC570B800E06D16 /* oggfile.cpp in Sources */, + 177A132B0CC570B800E06D16 /* oggpage.cpp in Sources */, + 177A132D0CC570B800E06D16 /* oggpageheader.cpp in Sources */, + 177A132F0CC570B800E06D16 /* vorbisfile.cpp in Sources */, + 177A13310CC570B800E06D16 /* vorbisproperties.cpp in Sources */, + 177A13330CC570B800E06D16 /* xiphcomment.cpp in Sources */, + 177A13350CC570B800E06D16 /* tag.cpp in Sources */, + 177A13390CC570B800E06D16 /* tbytevector.cpp in Sources */, + 177A133B0CC570B800E06D16 /* tbytevectorlist.cpp in Sources */, + 177A133D0CC570B800E06D16 /* tdebug.cpp in Sources */, + 177A133F0CC570B800E06D16 /* tfile.cpp in Sources */, + 177A13440CC570B800E06D16 /* tlocalfileio.cpp in Sources */, + 177A13480CC570B800E06D16 /* tstring.cpp in Sources */, + 177A134A0CC570B800E06D16 /* tstringlist.cpp in Sources */, + 177A134C0CC570B800E06D16 /* unicode.cpp in Sources */, + 177A13510CC570C100E06D16 /* tag_c.cpp in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -686,6 +989,10 @@ GCC_OPTIMIZATION_LEVEL = 0; GCC_PRECOMPILE_PREFIX_HEADER = NO; GCC_PREFIX_HEADER = ""; + HEADER_SEARCH_PATHS = ( + "$(inherited)", + "taglib/**", + ); INFOPLIST_FILE = Info.plist; INSTALL_PATH = "@loader_path/../Frameworks"; PRODUCT_NAME = TagLib; @@ -708,6 +1015,10 @@ GCC_MODEL_TUNING = G5; GCC_PRECOMPILE_PREFIX_HEADER = NO; GCC_PREFIX_HEADER = ""; + HEADER_SEARCH_PATHS = ( + "$(inherited)", + "taglib/**", + ); INFOPLIST_FILE = Info.plist; INSTALL_PATH = "@loader_path/../Frameworks"; PRODUCT_NAME = TagLib; diff --git a/Frameworks/TagLib/Files/AUTHORS b/Frameworks/TagLib/taglib/AUTHORS old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/AUTHORS rename to Frameworks/TagLib/taglib/AUTHORS diff --git a/Frameworks/TagLib/Files/COPYING b/Frameworks/TagLib/taglib/COPYING old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/COPYING rename to Frameworks/TagLib/taglib/COPYING diff --git a/Frameworks/TagLib/Files/INSTALL b/Frameworks/TagLib/taglib/INSTALL old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/INSTALL rename to Frameworks/TagLib/taglib/INSTALL diff --git a/Frameworks/TagLib/taglib/bindings/README b/Frameworks/TagLib/taglib/bindings/README new file mode 100755 index 000000000..f9e912463 --- /dev/null +++ b/Frameworks/TagLib/taglib/bindings/README @@ -0,0 +1,6 @@ +There are a few other people that have done bindings externally that I have +been made aware of. I have not personally reviewed these bindings, but I'm +listing them here so that those who find them useful are able to find them: + +- Ruby - http://www.hakubi.us/ruby-taglib/ +- Python - http://namingmuse.berlios.de/ diff --git a/Frameworks/TagLib/Files/bindings/c/tag_c.cpp b/Frameworks/TagLib/taglib/bindings/c/tag_c.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/bindings/c/tag_c.cpp rename to Frameworks/TagLib/taglib/bindings/c/tag_c.cpp diff --git a/Frameworks/TagLib/Files/bindings/c/tag_c.h b/Frameworks/TagLib/taglib/bindings/c/tag_c.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/bindings/c/tag_c.h rename to Frameworks/TagLib/taglib/bindings/c/tag_c.h diff --git a/Frameworks/TagLib/Files/config.h b/Frameworks/TagLib/taglib/config.h similarity index 91% rename from Frameworks/TagLib/Files/config.h rename to Frameworks/TagLib/taglib/config.h index 1df8d2bb0..d583515a1 100644 --- a/Frameworks/TagLib/Files/config.h +++ b/Frameworks/TagLib/taglib/config.h @@ -1,4 +1,4 @@ -/* config.h. Generated by configure. */ +/* config.h. Generated from config.h.in by configure. */ /* config.h.in. Generated from configure.in by autoheader. */ /* Define to 1 if you have the header file. */ @@ -28,9 +28,6 @@ /* Define to 1 if you have the header file. */ #define HAVE_SYS_TYPES_H 1 -/* C++ compiler supports template repository */ -#define HAVE_TEMPLATE_REPOSITORY 1 - /* Define to 1 if you have the header file. */ #define HAVE_UNISTD_H 1 @@ -62,4 +59,4 @@ #define STDC_HEADERS 1 /* Version number of package */ -#define VERSION "0.1" +#define VERSION "1.4" diff --git a/Frameworks/TagLib/Files/taglib/ape/ape-tag-format.txt b/Frameworks/TagLib/taglib/taglib/ape/ape-tag-format.txt old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ape/ape-tag-format.txt rename to Frameworks/TagLib/taglib/taglib/ape/ape-tag-format.txt diff --git a/Frameworks/TagLib/Files/taglib/ape/apefooter.cpp b/Frameworks/TagLib/taglib/taglib/ape/apefooter.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ape/apefooter.cpp rename to Frameworks/TagLib/taglib/taglib/ape/apefooter.cpp diff --git a/Frameworks/TagLib/Files/taglib/ape/apefooter.h b/Frameworks/TagLib/taglib/taglib/ape/apefooter.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ape/apefooter.h rename to Frameworks/TagLib/taglib/taglib/ape/apefooter.h diff --git a/Frameworks/TagLib/Files/taglib/ape/apeitem.cpp b/Frameworks/TagLib/taglib/taglib/ape/apeitem.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ape/apeitem.cpp rename to Frameworks/TagLib/taglib/taglib/ape/apeitem.cpp diff --git a/Frameworks/TagLib/Files/taglib/ape/apeitem.h b/Frameworks/TagLib/taglib/taglib/ape/apeitem.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ape/apeitem.h rename to Frameworks/TagLib/taglib/taglib/ape/apeitem.h diff --git a/Frameworks/TagLib/Files/taglib/ape/apetag.cpp b/Frameworks/TagLib/taglib/taglib/ape/apetag.cpp old mode 100644 new mode 100755 similarity index 95% rename from Frameworks/TagLib/Files/taglib/ape/apetag.cpp rename to Frameworks/TagLib/taglib/taglib/ape/apetag.cpp index 58ca1389e..ef3c3cd0f --- a/Frameworks/TagLib/Files/taglib/ape/apetag.cpp +++ b/Frameworks/TagLib/taglib/taglib/ape/apetag.cpp @@ -19,6 +19,14 @@ * USA * ***************************************************************************/ +#ifdef __SUNPRO_CC +// Sun Studio finds multiple specializations of Map because +// it considers specializations with and without class types +// to be different; this define forces Map to use only the +// specialization with the class keyword. +#define WANT_CLASS_INSTANTIATION_OF_MAP (1) +#endif + #include #include #include diff --git a/Frameworks/TagLib/Files/taglib/ape/apetag.h b/Frameworks/TagLib/taglib/taglib/ape/apetag.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ape/apetag.h rename to Frameworks/TagLib/taglib/taglib/ape/apetag.h diff --git a/Frameworks/TagLib/Files/taglib/audioproperties.cpp b/Frameworks/TagLib/taglib/taglib/audioproperties.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/audioproperties.cpp rename to Frameworks/TagLib/taglib/taglib/audioproperties.cpp diff --git a/Frameworks/TagLib/Files/taglib/audioproperties.h b/Frameworks/TagLib/taglib/taglib/audioproperties.h old mode 100644 new mode 100755 similarity index 98% rename from Frameworks/TagLib/Files/taglib/audioproperties.h rename to Frameworks/TagLib/taglib/taglib/audioproperties.h index 23c696179..662729f75 --- a/Frameworks/TagLib/Files/taglib/audioproperties.h +++ b/Frameworks/TagLib/taglib/taglib/audioproperties.h @@ -22,6 +22,8 @@ #ifndef TAGLIB_AUDIOPROPERTIES_H #define TAGLIB_AUDIOPROPERTIES_H +#include "taglib_export.h" + namespace TagLib { //! A simple, abstract interface to common audio properties @@ -33,7 +35,7 @@ namespace TagLib { * interface that is sufficient for most applications. */ - class AudioProperties + class TAGLIB_EXPORT AudioProperties { public: diff --git a/Frameworks/TagLib/Files/taglib/fileref.cpp b/Frameworks/TagLib/taglib/taglib/fileref.cpp old mode 100644 new mode 100755 similarity index 93% rename from Frameworks/TagLib/Files/taglib/fileref.cpp rename to Frameworks/TagLib/taglib/taglib/fileref.cpp index 2aaaa2408..561077400 --- a/Frameworks/TagLib/Files/taglib/fileref.cpp +++ b/Frameworks/TagLib/taglib/taglib/fileref.cpp @@ -27,6 +27,7 @@ #include "vorbisfile.h" #include "flacfile.h" #include "mpcfile.h" +#include "mp4file.h" using namespace TagLib; @@ -109,6 +110,8 @@ StringList FileRef::defaultFileExtensions() l.append("flac"); l.append("mp3"); l.append("mpc"); + l.append("m4a"); + //l.append("m4p"); return l; } @@ -171,6 +174,10 @@ File *FileRef::create(const char *fileName, bool readAudioProperties, return new FLAC::File(fileName, readAudioProperties, audioPropertiesStyle); if(s.substr(s.size() - 4, 4).upper() == ".MPC") return new MPC::File(fileName, readAudioProperties, audioPropertiesStyle); + if(s.substr(s.size() - 4, 4).upper() == ".M4A") + return new MP4::File(fileName, readAudioProperties, audioPropertiesStyle); + //if(s.substr(s.size() - 4, 4).upper() == ".M4P") + //return new MP4::File(fileName, readAudioProperties, audioPropertiesStyle); } return 0; diff --git a/Frameworks/TagLib/Files/taglib/fileref.h b/Frameworks/TagLib/taglib/taglib/fileref.h old mode 100644 new mode 100755 similarity index 99% rename from Frameworks/TagLib/Files/taglib/fileref.h rename to Frameworks/TagLib/taglib/taglib/fileref.h index 74f3ac7cf..60db14258 --- a/Frameworks/TagLib/Files/taglib/fileref.h +++ b/Frameworks/TagLib/taglib/taglib/fileref.h @@ -24,6 +24,7 @@ #include +#include "taglib_export.h" #include "audioproperties.h" namespace TagLib { @@ -52,7 +53,7 @@ namespace TagLib { * \see addFileTypeResolver() */ - class FileRef + class TAGLIB_EXPORT FileRef { public: diff --git a/Frameworks/TagLib/Files/taglib/flac/flacfile.cpp b/Frameworks/TagLib/taglib/taglib/flac/flacfile.cpp old mode 100644 new mode 100755 similarity index 98% rename from Frameworks/TagLib/Files/taglib/flac/flacfile.cpp rename to Frameworks/TagLib/taglib/taglib/flac/flacfile.cpp index dcaf58ef5..fb44d9ea1 --- a/Frameworks/TagLib/Files/taglib/flac/flacfile.cpp +++ b/Frameworks/TagLib/taglib/taglib/flac/flacfile.cpp @@ -98,6 +98,13 @@ public: // public members //////////////////////////////////////////////////////////////////////////////// +FLAC::File::File(ID3v2::FrameFactory *frameFactory) : TagLib::File() +{ + d = new FilePrivate; + if (frameFactory) + d->ID3v2FrameFactory = frameFactory; +} + FLAC::File::File(const char *file, bool readProperties, Properties::ReadStyle propertiesStyle) : TagLib::File(file) @@ -130,6 +137,52 @@ FLAC::Properties *FLAC::File::audioProperties() const return d->properties; } +void FLAC::File::read(bool readProperties, Properties::ReadStyle propertiesStyle) +{ + // Look for an ID3v2 tag + + d->ID3v2Location = findID3v2(); + + if(d->ID3v2Location >= 0) { + + d->ID3v2Tag = new ID3v2::Tag(this, d->ID3v2Location, d->ID3v2FrameFactory); + + d->ID3v2OriginalSize = d->ID3v2Tag->header()->completeTagSize(); + + if(d->ID3v2Tag->header()->tagSize() <= 0) { + delete d->ID3v2Tag; + d->ID3v2Tag = 0; + } + else + d->hasID3v2 = true; + } + + // Look for an ID3v1 tag + + d->ID3v1Location = findID3v1(); + + if(d->ID3v1Location >= 0) { + d->ID3v1Tag = new ID3v1::Tag(this, d->ID3v1Location); + d->hasID3v1 = true; + } + + // Look for FLAC metadata, including vorbis comments + + scan(); + + if (!isValid()) return; + + if(d->hasXiphComment) + d->comment = new Ogg::XiphComment(xiphCommentData()); + + if(d->hasXiphComment || d->hasID3v2 || d->hasID3v1) + d->tag = new FLAC::Tag(d->comment, d->ID3v2Tag, d->ID3v1Tag); + else + d->tag = new FLAC::Tag(new Ogg::XiphComment); + + if(readProperties) + d->properties = new Properties(streamInfoData(), streamLength(), propertiesStyle); +} bool FLAC::File::save() { @@ -275,53 +328,6 @@ void FLAC::File::setID3v2FrameFactory(const ID3v2::FrameFactory *factory) // private members //////////////////////////////////////////////////////////////////////////////// -void FLAC::File::read(bool readProperties, Properties::ReadStyle propertiesStyle) -{ - // Look for an ID3v2 tag - - d->ID3v2Location = findID3v2(); - - if(d->ID3v2Location >= 0) { - - d->ID3v2Tag = new ID3v2::Tag(this, d->ID3v2Location, d->ID3v2FrameFactory); - - d->ID3v2OriginalSize = d->ID3v2Tag->header()->completeTagSize(); - - if(d->ID3v2Tag->header()->tagSize() <= 0) { - delete d->ID3v2Tag; - d->ID3v2Tag = 0; - } - else - d->hasID3v2 = true; - } - - // Look for an ID3v1 tag - - d->ID3v1Location = findID3v1(); - - if(d->ID3v1Location >= 0) { - d->ID3v1Tag = new ID3v1::Tag(this, d->ID3v1Location); - d->hasID3v1 = true; - } - - // Look for FLAC metadata, including vorbis comments - - scan(); - - if (!isValid()) return; - - if(d->hasXiphComment) - d->comment = new Ogg::XiphComment(xiphCommentData()); - - if(d->hasXiphComment || d->hasID3v2 || d->hasID3v1) - d->tag = new FLAC::Tag(d->comment, d->ID3v2Tag, d->ID3v1Tag); - else - d->tag = new FLAC::Tag(new Ogg::XiphComment); - - if(readProperties) - d->properties = new Properties(streamInfoData(), streamLength(), propertiesStyle); -} - ByteVector FLAC::File::streamInfoData() { if (isValid()) diff --git a/Frameworks/TagLib/Files/taglib/flac/flacfile.h b/Frameworks/TagLib/taglib/taglib/flac/flacfile.h old mode 100644 new mode 100755 similarity index 91% rename from Frameworks/TagLib/Files/taglib/flac/flacfile.h rename to Frameworks/TagLib/taglib/taglib/flac/flacfile.h index 67f20ee7b..b83b6c731 --- a/Frameworks/TagLib/Files/taglib/flac/flacfile.h +++ b/Frameworks/TagLib/taglib/taglib/flac/flacfile.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_FLACFILE_H #define TAGLIB_FLACFILE_H +#include "taglib_export.h" #include "tfile.h" #include "flacproperties.h" @@ -56,9 +57,15 @@ namespace TagLib { * information specific to FLAC files. */ - class File : public TagLib::File + class TAGLIB_EXPORT File : public TagLib::File { public: + /*! + * Contructs a FLAC file object without reading a file. Allows object + * fields to be set up before reading. + */ + File(ID3v2::FrameFactory *frameFactory = NULL); + /*! * Contructs a FLAC file from \a file. If \a readProperties is true the * file's audio properties will also be read using \a propertiesStyle. If @@ -104,6 +111,14 @@ namespace TagLib { */ virtual Properties *audioProperties() const; + /*! + * Reads from FLAC file. If \a readProperties is true the file's audio + * properties will also be read using \a propertiesStyle. If false, + * \a propertiesStyle is ignored. + */ + void read(bool readProperties = true, + Properties::ReadStyle propertiesStyle = Properties::Average); + /*! * Save the file. This will primarily save the XiphComment, but * will also keep any old ID3-tags up to date. If the file @@ -181,7 +196,6 @@ namespace TagLib { File(const File &); File &operator=(const File &); - void read(bool readProperties, Properties::ReadStyle propertiesStyle); void scan(); long findID3v2(); long findID3v1(); diff --git a/Frameworks/TagLib/Files/taglib/flac/flacproperties.cpp b/Frameworks/TagLib/taglib/taglib/flac/flacproperties.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/flac/flacproperties.cpp rename to Frameworks/TagLib/taglib/taglib/flac/flacproperties.cpp diff --git a/Frameworks/TagLib/Files/taglib/flac/flacproperties.h b/Frameworks/TagLib/taglib/taglib/flac/flacproperties.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/flac/flacproperties.h rename to Frameworks/TagLib/taglib/taglib/flac/flacproperties.h diff --git a/Frameworks/TagLib/Files/taglib/flac/flactag.h b/Frameworks/TagLib/taglib/taglib/flac/flactag.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/flac/flactag.h rename to Frameworks/TagLib/taglib/taglib/flac/flactag.h diff --git a/Frameworks/TagLib/taglib/taglib/m4a/boxfactory.cpp b/Frameworks/TagLib/taglib/taglib/m4a/boxfactory.cpp new file mode 100755 index 000000000..017c483f9 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/boxfactory.cpp @@ -0,0 +1,129 @@ +#include +#include "tstring.h" +#include "boxfactory.h" +#include "mp4skipbox.h" +#include "mp4moovbox.h" +#include "mp4mvhdbox.h" +#include "mp4trakbox.h" +#include "mp4mdiabox.h" +#include "mp4minfbox.h" +#include "mp4stblbox.h" +#include "mp4stsdbox.h" +#include "mp4hdlrbox.h" +#include "mp4udtabox.h" +#include "mp4metabox.h" +#include "mp4ilstbox.h" +#include "itunesnambox.h" +#include "itunesartbox.h" +#include "itunesalbbox.h" +#include "itunesgenbox.h" +#include "itunesdaybox.h" +#include "itunestrknbox.h" +#include "itunescmtbox.h" +#include "itunesgrpbox.h" +#include "ituneswrtbox.h" +#include "itunesdiskbox.h" +#include "itunestmpobox.h" +#include "itunescvrbox.h" +#include "itunesdatabox.h" + +using namespace TagLib; + +MP4::BoxFactory::BoxFactory() +{ +} + +MP4::BoxFactory::~BoxFactory() +{ +} + +//! factory function +MP4::Mp4IsoBox* MP4::BoxFactory::createInstance( TagLib::File* anyfile, MP4::Fourcc fourcc, uint size, long offset ) const +{ + MP4::File * file = static_cast(anyfile); + if(!file) + return 0; + + //std::cout << "creating box for: " << fourcc.toString() << std::endl; + + switch( fourcc ) + { + case 0x6d6f6f76: // 'moov' + return new MP4::Mp4MoovBox( file, fourcc, size, offset ); + break; + case 0x6d766864: // 'mvhd' + return new MP4::Mp4MvhdBox( file, fourcc, size, offset ); + break; + case 0x7472616b: // 'trak' + return new MP4::Mp4TrakBox( file, fourcc, size, offset ); + break; + case 0x6d646961: // 'mdia' + return new MP4::Mp4MdiaBox( file, fourcc, size, offset ); + break; + case 0x6d696e66: // 'minf' + return new MP4::Mp4MinfBox( file, fourcc, size, offset ); + break; + case 0x7374626c: // 'stbl' + return new MP4::Mp4StblBox( file, fourcc, size, offset ); + break; + case 0x73747364: // 'stsd' + return new MP4::Mp4StsdBox( file, fourcc, size, offset ); + break; + case 0x68646c72: // 'hdlr' + return new MP4::Mp4HdlrBox( file, fourcc, size, offset ); + break; + case 0x75647461: // 'udta' + return new MP4::Mp4UdtaBox( file, fourcc, size, offset ); + break; + case 0x6d657461: // 'meta' + return new MP4::Mp4MetaBox( file, fourcc, size, offset ); + break; + case 0x696c7374: // 'ilst' + return new MP4::Mp4IlstBox( file, fourcc, size, offset ); + break; + case 0xa96e616d: // '_nam' + return new MP4::ITunesNamBox( file, fourcc, size, offset ); + break; + case 0xa9415254: // '_ART' + return new MP4::ITunesArtBox( file, fourcc, size, offset ); + break; + case 0xa9616c62: // '_alb' + return new MP4::ITunesAlbBox( file, fourcc, size, offset ); + break; + case 0xa967656e: // '_gen' + return new MP4::ITunesGenBox( file, fourcc, size, offset ); + break; + case 0x676e7265: // 'gnre' + return new MP4::ITunesGenBox( file, fourcc, size, offset ); + break; + case 0xa9646179: // '_day' + return new MP4::ITunesDayBox( file, fourcc, size, offset ); + break; + case 0x74726b6e: // 'trkn' + return new MP4::ITunesTrknBox( file, fourcc, size, offset ); + break; + case 0xa9636d74: // '_cmt' + return new MP4::ITunesCmtBox( file, fourcc, size, offset ); + break; + case 0xa9677270: // '_grp' + return new MP4::ITunesGrpBox( file, fourcc, size, offset ); + break; + case 0xa9777274: // '_wrt' + return new MP4::ITunesWrtBox( file, fourcc, size, offset ); + break; + case 0x6469736b: // 'disk' + return new MP4::ITunesDiskBox( file, fourcc, size, offset ); + break; + case 0x746d706f: // 'tmpo' + return new MP4::ITunesTmpoBox( file, fourcc, size, offset ); + break; + case 0x636f7672: // 'covr' + return new MP4::ITunesCvrBox( file, fourcc, size, offset ); + break; + case 0x64616461: // 'data' + return new MP4::ITunesDataBox( file, fourcc, size, offset ); + break; + default: + return new MP4::Mp4SkipBox( file, fourcc, size, offset ); + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/boxfactory.h b/Frameworks/TagLib/taglib/taglib/m4a/boxfactory.h new file mode 100755 index 000000000..185800222 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/boxfactory.h @@ -0,0 +1,24 @@ +#ifndef BOXFACTORY_H +#define BOXFACTORY_H + +#include "taglib.h" +#include "mp4isobox.h" + +namespace TagLib +{ + namespace MP4 + { + class BoxFactory + { + public: + BoxFactory(); + ~BoxFactory(); + + //! factory function + Mp4IsoBox* createInstance( TagLib::File* anyfile, MP4::Fourcc fourcc, uint size, long offset ) const; + }; // class BoxFactory + + } // namepace MP4 +} // namepace TagLib + +#endif // BOXFACTORY_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesalbbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesalbbox.cpp new file mode 100755 index 000000000..6aa08bb73 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesalbbox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunesalbbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesAlbBox::ITunesAlbBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesAlbBox::ITunesAlbBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesAlbBox::ITunesAlbBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesAlbBox::~ITunesAlbBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesAlbBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesAlbBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::album, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of album box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesalbbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesalbbox.h new file mode 100755 index 000000000..e2c86bc97 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesalbbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESALBBOX_H +#define ITUNESALBBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesAlbBox: public Mp4IsoBox + { + public: + ITunesAlbBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesAlbBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesAlbBoxPrivate; + ITunesAlbBoxPrivate* d; + }; // class ITunesAlbBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESALBBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesartbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesartbox.cpp new file mode 100755 index 000000000..14f557a99 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesartbox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunesartbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesArtBox::ITunesArtBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesArtBox::ITunesArtBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesArtBox::ITunesArtBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesArtBox::~ITunesArtBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesArtBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesArtBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::artist, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of artist box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesartbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesartbox.h new file mode 100755 index 000000000..00563a4eb --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesartbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESARTBOX_H +#define ITUNESARTBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesArtBox: public Mp4IsoBox + { + public: + ITunesArtBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesArtBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesArtBoxPrivate; + ITunesArtBoxPrivate* d; + }; // class ITunesArtBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESARTBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunescmtbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunescmtbox.cpp new file mode 100755 index 000000000..c4db747b1 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunescmtbox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunescmtbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesCmtBox::ITunesCmtBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesCmtBox::ITunesCmtBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesCmtBox::ITunesCmtBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesCmtBox::~ITunesCmtBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesCmtBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesCmtBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::comment, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of title box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunescmtbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunescmtbox.h new file mode 100755 index 000000000..41d010772 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunescmtbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESCMTBOX_H +#define ITUNESCMTBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesCmtBox: public Mp4IsoBox + { + public: + ITunesCmtBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesCmtBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesCmtBoxPrivate; + ITunesCmtBoxPrivate* d; + }; // class ITunesCmtBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESCMTBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunescvrbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunescvrbox.cpp new file mode 100755 index 000000000..a8152bf8b --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunescvrbox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunescvrbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesCvrBox::ITunesCvrBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesCvrBox::ITunesCvrBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesCvrBox::ITunesCvrBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesCvrBox::~ITunesCvrBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesCvrBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesCvrBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::cover, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of album box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunescvrbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunescvrbox.h new file mode 100755 index 000000000..b18368c4f --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunescvrbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESCVRBOX_H +#define ITUNESCVRBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesCvrBox: public Mp4IsoBox + { + public: + ITunesCvrBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesCvrBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesCvrBoxPrivate; + ITunesCvrBoxPrivate* d; + }; // class ITunesCvrBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESCVRBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesdatabox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesdatabox.cpp new file mode 100755 index 000000000..483dfdb3e --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesdatabox.cpp @@ -0,0 +1,42 @@ +#include +#include "itunesdatabox.h" +#include "tbytevector.h" +#include "mp4isobox.h" +#include "tfile.h" + +using namespace TagLib; + +class MP4::ITunesDataBox::ITunesDataBoxPrivate +{ +public: + ByteVector data; +}; + +MP4::ITunesDataBox::ITunesDataBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoFullBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesDataBox::ITunesDataBoxPrivate(); +} + +MP4::ITunesDataBox::~ITunesDataBox() +{ + delete d; +} + +ByteVector MP4::ITunesDataBox::data() const +{ + return d->data; +} + +//! parse the content of the box +void MP4::ITunesDataBox::parse() +{ + // skip first 4 byte - don't know what they are supposed to be for - simply 4 zeros + file()->seek( 4, TagLib::File::Current ); + // read contents - remaining size is box_size-12-4 (12:fullbox header, 4:starting zeros of data box) +#if 0 + std::cout << " reading data box with data length: " << size()-16 << std::endl; +#endif + d->data = file()->readBlock( size()-12-4 ); +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesdatabox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesdatabox.h new file mode 100755 index 000000000..bb0d85266 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesdatabox.h @@ -0,0 +1,32 @@ +#ifndef ITUNESDATABOX_H +#define ITUNESDATABOX_H + +#include "mp4isofullbox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesDataBox: public Mp4IsoFullBox + { + public: + ITunesDataBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesDataBox(); + + //! get the internal data, which can be txt or binary data as well + ByteVector data() const; + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesDataBoxPrivate; + ITunesDataBoxPrivate* d; + }; // class ITunesDataBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESDATABOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesdaybox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesdaybox.cpp new file mode 100755 index 000000000..924c954f5 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesdaybox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunesdaybox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesDayBox::ITunesDayBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesDayBox::ITunesDayBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesDayBox::ITunesDayBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesDayBox::~ITunesDayBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesDayBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesDayBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::year, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of day box: " << dataString.substr(0,4) << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesdaybox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesdaybox.h new file mode 100755 index 000000000..5992960a2 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesdaybox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESDAYBOX_H +#define ITUNESDAYBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesDayBox: public Mp4IsoBox + { + public: + ITunesDayBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesDayBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesDayBoxPrivate; + ITunesDayBoxPrivate* d; + }; // class ITunesDayBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESDAYBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesdiskbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesdiskbox.cpp new file mode 100755 index 000000000..d387f2861 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesdiskbox.cpp @@ -0,0 +1,72 @@ +#include +#include "itunesdiskbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesDiskBox::ITunesDiskBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesDiskBox::ITunesDiskBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesDiskBox::ITunesDiskBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesDiskBox::~ITunesDiskBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesDiskBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesDiskBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::disk, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::ByteVector trknData = d->dataBox->data(); + TagLib::String trknumber = TagLib::String::number( static_cast( static_cast(trknData[0]) << 24 | + static_cast(trknData[1]) << 16 | + static_cast(trknData[2]) << 8 | + static_cast(trknData[3]) ) ); + std::cout << "Content of tracknumber box: " << trknumber << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesdiskbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesdiskbox.h new file mode 100755 index 000000000..7d82c89e6 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesdiskbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESDISKBOX_H +#define ITUNESDISKBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesDiskBox: public Mp4IsoBox + { + public: + ITunesDiskBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesDiskBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesDiskBoxPrivate; + ITunesDiskBoxPrivate* d; + }; // class ITunesDiskBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESDISKBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesgenbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesgenbox.cpp new file mode 100755 index 000000000..b903d0176 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesgenbox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunesgenbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesGenBox::ITunesGenBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesGenBox::ITunesGenBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesGenBox::ITunesGenBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesGenBox::~ITunesGenBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesGenBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesGenBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::genre, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of genre box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesgenbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesgenbox.h new file mode 100755 index 000000000..c4f9fed92 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesgenbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESGENBOX_H +#define ITUNESGENBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesGenBox: public Mp4IsoBox + { + public: + ITunesGenBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesGenBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesGenBoxPrivate; + ITunesGenBoxPrivate* d; + }; // class ITunesGenBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESGENBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesgrpbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesgrpbox.cpp new file mode 100755 index 000000000..203a30f83 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesgrpbox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunesgrpbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesGrpBox::ITunesGrpBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesGrpBox::ITunesGrpBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesGrpBox::ITunesGrpBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesGrpBox::~ITunesGrpBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesGrpBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesGrpBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::grouping, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of title box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesgrpbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesgrpbox.h new file mode 100755 index 000000000..52504aa47 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesgrpbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESGRPBOX_H +#define ITUNESGRPBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesGrpBox: public Mp4IsoBox + { + public: + ITunesGrpBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesGrpBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesGrpBoxPrivate; + ITunesGrpBoxPrivate* d; + }; // class ITunesGrpBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESGRPBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesnambox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunesnambox.cpp new file mode 100755 index 000000000..98c488eab --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesnambox.cpp @@ -0,0 +1,68 @@ +#include +#include "itunesnambox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesNamBox::ITunesNamBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesNamBox::ITunesNamBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesNamBox::ITunesNamBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesNamBox::~ITunesNamBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesNamBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesNamBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::title, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of title box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunesnambox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunesnambox.h new file mode 100755 index 000000000..ec97100ef --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunesnambox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESNAMBOX_H +#define ITUNESNAMBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesNamBox: public Mp4IsoBox + { + public: + ITunesNamBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesNamBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesNamBoxPrivate; + ITunesNamBoxPrivate* d; + }; // class ITunesNamBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESNAMBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunestmpobox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunestmpobox.cpp new file mode 100755 index 000000000..db9aa17d3 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunestmpobox.cpp @@ -0,0 +1,72 @@ +#include +#include "itunestmpobox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesTmpoBox::ITunesTmpoBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesTmpoBox::ITunesTmpoBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesTmpoBox::ITunesTmpoBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesTmpoBox::~ITunesTmpoBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesTmpoBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesTmpoBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::bpm, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::ByteVector trknData = d->dataBox->data(); + TagLib::String trknumber = TagLib::String::number( static_cast( static_cast(trknData[0]) << 24 | + static_cast(trknData[1]) << 16 | + static_cast(trknData[2]) << 8 | + static_cast(trknData[3]) ) ); + std::cout << "Content of tracknumber box: " << trknumber << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunestmpobox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunestmpobox.h new file mode 100755 index 000000000..5c69137f5 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunestmpobox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESTMPOBOX_H +#define ITUNESTMPOBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesTmpoBox: public Mp4IsoBox + { + public: + ITunesTmpoBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesTmpoBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesTmpoBoxPrivate; + ITunesTmpoBoxPrivate* d; + }; // class ITunesTmpoBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESTMPOBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunestrknbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/itunestrknbox.cpp new file mode 100755 index 000000000..f9058f2bb --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunestrknbox.cpp @@ -0,0 +1,72 @@ +#include +#include "itunestrknbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesTrknBox::ITunesTrknBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesTrknBox::ITunesTrknBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesTrknBox::ITunesTrknBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesTrknBox::~ITunesTrknBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesTrknBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesTrknBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::trackno, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::ByteVector trknData = d->dataBox->data(); + TagLib::String trknumber = TagLib::String::number( static_cast( static_cast(trknData[0]) << 24 | + static_cast(trknData[1]) << 16 | + static_cast(trknData[2]) << 8 | + static_cast(trknData[3]) ) ); + std::cout << "Content of tracknumber box: " << trknumber << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/itunestrknbox.h b/Frameworks/TagLib/taglib/taglib/m4a/itunestrknbox.h new file mode 100755 index 000000000..4d568814c --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/itunestrknbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESTRKNBOX_H +#define ITUNESTRKNBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesTrknBox: public Mp4IsoBox + { + public: + ITunesTrknBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesTrknBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesTrknBoxPrivate; + ITunesTrknBoxPrivate* d; + }; // class ITunesTrknBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESTRKNBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/ituneswrtbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/ituneswrtbox.cpp new file mode 100755 index 000000000..07caf9dd4 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/ituneswrtbox.cpp @@ -0,0 +1,68 @@ +#include +#include "ituneswrtbox.h" +#include "itunesdatabox.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "tfile.h" +#include "mp4tagsproxy.h" + +using namespace TagLib; + +class MP4::ITunesWrtBox::ITunesWrtBoxPrivate +{ +public: + ITunesDataBox* dataBox; +}; + +MP4::ITunesWrtBox::ITunesWrtBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::ITunesWrtBox::ITunesWrtBoxPrivate(); + d->dataBox = 0; +} + +MP4::ITunesWrtBox::~ITunesWrtBox() +{ + if( d->dataBox != 0 ) + delete d->dataBox; + delete d; +} + +//! parse the content of the box +void MP4::ITunesWrtBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + // parse data box + TagLib::uint size; + MP4::Fourcc fourcc; + + if(mp4file->readSizeAndType( size, fourcc ) == true) + { + // check for type - must be 'data' + if( fourcc != MP4::Fourcc("data") ) + { + std::cerr << "bad atom in itunes tag - skipping it." << std::endl; + // jump over data tag + mp4file->seek( size-8, TagLib::File::Current ); + return; + } + d->dataBox = new ITunesDataBox( mp4file, fourcc, size, mp4file->tell() ); + d->dataBox->parsebox(); + } + else + { + // reading unsuccessful - serious error! + std::cerr << "Error in parsing ITunesWrtBox - serious Error in taglib!" << std::endl; + return; + } + // register data box + mp4file->tagProxy()->registerBox( Mp4TagsProxy::composer, d->dataBox ); + +#if 0 + // get data pointer - just for debuging... + TagLib::String dataString( d->dataBox->data() ); + std::cout << "Content of title box: " << dataString << std::endl; +#endif +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/ituneswrtbox.h b/Frameworks/TagLib/taglib/taglib/m4a/ituneswrtbox.h new file mode 100755 index 000000000..5f76638e6 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/ituneswrtbox.h @@ -0,0 +1,29 @@ +#ifndef ITUNESWRTBOX_H +#define ITUNESWRTBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class ITunesWrtBox: public Mp4IsoBox + { + public: + ITunesWrtBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~ITunesWrtBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class ITunesWrtBoxPrivate; + ITunesWrtBoxPrivate* d; + }; // class ITunesWrtBox + + } // namespace MP4 +} // namespace TagLib + +#endif // ITUNESWRTBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4audioproperties.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4audioproperties.cpp new file mode 100755 index 000000000..6a3c73216 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4audioproperties.cpp @@ -0,0 +1,54 @@ +#include "mp4audioproperties.h" +#include "mp4propsproxy.h" + +using namespace TagLib; + +class MP4::AudioProperties::AudioPropertiesPrivate +{ +public: + MP4::Mp4PropsProxy* propsproxy; +}; // AudioPropertiesPrivate + +MP4::AudioProperties::AudioProperties():TagLib::AudioProperties(TagLib::AudioProperties::Average) +{ + d = new MP4::AudioProperties::AudioPropertiesPrivate(); +} + +MP4::AudioProperties::~AudioProperties() +{ + delete d; +} + +void MP4::AudioProperties::setProxy( Mp4PropsProxy* proxy ) +{ + d->propsproxy = proxy; +} + +int MP4::AudioProperties::length() const +{ + if( d->propsproxy == 0 ) + return 0; + return d->propsproxy->seconds(); +} + +int MP4::AudioProperties::bitrate() const +{ + if( d->propsproxy == 0 ) + return 0; + return d->propsproxy->bitRate()/1000; +} + +int MP4::AudioProperties::sampleRate() const +{ + if( d->propsproxy == 0 ) + return 0; + return d->propsproxy->sampleRate(); +} + +int MP4::AudioProperties::channels() const +{ + if( d->propsproxy == 0 ) + return 0; + return d->propsproxy->channels(); +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4audioproperties.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4audioproperties.h new file mode 100755 index 000000000..fa3f01f41 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4audioproperties.h @@ -0,0 +1,52 @@ +#ifndef MP4AUDIOPROPERTIES_H +#define MP4AUDIOPROPERTIES_H MP4AUDIOPROPERTIES_H + +#include "audioproperties.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4PropsProxy; + + class AudioProperties : public TagLib::AudioProperties + { + public: + //! constructor + AudioProperties(); + //! destructor + ~AudioProperties(); + + //! function to set the proxy + void setProxy( Mp4PropsProxy* proxy ); + + /*! + * Returns the lenght of the file in seconds. + */ + int length() const; + + /*! + * Returns the most appropriate bit rate for the file in kb/s. For constant + * bitrate formats this is simply the bitrate of the file. For variable + * bitrate formats this is either the average or nominal bitrate. + */ + int bitrate() const; + + /*! + * Returns the sample rate in Hz. + */ + int sampleRate() const; + + /*! + * Returns the number of audio channels. + */ + int channels() const; + + private: + class AudioPropertiesPrivate; + AudioPropertiesPrivate* d; + }; + } // namespace MP4 +} // namespace TagLib + +#endif // MP4AUDIOPROPERTIES_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4audiosampleentry.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4audiosampleentry.cpp new file mode 100755 index 000000000..62c985063 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4audiosampleentry.cpp @@ -0,0 +1,124 @@ +#include +#include "mp4audiosampleentry.h" +#include "mp4isobox.h" +#include "mp4file.h" +#include "mp4propsproxy.h" + +using namespace TagLib; + +class MP4::Mp4AudioSampleEntry::Mp4AudioSampleEntryPrivate +{ +public: + TagLib::uint channelcount; + TagLib::uint samplerate; + TagLib::uint bitrate; +}; + +MP4::Mp4AudioSampleEntry::Mp4AudioSampleEntry( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4SampleEntry(file, fourcc, size, offset) +{ + d = new MP4::Mp4AudioSampleEntry::Mp4AudioSampleEntryPrivate(); +} + +MP4::Mp4AudioSampleEntry::~Mp4AudioSampleEntry() +{ + delete d; +} + +TagLib::uint MP4::Mp4AudioSampleEntry::channels() const +{ + return d->channelcount; +} + +TagLib::uint MP4::Mp4AudioSampleEntry::samplerate() const +{ + return d->samplerate; +} + +TagLib::uint MP4::Mp4AudioSampleEntry::bitrate() const +{ + return d->bitrate; +} + +void MP4::Mp4AudioSampleEntry::parseEntry() +{ + TagLib::MP4::File* mp4file = static_cast(file()); + if(!mp4file) + return; + + // read 8 reserved bytes + mp4file->seek( 8, TagLib::File::Current ); + // read channelcount + if(!mp4file->readShort( d->channelcount )) + return; + // seek over samplesize, pre_defined and reserved + mp4file->seek( 6, TagLib::File::Current ); + // read samplerate + if(!mp4file->readInt( d->samplerate )) + return; + + // register box at proxy + mp4file->propProxy()->registerAudioSampleEntry( this ); + + + //std::cout << "fourcc of audio sample entry: " << fourcc().toString() << std::endl; + // check for both mp4a (plain files) and drms (encrypted files) + if( (fourcc() == MP4::Fourcc("mp4a")) || + (fourcc() == MP4::Fourcc("drms")) ) + { + TagLib::MP4::Fourcc fourcc; + TagLib::uint esds_size; + + mp4file->readSizeAndType( esds_size, fourcc ); + + // read esds' main parts + if( size()-48 > 0 ) + ByteVector flags_version = mp4file->readBlock(4); + else + return; + + ByteVector EsDescrTag = mp4file->readBlock(1); + // first 4 bytes contain full box specifics (version & flags) + // upcoming byte must be ESDescrTag (0x03) + if( EsDescrTag[0] == 0x03 ) + { + TagLib::uint descr_len = mp4file->readSystemsLen(); + TagLib::uint EsId; + if( !mp4file->readShort( EsId ) ) + return; + ByteVector priority = mp4file->readBlock(1); + if( descr_len < 20 ) + return; + } + else + { + TagLib::uint EsId; + if( !mp4file->readShort( EsId ) ) + return; + } + // read decoder configuration tag (0x04) + ByteVector DecCfgTag = mp4file->readBlock(1); + if( DecCfgTag[0] != 0x04 ) + return; + // read decoder configuration length + TagLib::uint deccfg_len = mp4file->readSystemsLen(); + // read object type Id + ByteVector objId = mp4file->readBlock(1); + // read stream type id + ByteVector strId = mp4file->readBlock(1); + // read buffer Size DB + ByteVector bufferSizeDB = mp4file->readBlock(3); + // read max bitrate + TagLib::uint max_bitrate; + if( !mp4file->readInt( max_bitrate ) ) + return; + // read average bitrate + if( !mp4file->readInt( d->bitrate ) ) + return; + // skip the rest + mp4file->seek( offset()+size()-8, File::Beginning ); + } + else + mp4file->seek( size()-36, File::Current ); +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4audiosampleentry.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4audiosampleentry.h new file mode 100755 index 000000000..71cfb3df7 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4audiosampleentry.h @@ -0,0 +1,36 @@ +#ifndef MP4AUDIOSAMPLEENTRY_H +#define MP4AUDIOSAMPLEENTRY_H + +#include "mp4sampleentry.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4AudioSampleEntry: public Mp4SampleEntry + { + public: + Mp4AudioSampleEntry( File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~Mp4AudioSampleEntry(); + + //! function to get the number of channels + TagLib::uint channels() const; + //! function to get the sample rate + TagLib::uint samplerate() const; + //! function to get the average bitrate of the audio stream + TagLib::uint bitrate() const; + + private: + //! parse the content of the box + void parseEntry(); + + protected: + class Mp4AudioSampleEntryPrivate; + Mp4AudioSampleEntryPrivate* d; + }; // class Mp4AudioSampleEntry + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4AUDIOSAMPLEENTRY_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4file.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4file.cpp new file mode 100755 index 000000000..2085a3f25 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4file.cpp @@ -0,0 +1,390 @@ +#include +#include +#include +#include "tlist.h" + +#include "id3v1genres.h" + +#include "mp4itunestag.h" +#include "mp4file.h" +#include "boxfactory.h" +#include "mp4tagsproxy.h" +#include "mp4propsproxy.h" +#include "mp4audioproperties.h" +#include "itunesdatabox.h" + +using namespace TagLib; + +class MP4::File::FilePrivate +{ +public: + //! list for all boxes of the mp4 file + TagLib::List boxes; + //! the box factory - will create all boxes by tag and size + MP4::BoxFactory boxfactory; + //! proxy for the tags is filled after parsing + MP4::Mp4TagsProxy tagsProxy; + //! proxy for audio properties + MP4::Mp4PropsProxy propsProxy; + //! the tag returned by tag() function + MP4::Tag mp4tag; + //! container for the audio properties returned by properties() function + MP4::AudioProperties mp4audioproperties; + //! is set to valid after successfull parsing + bool isValid; +}; + +//! function to fill the tags with converted proxy data, which has been parsed out of the file previously +static void fillTagFromProxy( MP4::Mp4TagsProxy& proxy, MP4::Tag& mp4tag ); + +MP4::File::File() : TagLib::File() +{ + // create member container + d = new MP4::File::FilePrivate(); + d->isValid = false; +} + +MP4::File::File(const char *file, bool , AudioProperties::ReadStyle ) + :TagLib::File( file ) +{ + // create member container + d = new MP4::File::FilePrivate(); + + read(); +} + +MP4::File::~File() +{ + TagLib::List::Iterator delIter; + for( delIter = d->boxes.begin(); + delIter != d->boxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +Tag *MP4::File::tag() const +{ + return &d->mp4tag; +} + +AudioProperties * MP4::File::audioProperties() const +{ + d->mp4audioproperties.setProxy( &d->propsProxy ); + return &d->mp4audioproperties; +} + +void MP4::File::read( bool, TagLib::AudioProperties::ReadStyle ) +{ + d->isValid = false; + TagLib::uint size; + MP4::Fourcc fourcc; + + while( readSizeAndType( size, fourcc ) == true ) + { + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( this, fourcc, size, tell() ); + curbox->parsebox(); + d->boxes.append( curbox ); + } + + for( TagLib::List::Iterator iter = d->boxes.begin(); + iter != d->boxes.end(); + iter++ ) + { + if( (*iter)->fourcc() == MP4::Fourcc("moov") ) + { + d->isValid = true; + break; + } + } + + if( d->isValid ) + debug( "file is valid" ); + else + debug( "file is NOT valid" ); + + // fill tags from proxy data + fillTagFromProxy( d->tagsProxy, d->mp4tag ); +} + +bool MP4::File::save() +{ + return false; +} + +void MP4::File::remove() +{ +} + +TagLib::uint MP4::File::readSystemsLen() +{ + TagLib::uint length = 0; + TagLib::uint nbytes = 0; + ByteVector input; + TagLib::uchar tmp_input; + + do + { + input = readBlock(1); + tmp_input = static_cast(input[0]); + nbytes++; + length = (length<<7) | (tmp_input&0x7F); + } while( (tmp_input&0x80) && (nbytes<4) ); + + return length; +} + +bool MP4::File::readSizeAndType( TagLib::uint& size, MP4::Fourcc& fourcc ) +{ + // read the two blocks from file + ByteVector readsize = readBlock(4); + ByteVector readtype = readBlock(4); + + if( (readsize.size() != 4) || (readtype.size() != 4) ) + return false; + + // set size + size = static_cast(readsize[0]) << 24 | + static_cast(readsize[1]) << 16 | + static_cast(readsize[2]) << 8 | + static_cast(readsize[3]); + if (size == 0) + return false; + + // set fourcc + fourcc = readtype.data(); + + return true; +} + +bool MP4::File::readInt( TagLib::uint& toRead ) +{ + ByteVector readbuffer = readBlock(4); + if( readbuffer.size() != 4 ) + return false; + + toRead = static_cast(readbuffer[0]) << 24 | + static_cast(readbuffer[1]) << 16 | + static_cast(readbuffer[2]) << 8 | + static_cast(readbuffer[3]); + return true; +} + +bool MP4::File::readShort( TagLib::uint& toRead ) +{ + ByteVector readbuffer = readBlock(2); + if( readbuffer.size() != 2 ) + return false; + + toRead = static_cast(readbuffer[0]) << 8 | + static_cast(readbuffer[1]); + return true; +} + +bool MP4::File::readLongLong( TagLib::ulonglong& toRead ) +{ + ByteVector readbuffer = readBlock(8); + if( readbuffer.size() != 8 ) + return false; + + toRead = static_cast(static_cast(readbuffer[0])) << 56 | + static_cast(static_cast(readbuffer[1])) << 48 | + static_cast(static_cast(readbuffer[2])) << 40 | + static_cast(static_cast(readbuffer[3])) << 32 | + static_cast(static_cast(readbuffer[4])) << 24 | + static_cast(static_cast(readbuffer[5])) << 16 | + static_cast(static_cast(readbuffer[6])) << 8 | + static_cast(static_cast(readbuffer[7])); + return true; +} + +bool MP4::File::readFourcc( TagLib::MP4::Fourcc& fourcc ) +{ + ByteVector readtype = readBlock(4); + + if( readtype.size() != 4) + return false; + + // set fourcc + fourcc = readtype.data(); + + return true; +} + +MP4::Mp4TagsProxy* MP4::File::tagProxy() const +{ + return &d->tagsProxy; +} + +MP4::Mp4PropsProxy* MP4::File::propProxy() const +{ + return &d->propsProxy; +} + +/* This function has been updated based on information at */ +/* "http://atomicparsley.sourceforge.net/mpeg-4files.html". */ +void fillTagFromProxy( MP4::Mp4TagsProxy& proxy, MP4::Tag& mp4tag ) +{ + // tmp buffer for each tag + MP4::ITunesDataBox* databox; + + databox = proxy.titleData(); + if( databox != 0 ) + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setTitle( datastring ); + } + + databox = proxy.artistData(); + if( databox != 0 ) + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setArtist( datastring ); + } + + databox = proxy.albumData(); + if( databox != 0 ) + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setAlbum( datastring ); + } + + databox = proxy.genreData(); + if( databox != 0 ) + { + if (databox->flags() == 0) + { + // convert data to uint + TagLib::ByteVector datavec = databox->data(); + int genreVal = static_cast( datavec[1] ); + if (genreVal > 0) + { + TagLib::String datastring = ID3v1::genre( genreVal - 1 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setGenre( datastring ); + } + } + else + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setGenre( datastring ); + } + } + + databox = proxy.yearData(); + if( databox != 0 ) + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setYear( datastring.toInt() ); + } + + databox = proxy.trknData(); + if( databox != 0 ) + { + // convert data to uint + TagLib::ByteVector datavec = databox->data(); + if( datavec.size() >= 6 ) + { + TagLib::uint notracks = static_cast( datavec[5] ); + mp4tag.setNumTracks( notracks ); + } + if( datavec.size() >= 4 ) + { + TagLib::uint trackno = static_cast( datavec[3] ); + mp4tag.setTrack( trackno ); + } + else + mp4tag.setTrack( 0 ); + } + + databox = proxy.commentData(); + if( databox != 0 ) + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setComment( datastring ); + } + + databox = proxy.groupingData(); + if( databox != 0 ) + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setGrouping( datastring ); + } + + databox = proxy.composerData(); + if( databox != 0 ) + { + // convert data to string + TagLib::String datastring( databox->data(), String::UTF8 ); + // check if string was set + if( !(datastring == "") ) + mp4tag.setComposer( datastring ); + } + + databox = proxy.diskData(); + if( databox != 0 ) + { + // convert data to uint + TagLib::ByteVector datavec = databox->data(); + if( datavec.size() >= 6 ) + { + TagLib::uint nodiscs = static_cast( datavec[5] ); + mp4tag.setNumDisks( nodiscs ); + } + if( datavec.size() >= 4 ) + { + TagLib::uint discno = static_cast( datavec[3] ); + mp4tag.setDisk( discno ); + } + else + mp4tag.setDisk( 0 ); + } + + databox = proxy.bpmData(); + if( databox != 0 ) + { + // convert data to uint + TagLib::ByteVector datavec = databox->data(); + + if( datavec.size() >= 2 ) + { + TagLib::uint bpm = static_cast( static_cast(datavec[0]) << 8 | + static_cast(datavec[1]) ); + mp4tag.setBpm( bpm ); + } + else + mp4tag.setBpm( 0 ); + } + + databox = proxy.coverData(); + if( databox != 0 ) + { + // get byte vector + mp4tag.setCover( databox->data() ); + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4file.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4file.h new file mode 100755 index 000000000..ff5964785 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4file.h @@ -0,0 +1,162 @@ +/*************************************************************************** + copyright : (C) 2002, 2003 by Jochen Issing + email : jochen.issing@isign-softart.de + ***************************************************************************/ + +/*************************************************************************** + * This library is free software; you can redistribute it and/or modify * + * it under the terms of the GNU Lesser General Public License version * + * 2.1 as published by the Free Software Foundation. * + * * + * This library is distributed in the hope that it will be useful, but * + * WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * Lesser General Public License for more details. * + * * + * You should have received a copy of the GNU Lesser General Public * + * License along with this library; if not, write to the Free Software * + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * + * USA * + ***************************************************************************/ + +#ifndef TAGLIB_MP4FILE_H +#define TAGLIB_MP4FILE_H + +#include +#include + +#include "mp4fourcc.h" + +namespace TagLib { + + typedef unsigned long long ulonglong; + + class Tag; + + namespace MP4 + { + class Mp4TagsProxy; + class Mp4PropsProxy; + + //! An implementation of TagLib::File with mp4 itunes specific methods + + /*! + * This implements and provides an interface for mp4 itunes files to the + * TagLib::Tag and TagLib::AudioProperties interfaces by way of implementing + * the abstract TagLib::File API as well as providing some additional + * information specific to mp4 itunes files. (TODO) + */ + + class File : public TagLib::File + { + public: + /*! + * Contructs an mp4 itunes file object without reading a file. Allows object + * fields to be set up before reading. + */ + File(); + + /*! + * Contructs an mp4 itunes file from \a file. If \a readProperties is true the + * file's audio properties will also be read using \a propertiesStyle. If + * false, \a propertiesStyle is ignored. + */ + File(const char *file, bool readProperties = true, + TagLib::AudioProperties::ReadStyle propertiesStyle = TagLib::AudioProperties::Average); + + /*! + * Destroys this instance of the File. + */ + virtual ~File(); + + /*! + * Returns the Tag for this file. This will be an APE tag, an ID3v1 tag + * or a combination of the two. + */ + virtual TagLib::Tag *tag() const; + + /*! + * Returns the mp4 itunes::Properties for this file. If no audio properties + * were read then this will return a null pointer. + */ + virtual AudioProperties *audioProperties() const; + + /*! + * Reads from mp4 itunes file. If \a readProperties is true the file's + * audio properties will also be read using \a propertiesStyle. If false, + * \a propertiesStyle is ignored. + */ + void read(bool readProperties = true, + TagLib::AudioProperties::ReadStyle propertiesStyle = TagLib::AudioProperties::Average); + + /*! + * Saves the file. + */ + virtual bool save(); + + /*! + * This will remove all tags. + * + * \note This will also invalidate pointers to the tags + * as their memory will be freed. + * \note In order to make the removal permanent save() still needs to be called + */ + void remove(); + + /*! + * Helper function for parsing the MP4 file - reads the size and type of the next box. + * Returns true if read succeeded - not at EOF + */ + bool readSizeAndType( TagLib::uint& size, MP4::Fourcc& fourcc ); + + /*! + * Helper function to read the length of an descriptor in systems manner + */ + TagLib::uint readSystemsLen(); + + /*! + * Helper function for reading an unsigned int out of the file (big endian method) + */ + bool readInt( TagLib::uint& toRead ); + + /*! + * Helper function for reading an unsigned short out of the file (big endian method) + */ + bool readShort( TagLib::uint& toRead ); + + /*! + * Helper function for reading an unsigned long long (64bit) out of the file (big endian method) + */ + bool readLongLong( TagLib::ulonglong& toRead ); + + /*! + * Helper function to read a fourcc code + */ + bool readFourcc( TagLib::MP4::Fourcc& fourcc ); + + /*! + * Function to get the tags proxy for registration of the tags boxes. + * The proxy provides direct access to the data boxes of the certain tags - normally + * covered by several levels of subboxes + */ + Mp4TagsProxy* tagProxy() const; + + /*! + * Function to get the properties proxy for registration of the properties boxes. + * The proxy provides direct access to the needed boxes describing audio properties. + */ + Mp4PropsProxy* propProxy() const; + + private: + File(const File &); + File &operator=(const File &); + + class FilePrivate; + FilePrivate *d; + }; + + } // namespace MP4 + +} // namespace TagLib + +#endif // TAGLIB_MP4FILE_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4fourcc.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4fourcc.cpp new file mode 100755 index 000000000..f1c0fc8bd --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4fourcc.cpp @@ -0,0 +1,63 @@ +#include "mp4fourcc.h" + +using namespace TagLib; + +MP4::Fourcc::Fourcc() +{ + m_fourcc = 0U; +} + +MP4::Fourcc::Fourcc( TagLib::String fourcc ) +{ + m_fourcc = 0U; + + if( fourcc.size() >= 4 ) + m_fourcc = static_cast(fourcc[0]) << 24 | + static_cast(fourcc[1]) << 16 | + static_cast(fourcc[2]) << 8 | + static_cast(fourcc[3]); +} + +MP4::Fourcc::~Fourcc() +{} + +TagLib::String MP4::Fourcc::toString() const +{ + TagLib::String fourcc; + fourcc.append(static_cast(m_fourcc >> 24 & 0xFF)); + fourcc.append(static_cast(m_fourcc >> 16 & 0xFF)); + fourcc.append(static_cast(m_fourcc >> 8 & 0xFF)); + fourcc.append(static_cast(m_fourcc & 0xFF)); + + return fourcc; +} + +MP4::Fourcc::operator unsigned int() const +{ + return m_fourcc; +} + +bool MP4::Fourcc::operator == (unsigned int fourccB ) const +{ + return (m_fourcc==fourccB); +} + +bool MP4::Fourcc::operator != (unsigned int fourccB ) const +{ + return (m_fourcc!=fourccB); +} + +MP4::Fourcc& MP4::Fourcc::operator = (unsigned int fourcc ) +{ + m_fourcc = fourcc; + return *this; +} + +MP4::Fourcc& MP4::Fourcc::operator = (char fourcc[4]) +{ + m_fourcc = static_cast(fourcc[0]) << 24 | + static_cast(fourcc[1]) << 16 | + static_cast(fourcc[2]) << 8 | + static_cast(fourcc[3]); + return *this; +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4fourcc.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4fourcc.h new file mode 100755 index 000000000..961f8763f --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4fourcc.h @@ -0,0 +1,42 @@ +#ifndef MP4FOURCC_H +#define MP4FOURCC_H + +#include "tstring.h" + +namespace TagLib +{ + namespace MP4 + { + /*! union for easy fourcc / type handling */ + class Fourcc + { + public: + //! std constructor + Fourcc(); + //! string constructor + Fourcc(TagLib::String fourcc); + + //! destructor + ~Fourcc(); + + //! function to get a string version of the fourcc + TagLib::String toString() const; + //! cast operator to unsigned int + operator unsigned int() const; + //! comparison operator + bool operator == (unsigned int fourccB ) const; + //! comparison operator + bool operator != (unsigned int fourccB ) const; + //! assigment operator for unsigned int + Fourcc& operator = (unsigned int fourcc ); + //! assigment operator for character string + Fourcc& operator = (char fourcc[4]); + + private: + uint m_fourcc; /*!< integer code of the fourcc */ + }; + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4FOURCC_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4hdlrbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4hdlrbox.cpp new file mode 100755 index 000000000..6a8a38e8f --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4hdlrbox.cpp @@ -0,0 +1,54 @@ +#include +#include +#include "mp4hdlrbox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4HdlrBox::Mp4HdlrBoxPrivate +{ +public: + TagLib::uint pre_defined; + MP4::Fourcc handler_type; + TagLib::String hdlr_string; +}; // class Mp4HdlrBoxPrivate + +MP4::Mp4HdlrBox::Mp4HdlrBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoFullBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4HdlrBox::Mp4HdlrBoxPrivate(); +} + +MP4::Mp4HdlrBox::~Mp4HdlrBox() +{ + delete d; +} + +MP4::Fourcc MP4::Mp4HdlrBox::hdlr_type() const +{ + return d->handler_type; +} + +TagLib::String MP4::Mp4HdlrBox::hdlr_string() const +{ + return d->hdlr_string; +} + +void MP4::Mp4HdlrBox::parse() +{ + TagLib::uint totalread = 12+20; + + TagLib::MP4::File* mp4file = static_cast( file() ); + if( mp4file->readInt( d->pre_defined ) == false ) + return; + if( mp4file->readFourcc( d->handler_type ) == false ) + return; + + // read reserved into trash + mp4file->seek( 3*4, TagLib::File::Current ); + + // check if there are bytes remaining - used for hdlr string + if( size() - totalread != 0 ) + d->hdlr_string = mp4file->readBlock( size()-totalread ); +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4hdlrbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4hdlrbox.h new file mode 100755 index 000000000..5c26bd062 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4hdlrbox.h @@ -0,0 +1,32 @@ +#ifndef MP4HDLRBOX_H +#define MP4HDLRBOX_H + +#include "mp4isofullbox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4HdlrBox: public Mp4IsoFullBox + { + public: + Mp4HdlrBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4HdlrBox(); + + //! parse hdlr contents + void parse(); + //! get the handler type + MP4::Fourcc hdlr_type() const; + //! get the hdlr string + TagLib::String hdlr_string() const; + + private: + class Mp4HdlrBoxPrivate; + Mp4HdlrBoxPrivate* d; + }; // Mp4HdlrBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4HDLRBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4ilstbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4ilstbox.cpp new file mode 100755 index 000000000..b1f214fee --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4ilstbox.cpp @@ -0,0 +1,76 @@ +#include "tlist.h" +#include +#include "mp4ilstbox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4IlstBox::Mp4IlstBoxPrivate +{ +public: + //! container for all boxes in ilst box + TagLib::List ilstBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; +}; // class Mp4IlstBoxPrivate + +MP4::Mp4IlstBox::Mp4IlstBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4IlstBox::Mp4IlstBoxPrivate(); +} + +MP4::Mp4IlstBox::~Mp4IlstBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->ilstBoxes.begin(); + delIter != d->ilstBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4IlstBox::parse() +{ +#if 0 + std::cout << " parsing ilst box" << std::endl; +#endif + + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 8; + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + +#if 0 + std::cout << " "; +#endif + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " ilst box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + curbox->parsebox(); + d->ilstBoxes.append( curbox ); + + // check for end of ilst box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; + +#if 0 + std::cout << " "; +#endif + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4ilstbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4ilstbox.h new file mode 100755 index 000000000..597a6bda3 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4ilstbox.h @@ -0,0 +1,28 @@ +#ifndef MP4ILSTBOX_H +#define MP4ILSTBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4IlstBox: public Mp4IsoBox + { + public: + Mp4IlstBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4IlstBox(); + + //! parse ilst contents + void parse(); + + private: + class Mp4IlstBoxPrivate; + Mp4IlstBoxPrivate* d; + }; // Mp4IlstBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4ILSTBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4isobox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4isobox.cpp new file mode 100755 index 000000000..69bd69a18 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4isobox.cpp @@ -0,0 +1,55 @@ +#include "mp4isobox.h" +#include "tfile.h" + +using namespace TagLib; + +class MP4::Mp4IsoBox::Mp4IsoBoxPrivate +{ +public: + MP4::Fourcc fourcc; + TagLib::uint size; + long offset; + TagLib::File* file; +}; + +MP4::Mp4IsoBox::Mp4IsoBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) +{ + d = new MP4::Mp4IsoBox::Mp4IsoBoxPrivate(); + d->file = file; + d->fourcc = fourcc; + d->size = size; + d->offset = offset; +} + +MP4::Mp4IsoBox::~Mp4IsoBox() +{ + delete d; +} + +void MP4::Mp4IsoBox::parsebox() +{ + // seek to offset + file()->seek( offset(), File::Beginning ); + // simply call parse method of sub class + parse(); +} + +MP4::Fourcc MP4::Mp4IsoBox::fourcc() const +{ + return d->fourcc; +} + +TagLib::uint MP4::Mp4IsoBox::size() const +{ + return d->size; +} + +long MP4::Mp4IsoBox::offset() const +{ + return d->offset; +} + +TagLib::File* MP4::Mp4IsoBox::file() const +{ + return d->file; +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4isobox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4isobox.h new file mode 100755 index 000000000..8ea042378 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4isobox.h @@ -0,0 +1,46 @@ +#ifndef MP4ISOBOX_H +#define MP4ISOBOX_H + +#include "taglib.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + class File; + + namespace MP4 + { + class Mp4IsoBox + { + public: + //! constructor for base class + Mp4IsoBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + //! destructor - simply freeing private ptr + virtual ~Mp4IsoBox(); + + //! function to get the fourcc code + MP4::Fourcc fourcc() const; + //! function to get the size of tha atom/box + uint size() const; + //! function to get the offset of the atom in the mp4 file + long offset() const; + + //! parse wrapper to get common interface for both box and fullbox + virtual void parsebox(); + //! pure virtual function for all subclasses to implement + virtual void parse() = 0; + + protected: + //! function to get the file pointer + TagLib::File* file() const; + + protected: + class Mp4IsoBoxPrivate; + Mp4IsoBoxPrivate* d; + }; + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4ISOBOX_H + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4isofullbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4isofullbox.cpp new file mode 100755 index 000000000..acab3a8e9 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4isofullbox.cpp @@ -0,0 +1,46 @@ +#include "mp4isofullbox.h" +#include "tfile.h" + +using namespace TagLib; + +class MP4::Mp4IsoFullBox::Mp4IsoFullBoxPrivate +{ +public: + uchar version; + uint flags; +}; // Mp4IsoFullBoxPrivate + + +MP4::Mp4IsoFullBox::Mp4IsoFullBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) +: Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4IsoFullBox::Mp4IsoFullBoxPrivate(); +} + +MP4::Mp4IsoFullBox::~Mp4IsoFullBox() +{ + delete d; +} + +void MP4::Mp4IsoFullBox::parsebox() +{ + // seek to offset + Mp4IsoBox::file()->seek(Mp4IsoBox::offset(), File::Beginning ); + // parse version and flags + ByteVector version_flags = Mp4IsoBox::file()->readBlock(4); + d->version = version_flags[0]; + d->flags = version_flags[1] << 16 || version_flags[2] << 8 || version_flags[3]; + // call parse method of subclass + parse(); +} + +TagLib::uchar MP4::Mp4IsoFullBox::version() +{ + return d->version; +} + +TagLib::uint MP4::Mp4IsoFullBox::flags() +{ + return d->flags; +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4isofullbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4isofullbox.h new file mode 100755 index 000000000..de62a9ef6 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4isofullbox.h @@ -0,0 +1,36 @@ +#ifndef MP4ISOFULLBOX_H +#define MP4ISOFULLBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4IsoFullBox : public Mp4IsoBox + { + public: + //! constructor for full box + Mp4IsoFullBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ); + //! destructor for mp4 iso full box + virtual ~Mp4IsoFullBox(); + + //! function to get the version of box + uchar version(); + //! function to get the flag map + uint flags(); + + //! parse wrapper to get common interface for both box and fullbox + virtual void parsebox(); + + protected: + class Mp4IsoFullBoxPrivate; + Mp4IsoFullBoxPrivate* d; + }; + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4ISOFULLBOX_H + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4itunestag.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4itunestag.cpp new file mode 100755 index 000000000..341b91c35 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4itunestag.cpp @@ -0,0 +1,202 @@ +#include "mp4itunestag.h" + +using namespace TagLib; + +class MP4::Tag::TagPrivate +{ +public: + MP4::File* mp4file; + TagLib::String title; + TagLib::String artist; + TagLib::String album; + TagLib::String genre; + TagLib::uint year; + TagLib::uint track; + TagLib::uint numTracks; + TagLib::String comment; + TagLib::String grouping; + TagLib::String composer; + TagLib::uint disk; + TagLib::uint numDisks; + TagLib::uint bpm; + bool isEmpty; + TagLib::ByteVector cover; +}; + + +MP4::Tag::Tag( ) +{ + d = new TagPrivate(); + d->year = 0; + d->track = 0; + d->numTracks = 0; + d->disk = 0; + d->numTracks = 0; + d->bpm = 0; + d->isEmpty = true; +} + +MP4::Tag::~Tag() +{ + delete d; +} + +String MP4::Tag::title() const +{ + return d->title; +} + +String MP4::Tag::artist() const +{ + return d->artist; +} + +String MP4::Tag::album() const +{ + return d->album; +} + +String MP4::Tag::comment() const +{ + return d->comment; +} + +String MP4::Tag::genre() const +{ + return d->genre; +} + +TagLib::uint MP4::Tag::year() const +{ + return d->year; +} + +TagLib::uint MP4::Tag::track() const +{ + return d->track; +} + +TagLib::uint MP4::Tag::numTracks() const +{ + return d->numTracks; +} + +String MP4::Tag::grouping() const +{ + return d->grouping; +} + +String MP4::Tag::composer() const +{ + return d->composer; +} + +TagLib::uint MP4::Tag::disk() const +{ + return d->disk; +} + +TagLib::uint MP4::Tag::numDisks() const +{ + return d->numDisks; +} + +TagLib::uint MP4::Tag::bpm() const +{ + return d->bpm; +} + +TagLib::ByteVector MP4::Tag::cover() const +{ + return d->cover; +} + +void MP4::Tag::setTitle(const String &s) +{ + d->title = s; + d->isEmpty = false; +} + +void MP4::Tag::setArtist(const String &s) +{ + d->artist = s; + d->isEmpty = false; +} + +void MP4::Tag::setAlbum(const String &s) +{ + d->album = s; + d->isEmpty = false; +} + +void MP4::Tag::setComment(const String &s) +{ + d->comment = s; + d->isEmpty = false; +} + +void MP4::Tag::setGenre(const String &s) +{ + d->genre = s; + d->isEmpty = false; +} + +void MP4::Tag::setYear(TagLib::uint i) +{ + d->year = i; + d->isEmpty = false; +} + +void MP4::Tag::setTrack(TagLib::uint i) +{ + d->track = i; + d->isEmpty = false; +} + +void MP4::Tag::setNumTracks(TagLib::uint i) +{ + d->numTracks = i; + d->isEmpty = false; +} + +void MP4::Tag::setGrouping(const String &s) +{ + d->grouping = s; + d->isEmpty = false; +} + +void MP4::Tag::setComposer(const String &s) +{ + d->composer = s; + d->isEmpty = false; +} + +void MP4::Tag::setDisk(const TagLib::uint i) +{ + d->disk = i; + d->isEmpty = false; +} + +void MP4::Tag::setNumDisks(const TagLib::uint i) +{ + d->numDisks = i; + d->isEmpty = false; +} + +void MP4::Tag::setBpm(const TagLib::uint i) +{ + d->bpm = i; + d->isEmpty = false; +} + +void MP4::Tag::setCover(const TagLib::ByteVector& c) +{ + d->cover = c; + d->isEmpty = false; +} + +bool MP4::Tag::isEmpty() const +{ + return d->isEmpty; +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4itunestag.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4itunestag.h new file mode 100755 index 000000000..7f0d6a050 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4itunestag.h @@ -0,0 +1,76 @@ +#ifndef MP4ITUNESTAG_H +#define MP4ITUNESTAG_H + +#include "taglib.h" +#include "tstring.h" +#include "tag.h" + +namespace TagLib +{ + namespace MP4 + { + class File; + + class Tag : public TagLib::Tag + { + public: + /*! + * Constructs an empty MP4 iTunes tag. + */ + Tag( ); + + /*! + * Destroys this Tag instance. + */ + virtual ~Tag(); + + // Reimplementations. + + virtual String title() const; + virtual String artist() const; + virtual String album() const; + virtual String comment() const; + virtual String genre() const; + virtual uint year() const; + virtual uint track() const; + + virtual void setTitle(const String &s); + virtual void setArtist(const String &s); + virtual void setAlbum(const String &s); + virtual void setComment(const String &s); + virtual void setGenre(const String &s); + virtual void setYear(uint i); + virtual void setTrack(uint i); + + // MP4 specific fields + + String grouping() const; + String composer() const; + uint numTracks() const; + uint disk() const; + uint numDisks() const; + uint bpm() const; + ByteVector cover() const; + + void setGrouping(const String &s); + void setComposer(const String &s); + void setNumTracks(const uint i); + void setDisk(const uint i); + void setNumDisks(const uint i); + void setBpm(const uint i); + void setCover( const ByteVector& cover ); + + virtual bool isEmpty() const; + + private: + Tag(const Tag &); + Tag &operator=(const Tag &); + + class TagPrivate; + TagPrivate *d; + }; + } // namespace MP4 + +} // namespace TagLib + +#endif // MP4ITUNESTAG_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4mdiabox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4mdiabox.cpp new file mode 100755 index 000000000..8cd57535e --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4mdiabox.cpp @@ -0,0 +1,90 @@ +#include "tlist.h" +#include +#include "mp4mdiabox.h" +#include "mp4hdlrbox.h" +#include "mp4minfbox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4MdiaBox::Mp4MdiaBoxPrivate +{ +public: + //! container for all boxes in mdia box + TagLib::List mdiaBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; +}; // class Mp4MdiaBoxPrivate + +MP4::Mp4MdiaBox::Mp4MdiaBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4MdiaBox::Mp4MdiaBoxPrivate(); +} + +MP4::Mp4MdiaBox::~Mp4MdiaBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->mdiaBoxes.begin(); + delIter != d->mdiaBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4MdiaBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 8; + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + + // stores the current handler type + TagLib::MP4::Fourcc hdlrtype; + + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " mdia box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + if( static_cast( fourcc ) == 0x6d696e66 /*"minf"*/ ) + { + // cast to minf + Mp4MinfBox* minfbox = static_cast( curbox ); + if(!minfbox) + return; + // set handler type + minfbox->setHandlerType( hdlrtype ); + } + + curbox->parsebox(); + d->mdiaBoxes.append( curbox ); + + if(static_cast( fourcc ) == 0x68646c72 /*"hdlr"*/ ) + { + // cast to hdlr box + Mp4HdlrBox* hdlrbox = static_cast( curbox ); + if(!hdlrbox) + return; + // get handler type + hdlrtype = hdlrbox->hdlr_type(); + } + // check for end of mdia box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; + + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4mdiabox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4mdiabox.h new file mode 100755 index 000000000..2711253a6 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4mdiabox.h @@ -0,0 +1,28 @@ +#ifndef MP4MDIABOX_H +#define MP4MDIABOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4MdiaBox: public Mp4IsoBox + { + public: + Mp4MdiaBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4MdiaBox(); + + //! parse mdia contents + void parse(); + + private: + class Mp4MdiaBoxPrivate; + Mp4MdiaBoxPrivate* d; + }; // Mp4MdiaBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4MDIABOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4metabox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4metabox.cpp new file mode 100755 index 000000000..e4e074ed8 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4metabox.cpp @@ -0,0 +1,65 @@ +#include +#include +#include "mp4metabox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4MetaBox::Mp4MetaBoxPrivate +{ +public: + //! container for all boxes in meta box + TagLib::List metaBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; +}; // class Mp4MetaBoxPrivate + +MP4::Mp4MetaBox::Mp4MetaBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoFullBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4MetaBox::Mp4MetaBoxPrivate(); +} + +MP4::Mp4MetaBox::~Mp4MetaBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->metaBoxes.begin(); + delIter != d->metaBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4MetaBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 12; // initial size of box + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " meta box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + curbox->parsebox(); + d->metaBoxes.append( curbox ); + + // check for end of meta box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4metabox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4metabox.h new file mode 100755 index 000000000..1fac0143c --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4metabox.h @@ -0,0 +1,28 @@ +#ifndef MP4METABOX_H +#define MP4METABOX_H + +#include "mp4isofullbox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4MetaBox: public Mp4IsoFullBox + { + public: + Mp4MetaBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4MetaBox(); + + //! parse meta contents + void parse(); + + private: + class Mp4MetaBoxPrivate; + Mp4MetaBoxPrivate* d; + }; // Mp4MetaBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4METABOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4minfbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4minfbox.cpp new file mode 100755 index 000000000..fa45fa8fa --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4minfbox.cpp @@ -0,0 +1,83 @@ +#include "tlist.h" +#include +#include "mp4minfbox.h" +#include "mp4stblbox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4MinfBox::Mp4MinfBoxPrivate +{ +public: + //! container for all boxes in minf box + TagLib::List minfBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; + //! stores the handler type of the current trak + MP4::Fourcc handler_type; +}; // class Mp4MinfBoxPrivate + +MP4::Mp4MinfBox::Mp4MinfBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4MinfBox::Mp4MinfBoxPrivate(); +} + +MP4::Mp4MinfBox::~Mp4MinfBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->minfBoxes.begin(); + delIter != d->minfBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4MinfBox::setHandlerType( MP4::Fourcc fourcc ) +{ + d->handler_type = fourcc; +} + +void MP4::Mp4MinfBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 8; + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " minf box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + if(static_cast( fourcc ) == 0x7374626c /*stbl*/ ) + { + // cast to hdlr box + Mp4StblBox* stblbox = static_cast( curbox ); + if(!stblbox) + return; + // set handler type + stblbox->setHandlerType( d->handler_type ); + } + + curbox->parsebox(); + d->minfBoxes.append( curbox ); + + // check for end of minf box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4minfbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4minfbox.h new file mode 100755 index 000000000..1f617f814 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4minfbox.h @@ -0,0 +1,30 @@ +#ifndef MP4MINFBOX_H +#define MP4MINFBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4MinfBox: public Mp4IsoBox + { + public: + Mp4MinfBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4MinfBox(); + + //! parse minf contents + void parse(); + //! set the handler type - needed for stsd + void setHandlerType( MP4::Fourcc fourcc ); + + private: + class Mp4MinfBoxPrivate; + Mp4MinfBoxPrivate* d; + }; // Mp4MinfBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4MINFBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4moovbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4moovbox.cpp new file mode 100755 index 000000000..5dd470845 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4moovbox.cpp @@ -0,0 +1,65 @@ +#include "tlist.h" +#include +#include "mp4moovbox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4MoovBox::Mp4MoovBoxPrivate +{ +public: + //! container for all boxes in moov box + TagLib::List moovBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; +}; // class Mp4MoovBoxPrivate + +MP4::Mp4MoovBox::Mp4MoovBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4MoovBox::Mp4MoovBoxPrivate(); +} + +MP4::Mp4MoovBox::~Mp4MoovBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->moovBoxes.begin(); + delIter != d->moovBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4MoovBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 8; + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " moov box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + curbox->parsebox(); + d->moovBoxes.append( curbox ); + + // check for end of moov box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4moovbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4moovbox.h new file mode 100755 index 000000000..f150ab644 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4moovbox.h @@ -0,0 +1,28 @@ +#ifndef MP4MOOVBOX_H +#define MP4MOOVBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4MoovBox: public Mp4IsoBox + { + public: + Mp4MoovBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4MoovBox(); + + //! parse moov contents + void parse(); + + private: + class Mp4MoovBoxPrivate; + Mp4MoovBoxPrivate* d; + }; // Mp4MoovBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4MOOVBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4mvhdbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4mvhdbox.cpp new file mode 100755 index 000000000..0012e9c59 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4mvhdbox.cpp @@ -0,0 +1,119 @@ +#include +#include +#include "mp4mvhdbox.h" +#include "boxfactory.h" +#include "mp4file.h" +#include "mp4propsproxy.h" + +using namespace TagLib; + +class MP4::Mp4MvhdBox::Mp4MvhdBoxPrivate +{ +public: + //! creation time of the file + TagLib::ulonglong creationTime; + //! modification time of the file - since midnight, Jan. 1, 1904, UTC-time + TagLib::ulonglong modificationTime; + //! timescale for the file - referred by all time specifications in this box + TagLib::uint timescale; + //! duration of presentation + TagLib::ulonglong duration; + //! playout speed + TagLib::uint rate; + //! volume for entire presentation + TagLib::uint volume; + //! track ID for an additional track (next new track) + TagLib::uint nextTrackID; +}; // class Mp4MvhdBoxPrivate + +MP4::Mp4MvhdBox::Mp4MvhdBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoFullBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4MvhdBox::Mp4MvhdBoxPrivate(); +} + +MP4::Mp4MvhdBox::~Mp4MvhdBox() +{ + delete d; +} + +TagLib::ulonglong MP4::Mp4MvhdBox::creationTime() const +{ + return d->creationTime; +} + +TagLib::ulonglong MP4::Mp4MvhdBox::modificationTime() const +{ + return d->modificationTime; +} + +TagLib::uint MP4::Mp4MvhdBox::timescale() const +{ + return d->timescale; +} + +TagLib::ulonglong MP4::Mp4MvhdBox::duration() const +{ + return d->duration; +} + +TagLib::uint MP4::Mp4MvhdBox::rate() const +{ + return d->rate; +} + +TagLib::uint MP4::Mp4MvhdBox::volume() const +{ + return d->volume; +} + +TagLib::uint MP4::Mp4MvhdBox::nextTrackID() const +{ + return d->nextTrackID; +} + + +void MP4::Mp4MvhdBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + if( version() == 1 ) + { + if( !mp4file->readLongLong( d->creationTime ) ) + return; + if( !mp4file->readLongLong( d->modificationTime ) ) + return; + if( !mp4file->readInt( d->timescale ) ) + return; + if( !mp4file->readLongLong( d->duration ) ) + return; + } + else + { + TagLib::uint creationTime_tmp, modificationTime_tmp, duration_tmp; + + if( !mp4file->readInt( creationTime_tmp ) ) + return; + if( !mp4file->readInt( modificationTime_tmp ) ) + return; + if( !mp4file->readInt( d->timescale ) ) + return; + if( !mp4file->readInt( duration_tmp ) ) + return; + + d->creationTime = creationTime_tmp; + d->modificationTime = modificationTime_tmp; + d->duration = duration_tmp; + } + if( !mp4file->readInt( d->rate ) ) + return; + if( !mp4file->readInt( d->volume ) ) + return; + // jump over unused fields + mp4file->seek( 68, File::Current ); + + if( !mp4file->readInt( d->nextTrackID ) ) + return; + // register at proxy + mp4file->propProxy()->registerMvhd( this ); +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4mvhdbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4mvhdbox.h new file mode 100755 index 000000000..45ea47d26 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4mvhdbox.h @@ -0,0 +1,44 @@ +#ifndef MP4MVHDBOX_H +#define MP4MVHDBOX_H + +#include "mp4isofullbox.h" +#include "mp4fourcc.h" +#include "mp4file.h" // ulonglong + +namespace TagLib +{ + namespace MP4 + { + class Mp4MvhdBox: public Mp4IsoFullBox + { + public: + Mp4MvhdBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4MvhdBox(); + + //! function to get the creation time of the mp4 file + ulonglong creationTime() const; + //! function to get the modification time of the mp4 file + ulonglong modificationTime() const; + //! function to get the timescale referenced by the above timestamps + uint timescale() const; + //! function to get the presentation duration in the mp4 file + ulonglong duration() const; + //! function to get the rate (playout speed) - typically 1.0; + uint rate() const; + //! function to get volume level for presentation - typically 1.0; + uint volume() const; + //! function to get the track ID for adding new tracks - useless for this lib + uint nextTrackID() const; + + //! parse mvhd contents + void parse(); + + private: + class Mp4MvhdBoxPrivate; + Mp4MvhdBoxPrivate* d; + }; // Mp4MvhdBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4MVHDBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4propsproxy.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4propsproxy.cpp new file mode 100755 index 000000000..055d10668 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4propsproxy.cpp @@ -0,0 +1,68 @@ +#include "mp4propsproxy.h" + +using namespace TagLib; + +class MP4::Mp4PropsProxy::Mp4PropsProxyPrivate +{ +public: + //! the movie header box + MP4::Mp4MvhdBox* mvhdbox; + //! the sample table box + MP4::Mp4AudioSampleEntry* audiosampleentry; +}; + + +MP4::Mp4PropsProxy::Mp4PropsProxy() +{ + d = new MP4::Mp4PropsProxy::Mp4PropsProxyPrivate(); + d->mvhdbox = 0; + d->audiosampleentry = 0; +} + +MP4::Mp4PropsProxy::~Mp4PropsProxy() +{ + delete d; +} + +TagLib::uint MP4::Mp4PropsProxy::seconds() const +{ + if( d->mvhdbox ) + return static_cast( d->mvhdbox->duration() / d->mvhdbox->timescale() ); + else + return 0; +} + +TagLib::uint MP4::Mp4PropsProxy::channels() const +{ + if( d->audiosampleentry ) + return d->audiosampleentry->channels(); + else + return 0; +} + +TagLib::uint MP4::Mp4PropsProxy::sampleRate() const +{ + if( d->audiosampleentry ) + return (d->audiosampleentry->samplerate()>>16); + else + return 0; +} + +TagLib::uint MP4::Mp4PropsProxy::bitRate() const +{ + if( d->audiosampleentry ) + return (d->audiosampleentry->bitrate()); + else + return 0; +} + +void MP4::Mp4PropsProxy::registerMvhd( MP4::Mp4MvhdBox* mvhdbox ) +{ + d->mvhdbox = mvhdbox; +} + +void MP4::Mp4PropsProxy::registerAudioSampleEntry( MP4::Mp4AudioSampleEntry* audioSampleEntry ) +{ + d->audiosampleentry = audioSampleEntry; +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4propsproxy.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4propsproxy.h new file mode 100755 index 000000000..2e43c4381 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4propsproxy.h @@ -0,0 +1,44 @@ +#ifndef MP4PROPSPROXY_H +#define MP4PROPSPROXY_H MP4PROPSPROXY_H +#include "mp4mvhdbox.h" +#include "mp4audiosampleentry.h" + +namespace TagLib +{ + namespace MP4 + { + //! Mp4PropsProxy is used to access the stsd box and mvhd box directly + /*! this class works as a shortcut to avoid stepping through all parent boxes + * to access the boxes in question + */ + class Mp4PropsProxy + { + public: + //! constructor for properties proxy + Mp4PropsProxy(); + //! destructor + ~Mp4PropsProxy(); + + //! function to get length of media in seconds + TagLib::uint seconds() const; + //! function to get the nunmber of channels + TagLib::uint channels() const; + //! function to get the sample rate + TagLib::uint sampleRate() const; + //! function to get the bitrate rate + TagLib::uint bitRate() const; + + //! function to register the movie header box - mvhd + void registerMvhd( MP4::Mp4MvhdBox* mvhdbox ); + //! function to register the sample description box + void registerAudioSampleEntry( MP4::Mp4AudioSampleEntry* audiosampleentry ); + + private: + class Mp4PropsProxyPrivate; + Mp4PropsProxyPrivate* d; + + }; // Mp4PropsProxy + } // MP4 +} // TagLib + +#endif // MP4PROPSPROXY_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4sampleentry.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4sampleentry.cpp new file mode 100755 index 000000000..67b5d0617 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4sampleentry.cpp @@ -0,0 +1,38 @@ +#include "mp4sampleentry.h" +#include "mp4isobox.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4SampleEntry::Mp4SampleEntryPrivate +{ +public: + TagLib::uint data_reference_index; +}; + +MP4::Mp4SampleEntry::Mp4SampleEntry( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::Mp4SampleEntry::Mp4SampleEntryPrivate(); +} + +MP4::Mp4SampleEntry::~Mp4SampleEntry() +{ + delete d; +} + +//! parse the content of the box +void MP4::Mp4SampleEntry::parse() +{ + TagLib::MP4::File* mp4file = static_cast(file()); + if(!mp4file) + return; + + // skip the first 6 bytes + mp4file->seek( 6, TagLib::File::Current ); + // read data reference index + if(!mp4file->readShort( d->data_reference_index)) + return; + parseEntry(); +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4sampleentry.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4sampleentry.h new file mode 100755 index 000000000..7cddfc353 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4sampleentry.h @@ -0,0 +1,33 @@ +#ifndef MP4SAMPLEENTRY_H +#define MP4SAMPLEENTRY_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4SampleEntry: public Mp4IsoBox + { + public: + Mp4SampleEntry( File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~Mp4SampleEntry(); + + public: + //! parse the content of the box + virtual void parse(); + + private: + //! function to be implemented in subclass + virtual void parseEntry() = 0; + + protected: + class Mp4SampleEntryPrivate; + Mp4SampleEntryPrivate* d; + }; // class Mp4SampleEntry + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4SAMPLEENTRY_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4skipbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4skipbox.cpp new file mode 100755 index 000000000..a497578a1 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4skipbox.cpp @@ -0,0 +1,29 @@ +#include "mp4skipbox.h" +#include "mp4isobox.h" +#include "tfile.h" + +using namespace TagLib; + +class MP4::Mp4SkipBox::Mp4SkipBoxPrivate +{ +public: +}; + +MP4::Mp4SkipBox::Mp4SkipBox( TagLib::File* file, MP4::Fourcc fourcc, uint size, long offset ) + :Mp4IsoBox(file, fourcc, size, offset) +{ + d = new MP4::Mp4SkipBox::Mp4SkipBoxPrivate(); +} + +MP4::Mp4SkipBox::~Mp4SkipBox() +{ + delete d; +} + +//! parse the content of the box +void MP4::Mp4SkipBox::parse() +{ + // skip contents + file()->seek( size() - 8, TagLib::File::Current ); +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4skipbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4skipbox.h new file mode 100755 index 000000000..44a8a11cf --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4skipbox.h @@ -0,0 +1,29 @@ +#ifndef MP4SKIPBOX_H +#define MP4SKIPBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4SkipBox: public Mp4IsoBox + { + public: + Mp4SkipBox( File* file, MP4::Fourcc fourcc, uint size, long offset ); + ~Mp4SkipBox(); + + private: + //! parse the content of the box + virtual void parse(); + + protected: + class Mp4SkipBoxPrivate; + Mp4SkipBoxPrivate* d; + }; // class Mp4SkipBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4SKIPBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4stblbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4stblbox.cpp new file mode 100755 index 000000000..6d4044714 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4stblbox.cpp @@ -0,0 +1,84 @@ +#include "tlist.h" +#include +#include "mp4stblbox.h" +#include "mp4stsdbox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4StblBox::Mp4StblBoxPrivate +{ +public: + //! container for all boxes in stbl box + TagLib::List stblBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; + //! the handler type for the current trak + MP4::Fourcc handler_type; +}; // class Mp4StblBoxPrivate + +MP4::Mp4StblBox::Mp4StblBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4StblBox::Mp4StblBoxPrivate(); +} + +MP4::Mp4StblBox::~Mp4StblBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->stblBoxes.begin(); + delIter != d->stblBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4StblBox::setHandlerType( MP4::Fourcc fourcc ) +{ + d->handler_type = fourcc; +} + +void MP4::Mp4StblBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 8; + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " stbl box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + + // check for stsd + if( static_cast(fourcc) == 0x73747364 /*'stsd'*/ ) + { + // cast to stsd box + MP4::Mp4StsdBox* stsdbox = static_cast(curbox); + if(!stsdbox) + return; + // set the handler type + stsdbox->setHandlerType( d->handler_type ); + } + curbox->parsebox(); + d->stblBoxes.append( curbox ); + + // check for end of stbl box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4stblbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4stblbox.h new file mode 100755 index 000000000..7e06eb83d --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4stblbox.h @@ -0,0 +1,30 @@ +#ifndef MP4STBLBOX_H +#define MP4STBLBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4StblBox: public Mp4IsoBox + { + public: + Mp4StblBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4StblBox(); + + //! parse stbl contents + void parse(); + //! set the handler type - needed for stsd + void setHandlerType( MP4::Fourcc fourcc ); + + private: + class Mp4StblBoxPrivate; + Mp4StblBoxPrivate* d; + }; // Mp4StblBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4STBLBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4stsdbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4stsdbox.cpp new file mode 100755 index 000000000..9ccb35e83 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4stsdbox.cpp @@ -0,0 +1,70 @@ +#include "tlist.h" +#include +#include "mp4stsdbox.h" +#include "mp4audiosampleentry.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4StsdBox::Mp4StsdBoxPrivate +{ +public: + //! the handler type for the current trak + MP4::Fourcc handler_type; + //! the audio sample entry + MP4::Mp4AudioSampleEntry* audioSampleEntry; +}; // class Mp4StsdBoxPrivate + +MP4::Mp4StsdBox::Mp4StsdBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoFullBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4StsdBox::Mp4StsdBoxPrivate(); +} + +MP4::Mp4StsdBox::~Mp4StsdBox() +{ + delete d; +} + +void MP4::Mp4StsdBox::setHandlerType( MP4::Fourcc fourcc ) +{ + d->handler_type = fourcc; +} + +void MP4::Mp4StsdBox::parse() +{ + MP4::File* mp4file = static_cast( file() ); + if(!mp4file) + return; + + TagLib::uint totalsize = 12; // initial size of box + + // check for handler type - only parse if 'soun': + if( static_cast(d->handler_type) == 0x736f756e ) + { + // read entry count + TagLib::uint entry_count; + if(!mp4file->readInt( entry_count )) + return; + + // simply read first entry and skip all following + // read size and type + TagLib::uint cursize; + MP4::Fourcc fourcc; + if( !mp4file->readSizeAndType( cursize, fourcc )) + return; + + totalsize += 12; + // alocate an AudioSampleEntry + d->audioSampleEntry = new MP4::Mp4AudioSampleEntry( mp4file, fourcc, cursize, mp4file->tell() ); + // parse the AudioSampleEntry + d->audioSampleEntry->parse(); + totalsize += cursize-8; + // skip the remaining box contents + mp4file->seek( size()-totalsize, TagLib::File::Current ); + } + else + { + mp4file->seek( size()-totalsize, TagLib::File::Current ); + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4stsdbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4stsdbox.h new file mode 100755 index 000000000..67c077ac2 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4stsdbox.h @@ -0,0 +1,30 @@ +#ifndef MP4STSDBOX_H +#define MP4STSDBOX_H + +#include "mp4isofullbox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4StsdBox: public Mp4IsoFullBox + { + public: + Mp4StsdBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4StsdBox(); + + //! parse stsd contents + void parse(); + //! set the handler type - needed for stsd + void setHandlerType( MP4::Fourcc fourcc ); + + private: + class Mp4StsdBoxPrivate; + Mp4StsdBoxPrivate* d; + }; // Mp4StsdBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4STSDBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4tagsproxy.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4tagsproxy.cpp new file mode 100755 index 000000000..eeb5364bb --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4tagsproxy.cpp @@ -0,0 +1,147 @@ +#include "mp4tagsproxy.h" +#include "itunesdatabox.h" + +using namespace TagLib; + +class MP4::Mp4TagsProxy::Mp4TagsProxyPrivate +{ +public: + ITunesDataBox* titleData; + ITunesDataBox* artistData; + ITunesDataBox* albumData; + ITunesDataBox* coverData; + ITunesDataBox* genreData; + ITunesDataBox* yearData; + ITunesDataBox* trknData; + ITunesDataBox* commentData; + ITunesDataBox* groupingData; + ITunesDataBox* composerData; + ITunesDataBox* diskData; + ITunesDataBox* bpmData; +}; + +MP4::Mp4TagsProxy::Mp4TagsProxy() +{ + d = new MP4::Mp4TagsProxy::Mp4TagsProxyPrivate(); + d->titleData = 0; + d->artistData = 0; + d->albumData = 0; + d->coverData = 0; + d->genreData = 0; + d->yearData = 0; + d->trknData = 0; + d->commentData = 0; + d->groupingData = 0; + d->composerData = 0; + d->diskData = 0; + d->bpmData = 0; +} + +MP4::Mp4TagsProxy::~Mp4TagsProxy() +{ + delete d; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::titleData() const +{ + return d->titleData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::artistData() const +{ + return d->artistData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::albumData() const +{ + return d->albumData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::genreData() const +{ + return d->genreData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::yearData() const +{ + return d->yearData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::trknData() const +{ + return d->trknData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::commentData() const +{ + return d->commentData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::groupingData() const +{ + return d->groupingData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::composerData() const +{ + return d->composerData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::diskData() const +{ + return d->diskData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::bpmData() const +{ + return d->bpmData; +} + +MP4::ITunesDataBox* MP4::Mp4TagsProxy::coverData() const +{ + return d->coverData; +} + +void MP4::Mp4TagsProxy::registerBox( EBoxType boxtype, ITunesDataBox* databox ) +{ + switch( boxtype ) + { + case title: + d->titleData = databox; + break; + case artist: + d->artistData = databox; + break; + case album: + d->albumData = databox; + break; + case cover: + d->coverData = databox; + break; + case genre: + d->genreData = databox; + break; + case year: + d->yearData = databox; + break; + case trackno: + d->trknData = databox; + break; + case comment: + d->commentData = databox; + break; + case grouping: + d->groupingData = databox; + break; + case composer: + d->composerData = databox; + break; + case disk: + d->diskData = databox; + break; + case bpm: + d->bpmData = databox; + break; + } +} + diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4tagsproxy.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4tagsproxy.h new file mode 100755 index 000000000..40d0b58fa --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4tagsproxy.h @@ -0,0 +1,78 @@ +#ifndef MP4TAGSPROXY_H +#define MP4TAGSPROXY_H + +namespace TagLib +{ + namespace MP4 + { + // forward declaration(s) + class ITunesDataBox; + /*! proxy for mp4 itunes tag relevant boxes + * + * this class works as a proxy for the specific tag boxes + * in an mp4 itunes file. the boxes are mired in + * the mp4 file structure and stepping through all box layers + * is avoided by registration at the proxy object. + */ + class Mp4TagsProxy + { + public: + /*! enum for all supported box types */ + typedef enum + { + title = 0, + artist, + album, + cover, + genre, + year, + trackno, + comment, + grouping, + composer, + disk, + bpm + } EBoxType; + + //! constructor + Mp4TagsProxy(); + //! destructor + ~Mp4TagsProxy(); + + //! function to get the data box for the title + ITunesDataBox* titleData() const; + //! function to get the data box for the artist + ITunesDataBox* artistData() const; + //! function to get the data box for the album + ITunesDataBox* albumData() const; + //! function to get the data box for the genre + ITunesDataBox* genreData() const; + //! function to get the data box for the year + ITunesDataBox* yearData() const; + //! function to get the data box for the track number + ITunesDataBox* trknData() const; + //! function to get the data box for the comment + ITunesDataBox* commentData() const; + //! function to get the data box for the grouping + ITunesDataBox* groupingData() const; + //! function to get the data box for the composer + ITunesDataBox* composerData() const; + //! function to get the data box for the disk number + ITunesDataBox* diskData() const; + //! function to get the data box for the bpm + ITunesDataBox* bpmData() const; + //! function to get the data box for the cover + ITunesDataBox* coverData() const; + + //! function to register a data box for a certain box type + void registerBox( EBoxType boxtype, ITunesDataBox* databox ); + + private: + class Mp4TagsProxyPrivate; + //! private data of tags proxy + Mp4TagsProxyPrivate* d; + }; // class Mp4TagsProxy + } // namespace MP4 +} // namespace TagLib + +#endif // MP4TAGSPROXY_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4trakbox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4trakbox.cpp new file mode 100755 index 000000000..19d5c27c3 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4trakbox.cpp @@ -0,0 +1,65 @@ +#include "tlist.h" +#include +#include "mp4trakbox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4TrakBox::Mp4TrakBoxPrivate +{ +public: + //! container for all boxes in trak box + TagLib::List trakBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; +}; // class Mp4TrakBoxPrivate + +MP4::Mp4TrakBox::Mp4TrakBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4TrakBox::Mp4TrakBoxPrivate(); +} + +MP4::Mp4TrakBox::~Mp4TrakBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->trakBoxes.begin(); + delIter != d->trakBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4TrakBox::parse() +{ + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 8; + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " trak box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + curbox->parsebox(); + d->trakBoxes.append( curbox ); + + // check for end of trak box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4trakbox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4trakbox.h new file mode 100755 index 000000000..83170119d --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4trakbox.h @@ -0,0 +1,28 @@ +#ifndef MP4TRAKBOX_H +#define MP4TRAKBOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4TrakBox: public Mp4IsoBox + { + public: + Mp4TrakBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4TrakBox(); + + //! parse trak contents + void parse(); + + private: + class Mp4TrakBoxPrivate; + Mp4TrakBoxPrivate* d; + }; // Mp4TrakBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4TRAKBOX_H diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4udtabox.cpp b/Frameworks/TagLib/taglib/taglib/m4a/mp4udtabox.cpp new file mode 100755 index 000000000..dbf901a56 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4udtabox.cpp @@ -0,0 +1,74 @@ +#include "tlist.h" +#include +#include "mp4udtabox.h" +#include "boxfactory.h" +#include "mp4file.h" + +using namespace TagLib; + +class MP4::Mp4UdtaBox::Mp4UdtaBoxPrivate +{ +public: + //! container for all boxes in udta box + TagLib::List udtaBoxes; + //! a box factory for creating the appropriate boxes + MP4::BoxFactory boxfactory; +}; // class Mp4UdtaBoxPrivate + +MP4::Mp4UdtaBox::Mp4UdtaBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ) + : Mp4IsoBox( file, fourcc, size, offset ) +{ + d = new MP4::Mp4UdtaBox::Mp4UdtaBoxPrivate(); +} + +MP4::Mp4UdtaBox::~Mp4UdtaBox() +{ + TagLib::List::Iterator delIter; + for( delIter = d->udtaBoxes.begin(); + delIter != d->udtaBoxes.end(); + delIter++ ) + { + delete *delIter; + } + delete d; +} + +void MP4::Mp4UdtaBox::parse() +{ +#if 0 + std::cout << " parsing udta box" << std::endl; +#endif + TagLib::MP4::File* mp4file = static_cast( file() ); + + TagLib::uint totalsize = 8; + // parse all contained boxes + TagLib::uint size; + MP4::Fourcc fourcc; + +#if 0 + std::cout << " "; +#endif + while( (mp4file->readSizeAndType( size, fourcc ) == true) ) + { + totalsize += size; + + // check for errors + if( totalsize > MP4::Mp4IsoBox::size() ) + { + std::cerr << "Error in mp4 file " << mp4file->name() << " udta box contains bad box with name: " << fourcc.toString() << std::endl; + return; + } + + // create the appropriate subclass and parse it + MP4::Mp4IsoBox* curbox = d->boxfactory.createInstance( mp4file, fourcc, size, mp4file->tell() ); + curbox->parsebox(); + d->udtaBoxes.append( curbox ); + + // check for end of udta box + if( totalsize == MP4::Mp4IsoBox::size() ) + break; +#if 0 + std::cout << " "; +#endif + } +} diff --git a/Frameworks/TagLib/taglib/taglib/m4a/mp4udtabox.h b/Frameworks/TagLib/taglib/taglib/m4a/mp4udtabox.h new file mode 100755 index 000000000..06ce955ec --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/m4a/mp4udtabox.h @@ -0,0 +1,28 @@ +#ifndef MP4UDTABOX_H +#define MP4UDTABOX_H + +#include "mp4isobox.h" +#include "mp4fourcc.h" + +namespace TagLib +{ + namespace MP4 + { + class Mp4UdtaBox: public Mp4IsoBox + { + public: + Mp4UdtaBox( TagLib::File* file, MP4::Fourcc fourcc, TagLib::uint size, long offset ); + ~Mp4UdtaBox(); + + //! parse moov contents + void parse(); + + private: + class Mp4UdtaBoxPrivate; + Mp4UdtaBoxPrivate* d; + }; // Mp4UdtaBox + + } // namespace MP4 +} // namespace TagLib + +#endif // MP4UDTABOX_H diff --git a/Frameworks/TagLib/Files/taglib/mpc/combinedtag.h b/Frameworks/TagLib/taglib/taglib/mpc/combinedtag.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpc/combinedtag.h rename to Frameworks/TagLib/taglib/taglib/mpc/combinedtag.h diff --git a/Frameworks/TagLib/Files/taglib/mpc/mpcfile.cpp b/Frameworks/TagLib/taglib/taglib/mpc/mpcfile.cpp old mode 100644 new mode 100755 similarity index 99% rename from Frameworks/TagLib/Files/taglib/mpc/mpcfile.cpp rename to Frameworks/TagLib/taglib/taglib/mpc/mpcfile.cpp index a72e55a73..c608e8767 --- a/Frameworks/TagLib/Files/taglib/mpc/mpcfile.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpc/mpcfile.cpp @@ -89,6 +89,11 @@ public: // public members //////////////////////////////////////////////////////////////////////////////// +MPC::File::File() : TagLib::File() +{ + d = new FilePrivate; +} + MPC::File::File(const char *file, bool readProperties, Properties::ReadStyle propertiesStyle) : TagLib::File(file) { @@ -111,6 +116,67 @@ MPC::Properties *MPC::File::audioProperties() const return d->properties; } +void MPC::File::read(bool readProperties, Properties::ReadStyle /* propertiesStyle */) +{ + // Look for an ID3v1 tag + + d->ID3v1Location = findID3v1(); + + if(d->ID3v1Location >= 0) { + d->ID3v1Tag = new ID3v1::Tag(this, d->ID3v1Location); + d->hasID3v1 = true; + } + + // Look for an APE tag + + findAPE(); + + d->APELocation = findAPE(); + + if(d->APELocation >= 0) { + d->APETag = new APE::Tag(this, d->APELocation); + d->APESize = d->APETag->footer()->completeTagSize(); + d->APELocation = d->APELocation + d->APETag->footer()->size() - d->APESize; + d->hasAPE = true; + } + + if(d->hasID3v1 && d->hasAPE) + d->tag = new CombinedTag(d->APETag, d->ID3v1Tag); + else { + if(d->hasID3v1) + d->tag = d->ID3v1Tag; + else { + if(d->hasAPE) + d->tag = d->APETag; + else + d->tag = d->APETag = new APE::Tag; + } + } + + // Look for and skip an ID3v2 tag + + d->ID3v2Location = findID3v2(); + + if(d->ID3v2Location >= 0) { + seek(d->ID3v2Location); + d->ID3v2Header = new ID3v2::Header(readBlock(ID3v2::Header::size())); + d->ID3v2Size = d->ID3v2Header->completeTagSize(); + d->hasID3v2 = true; + } + + if(d->hasID3v2) + seek(d->ID3v2Location + d->ID3v2Size); + else + seek(0); + + // Look for MPC metadata + + if(readProperties) { + d->properties = new Properties(readBlock(MPC::HeaderSize), + length() - d->ID3v2Size - d->APESize); + } +} + bool MPC::File::save() { if(readOnly()) { @@ -254,67 +320,6 @@ void MPC::File::remove(int tags) // private members //////////////////////////////////////////////////////////////////////////////// -void MPC::File::read(bool readProperties, Properties::ReadStyle /* propertiesStyle */) -{ - // Look for an ID3v1 tag - - d->ID3v1Location = findID3v1(); - - if(d->ID3v1Location >= 0) { - d->ID3v1Tag = new ID3v1::Tag(this, d->ID3v1Location); - d->hasID3v1 = true; - } - - // Look for an APE tag - - findAPE(); - - d->APELocation = findAPE(); - - if(d->APELocation >= 0) { - d->APETag = new APE::Tag(this, d->APELocation); - d->APESize = d->APETag->footer()->completeTagSize(); - d->APELocation = d->APELocation + d->APETag->footer()->size() - d->APESize; - d->hasAPE = true; - } - - if(d->hasID3v1 && d->hasAPE) - d->tag = new CombinedTag(d->APETag, d->ID3v1Tag); - else { - if(d->hasID3v1) - d->tag = d->ID3v1Tag; - else { - if(d->hasAPE) - d->tag = d->APETag; - else - d->tag = d->APETag = new APE::Tag; - } - } - - // Look for and skip an ID3v2 tag - - d->ID3v2Location = findID3v2(); - - if(d->ID3v2Location >= 0) { - seek(d->ID3v2Location); - d->ID3v2Header = new ID3v2::Header(readBlock(ID3v2::Header::size())); - d->ID3v2Size = d->ID3v2Header->completeTagSize(); - d->hasID3v2 = true; - } - - if(d->hasID3v2) - seek(d->ID3v2Location + d->ID3v2Size); - else - seek(0); - - // Look for MPC metadata - - if(readProperties) { - d->properties = new Properties(readBlock(MPC::HeaderSize), - length() - d->ID3v2Size - d->APESize); - } -} - long MPC::File::findAPE() { if(!isValid()) diff --git a/Frameworks/TagLib/Files/taglib/mpc/mpcfile.h b/Frameworks/TagLib/taglib/taglib/mpc/mpcfile.h old mode 100644 new mode 100755 similarity index 90% rename from Frameworks/TagLib/Files/taglib/mpc/mpcfile.h rename to Frameworks/TagLib/taglib/taglib/mpc/mpcfile.h index aa40e953f..ba01dba9a --- a/Frameworks/TagLib/Files/taglib/mpc/mpcfile.h +++ b/Frameworks/TagLib/taglib/taglib/mpc/mpcfile.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_MPCFILE_H #define TAGLIB_MPCFILE_H +#include "taglib_export.h" #include "tfile.h" #include "mpcproperties.h" @@ -55,7 +56,7 @@ namespace TagLib { * The only invalid tag combination supported is an ID3v1 tag after an APE tag. */ - class File : public TagLib::File + class TAGLIB_EXPORT File : public TagLib::File { public: /*! @@ -75,6 +76,12 @@ namespace TagLib { AllTags = 0xffff }; + /*! + * Contructs an MPC file object without reading a file. Allows object + * fields to be set up before reading. + */ + File(); + /*! * Contructs an MPC file from \a file. If \a readProperties is true the * file's audio properties will also be read using \a propertiesStyle. If @@ -100,6 +107,14 @@ namespace TagLib { */ virtual Properties *audioProperties() const; + /*! + * Reads from MPC file. If \a readProperties is true the file's audio + * properties will also be read using \a propertiesStyle. If false, + * \a propertiesStyle is ignored. + */ + void read(bool readProperties = true, + Properties::ReadStyle propertiesStyle = Properties::Average); + /*! * Saves the file. */ @@ -147,7 +162,6 @@ namespace TagLib { File(const File &); File &operator=(const File &); - void read(bool readProperties, Properties::ReadStyle propertiesStyle); void scan(); long findAPE(); long findID3v1(); diff --git a/Frameworks/TagLib/Files/taglib/mpc/mpcproperties.cpp b/Frameworks/TagLib/taglib/taglib/mpc/mpcproperties.cpp old mode 100644 new mode 100755 similarity index 94% rename from Frameworks/TagLib/Files/taglib/mpc/mpcproperties.cpp rename to Frameworks/TagLib/taglib/taglib/mpc/mpcproperties.cpp index 2d3f863c5..4359281a1 --- a/Frameworks/TagLib/Files/taglib/mpc/mpcproperties.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpc/mpcproperties.cpp @@ -81,13 +81,6 @@ int MPC::Properties::sampleRate() const return d->sampleRate; } -/* -int MPC::Properties::sampleWidth() const -{ - return d->sampleWidth; -} -*/ - int MPC::Properties::channels() const { return d->channels; @@ -121,18 +114,21 @@ void MPC::Properties::read() d->channels = 2; } else { - unsigned int headerData = d->data.mid(0, 4).toUInt(false); + uint headerData = d->data.mid(0, 4).toUInt(false); + d->bitrate = (headerData >> 23) & 0x01ff; d->version = (headerData >> 11) & 0x03ff; d->sampleRate = 44100; d->channels = 2; + if(d->version >= 5) frames = d->data.mid(4, 4).toUInt(false); else - frames = d->data.mid(4, 2).toUInt(false); + frames = d->data.mid(6, 2).toUInt(false); } - unsigned int samples = frames * 1152 - 576; + uint samples = frames * 1152 - 576; + d->length = d->sampleRate > 0 ? (samples + (d->sampleRate / 2)) / d->sampleRate : 0; if(!d->bitrate) diff --git a/Frameworks/TagLib/Files/taglib/mpc/mpcproperties.h b/Frameworks/TagLib/taglib/taglib/mpc/mpcproperties.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpc/mpcproperties.h rename to Frameworks/TagLib/taglib/taglib/mpc/mpcproperties.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1genres.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1genres.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1genres.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1genres.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1genres.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1genres.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1genres.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1genres.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1tag.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1tag.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1tag.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1tag.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1tag.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1tag.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v1/id3v1tag.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v1/id3v1tag.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/attachedpictureframe.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/attachedpictureframe.cpp old mode 100644 new mode 100755 similarity index 90% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/attachedpictureframe.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/attachedpictureframe.cpp index 945d7a61a..a1b4ab7c2 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/attachedpictureframe.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/attachedpictureframe.cpp @@ -126,29 +126,12 @@ void AttachedPictureFrame::parseFields(const ByteVector &data) return; } - int pos = 0; + d->textEncoding = String::Type(data[0]); - d->textEncoding = String::Type(data[pos]); - pos += 1; + int pos = 1; - int offset = data.find(textDelimiter(String::Latin1), pos); - - if(offset < pos) - return; - - d->mimeType = String(data.mid(pos, offset - pos), String::Latin1); - pos = offset + 1; - - d->type = Type(data[pos]); - pos += 1; - - offset = data.find(textDelimiter(d->textEncoding), pos); - - if(offset < pos) - return; - - d->description = String(data.mid(pos, offset - pos), d->textEncoding); - pos = offset + 1; + d->mimeType = readStringField(data, String::Latin1, &pos); + d->description = readStringField(data, d->textEncoding, &pos); d->data = data.mid(pos); } diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/attachedpictureframe.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/attachedpictureframe.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/attachedpictureframe.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/attachedpictureframe.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/commentsframe.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/commentsframe.cpp old mode 100644 new mode 100755 similarity index 98% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/commentsframe.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/commentsframe.cpp index 0b7faaa19..0dd571200 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/commentsframe.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/commentsframe.cpp @@ -113,7 +113,7 @@ CommentsFrame *CommentsFrame::findByDescription(const ID3v2::Tag *tag, const Str it != comments.end(); ++it) { - CommentsFrame *frame = dynamic_cast(*it); + CommentsFrame *frame = static_cast(*it); if(frame && frame->description() == d) return frame; } diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/commentsframe.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/commentsframe.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/commentsframe.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/commentsframe.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.cpp old mode 100644 new mode 100755 similarity index 85% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.cpp index e408bdbad..76586fd09 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.cpp @@ -134,36 +134,15 @@ void GeneralEncapsulatedObjectFrame::parseFields(const ByteVector &data) return; } - int fieldStart = 0; + d->textEncoding = String::Type(data[0]); - d->textEncoding = String::Type(data[fieldStart]); - fieldStart += 1; + int pos = 1; - int fieldEnd = data.find(textDelimiter(String::Latin1), fieldStart); + d->mimeType = readStringField(data, String::Latin1, &pos); + d->fileName = readStringField(data, d->textEncoding, &pos); + d->description = readStringField(data, d->textEncoding, &pos); - if(fieldEnd < fieldStart) - return; - - d->mimeType = String(data.mid(fieldStart, fieldEnd - fieldStart), String::Latin1); - fieldStart = fieldEnd + 1; - - fieldEnd = data.find(textDelimiter(d->textEncoding), fieldStart); - - if(fieldEnd < fieldStart) - return; - - d->fileName = String(data.mid(fieldStart, fieldEnd - fieldStart), d->textEncoding); - fieldStart = fieldEnd + 1; - - fieldEnd = data.find(textDelimiter(d->textEncoding), fieldStart); - - if(fieldEnd < fieldStart) - return; - - d->description = String(data.mid(fieldStart, fieldEnd - fieldStart), d->textEncoding); - fieldStart = fieldEnd + 1; - - d->data = data.mid(fieldStart); + d->data = data.mid(pos); } ByteVector GeneralEncapsulatedObjectFrame::renderFields() const diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/relativevolumeframe.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/relativevolumeframe.cpp old mode 100644 new mode 100755 similarity index 97% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/relativevolumeframe.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/relativevolumeframe.cpp index 78a34e96e..90fc6f334 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/relativevolumeframe.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/relativevolumeframe.cpp @@ -130,7 +130,7 @@ float RelativeVolumeFrame::volumeAdjustment() const void RelativeVolumeFrame::setVolumeAdjustment(float adjustment, ChannelType type) { - d->channels[type].volumeAdjustment = short(adjustment / float(512)); + d->channels[type].volumeAdjustment = short(adjustment * float(512)); } void RelativeVolumeFrame::setVolumeAdjustment(float adjustment) @@ -164,8 +164,10 @@ void RelativeVolumeFrame::setPeakVolume(const PeakVolume &peak) void RelativeVolumeFrame::parseFields(const ByteVector &data) { - uint pos = data.find(textDelimiter(String::Latin1)); + ByteVector delimiter = textDelimiter(String::Latin1); + uint pos = data.find(delimiter); d->identification = String(data.mid(0, pos), String::Latin1); + pos += delimiter.size(); // Each channel is at least 4 bytes. diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/relativevolumeframe.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/relativevolumeframe.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/relativevolumeframe.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/relativevolumeframe.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/textidentificationframe.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/textidentificationframe.cpp old mode 100644 new mode 100755 similarity index 97% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/textidentificationframe.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/textidentificationframe.cpp index 3f7c72181..a353fd729 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/textidentificationframe.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/textidentificationframe.cpp @@ -126,8 +126,10 @@ void TextIdentificationFrame::parseFields(const ByteVector &data) // type is the same specified for this frame for(ByteVectorList::Iterator it = l.begin(); it != l.end(); it++) { - String s(*it, d->textEncoding); - d->fieldList.append(s); + if(!(*it).isEmpty()) { + String s(*it, d->textEncoding); + d->fieldList.append(s); + } } } @@ -235,7 +237,7 @@ UserTextIdentificationFrame *UserTextIdentificationFrame::find( { FrameList l = tag->frameList("TXXX"); for(FrameList::Iterator it = l.begin(); it != l.end(); ++it) { - UserTextIdentificationFrame *f = dynamic_cast(*it); + UserTextIdentificationFrame *f = static_cast(*it); if(f && f->description() == description) return f; } diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/textidentificationframe.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/textidentificationframe.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/textidentificationframe.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/textidentificationframe.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/uniquefileidentifierframe.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/unknownframe.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/unknownframe.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/unknownframe.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/unknownframe.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/unknownframe.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/unknownframe.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/frames/unknownframe.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/frames/unknownframe.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2.4.0-frames.txt b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2.4.0-frames.txt old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2.4.0-frames.txt rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2.4.0-frames.txt diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2.4.0-structure.txt b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2.4.0-structure.txt old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2.4.0-structure.txt rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2.4.0-structure.txt diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2extendedheader.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2extendedheader.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2extendedheader.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2extendedheader.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2extendedheader.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2extendedheader.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2extendedheader.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2extendedheader.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2footer.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2footer.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2footer.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2footer.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2footer.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2footer.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2footer.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2footer.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2frame.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2frame.cpp old mode 100644 new mode 100755 similarity index 94% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2frame.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2frame.cpp index 1b1d62ece..3b9ff7f24 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2frame.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2frame.cpp @@ -184,6 +184,26 @@ ByteVector Frame::fieldData(const ByteVector &frameData) const return frameData.mid(frameDataOffset, frameDataLength); } +String Frame::readStringField(const ByteVector &data, String::Type encoding, int *position) +{ + int start = 0; + + if(!position) + position = &start; + + ByteVector delimiter = textDelimiter(encoding); + + int end = data.find(delimiter, *position, delimiter.size()); + + if(end < *position) + return String::null; + + *position = end + delimiter.size(); + + return String(data.mid(*position, end - *position), encoding); +} + + //////////////////////////////////////////////////////////////////////////////// // Frame::Header class //////////////////////////////////////////////////////////////////////////////// @@ -200,7 +220,7 @@ public: groupingIdentity(false), compression(false), encryption(false), - unsyncronisation(false), + unsynchronisation(false), dataLengthIndicator(false) {} @@ -216,7 +236,7 @@ public: bool groupingIdentity; bool compression; bool encryption; - bool unsyncronisation; + bool unsynchronisation; bool dataLengthIndicator; }; @@ -381,7 +401,7 @@ void Frame::Header::setData(const ByteVector &data, uint version) d->groupingIdentity = flags[6]; // (structure 4.1.2.h) d->compression = flags[3]; // (structure 4.1.2.k) d->encryption = flags[2]; // (structure 4.1.2.m) - d->unsyncronisation = flags[1]; // (structure 4.1.2.n) + d->unsynchronisation = flags[1]; // (structure 4.1.2.n) d->dataLengthIndicator = flags[0]; // (structure 4.1.2.p) } break; @@ -451,7 +471,12 @@ bool Frame::Header::encryption() const bool Frame::Header::unsycronisation() const { - return d->unsyncronisation; + return unsynchronisation(); +} + +bool Frame::Header::unsynchronisation() const +{ + return d->unsynchronisation; } bool Frame::Header::dataLengthIndicator() const diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2frame.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2frame.h old mode 100644 new mode 100755 similarity index 96% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2frame.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2frame.h index 38cecf589..d1ebf2042 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2frame.h +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2frame.h @@ -179,6 +179,15 @@ namespace TagLib { */ ByteVector fieldData(const ByteVector &frameData) const; + /*! + * Reads a String of type \a encodiong from the ByteVector \a data. If \a + * position is passed in it is used both as the starting point and is + * updated to replect the position just after the string that has been read. + * This is useful for reading strings sequentially. + */ + String readStringField(const ByteVector &data, String::Type encoding, + int *positon = 0); + private: Frame(const Frame &); Frame &operator=(const Frame &); @@ -353,12 +362,14 @@ namespace TagLib { */ bool encryption() const; +#ifndef DO_NOT_DOCUMENT + bool unsycronisation() const; +#endif + /*! * Returns true if unsyncronisation is enabled for this frame. - * - * \note This flag is currently ignored internally in TagLib. */ - bool unsycronisation() const; + bool unsynchronisation() const; /*! * Returns true if the flag for a data length indicator is set. diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2framefactory.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2framefactory.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2framefactory.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2framefactory.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2framefactory.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2framefactory.h old mode 100644 new mode 100755 similarity index 98% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2framefactory.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2framefactory.h index 81cac97e1..c83c358aa --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2framefactory.h +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2framefactory.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_ID3V2FRAMEFACTORY_H #define TAGLIB_ID3V2FRAMEFACTORY_H +#include "taglib_export.h" #include "tbytevector.h" #include "id3v2frame.h" @@ -50,7 +51,7 @@ namespace TagLib { * textbooks (Notably Design Patters). */ - class FrameFactory + class TAGLIB_EXPORT FrameFactory { public: static FrameFactory *instance(); diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2header.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2header.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2header.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2header.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2header.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2header.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2header.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2header.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2synchdata.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2synchdata.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2synchdata.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2synchdata.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2synchdata.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2synchdata.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2synchdata.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2synchdata.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2tag.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2tag.cpp old mode 100644 new mode 100755 similarity index 97% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2tag.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2tag.cpp index 333e5f60a..708229201 --- a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2tag.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2tag.cpp @@ -124,8 +124,7 @@ String ID3v2::Tag::genre() const // should be separated by " / " instead of " ". For the moment to keep // the behavior the same as released versions it is being left with " ". - if(d->frameListMap["TCON"].isEmpty() || - !dynamic_cast(d->frameListMap["TCON"].front())) + if(d->frameListMap["TCON"].isEmpty() || !(d->frameListMap["TCON"].front())) { return String::null; } @@ -219,12 +218,23 @@ void ID3v2::Tag::setGenre(const String &s) return; } + // iTunes can't handle correctly encoded ID3v2.4 numerical genres. Just use + // strings until iTunes sucks less. + +#ifdef NO_ITUNES_HACKS + int index = ID3v1::genreIndex(s); if(index != 255) setTextFrame("TCON", String::number(index)); else setTextFrame("TCON", s); + +#else + + setTextFrame("TCON", s); + +#endif } void ID3v2::Tag::setYear(uint i) diff --git a/Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2tag.h b/Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2tag.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/id3v2/id3v2tag.h rename to Frameworks/TagLib/taglib/taglib/mpeg/id3v2/id3v2tag.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/mpegfile.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/mpegfile.cpp old mode 100644 new mode 100755 similarity index 90% rename from Frameworks/TagLib/Files/taglib/mpeg/mpegfile.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/mpegfile.cpp index 9bfa64ece..e15c6c330 --- a/Frameworks/TagLib/Files/taglib/mpeg/mpegfile.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/mpegfile.cpp @@ -221,14 +221,19 @@ public: // public members //////////////////////////////////////////////////////////////////////////////// +MPEG::File::File(ID3v2::FrameFactory *frameFactory) : TagLib::File() +{ + if (frameFactory) + d = new FilePrivate(frameFactory); + else + d = new FilePrivate; +} + MPEG::File::File(const char *file, bool readProperties, Properties::ReadStyle propertiesStyle) : TagLib::File(file) { d = new FilePrivate; - if(isOpen()) { - d->tag = new MPEGTag(this); - read(readProperties, propertiesStyle); - } + read(readProperties, propertiesStyle); } MPEG::File::File(const char *file, ID3v2::FrameFactory *frameFactory, @@ -236,10 +241,7 @@ MPEG::File::File(const char *file, ID3v2::FrameFactory *frameFactory, TagLib::File(file) { d = new FilePrivate(frameFactory); - if(isOpen()) { - d->tag = new MPEGTag(this); - read(readProperties, propertiesStyle); - } + read(readProperties, propertiesStyle); } MPEG::File::~File() @@ -257,6 +259,59 @@ MPEG::Properties *MPEG::File::audioProperties() const return d->properties; } +void MPEG::File::read(bool readProperties, Properties::ReadStyle propertiesStyle) +{ + if (!isOpen()) + return; + + d->tag = new MPEGTag(this); + + // Look for an ID3v2 tag + + d->ID3v2Location = findID3v2(); + + if(d->ID3v2Location >= 0) { + + d->ID3v2Tag = new ID3v2::Tag(this, d->ID3v2Location, d->ID3v2FrameFactory); + + d->ID3v2OriginalSize = d->ID3v2Tag->header()->completeTagSize(); + + if(d->ID3v2Tag->header()->tagSize() <= 0) { + delete d->ID3v2Tag; + d->ID3v2Tag = 0; + } + else + d->hasID3v2 = true; + } + + // Look for an ID3v1 tag + + d->ID3v1Location = findID3v1(); + + if(d->ID3v1Location >= 0) { + d->ID3v1Tag = new ID3v1::Tag(this, d->ID3v1Location); + d->hasID3v1 = true; + } + + // Look for an APE tag + + d->APELocation = findAPE(); + + if(d->APELocation >= 0) { + + d->APETag = new APE::Tag(this, d->APELocation); + + d->APEOriginalSize = d->APETag->footer()->completeTagSize(); + + d->APELocation = d->APELocation + d->APETag->footer()->size() - d->APEOriginalSize; + + d->hasAPE = true; + } + + if(readProperties) + d->properties = new Properties(this, propertiesStyle); +} + bool MPEG::File::save() { return save(AllTags); @@ -304,6 +359,18 @@ bool MPEG::File::save(int tags, bool stripOthers) d->ID3v2Location = 0; insert(d->ID3v2Tag->render(), d->ID3v2Location, d->ID3v2OriginalSize); + + d->hasID3v2 = true; + + // v1 tag location has changed, update if it exists + + if(d->ID3v1Tag) + d->ID3v1Location = findID3v1(); + + // APE tag location has changed, update if it exists + + if(d->APETag) + d->APELocation = findAPE(); } else if(stripOthers) success = strip(ID3v2, false) && success; @@ -316,6 +383,8 @@ bool MPEG::File::save(int tags, bool stripOthers) int offset = d->hasID3v1 ? -128 : 0; seek(offset, End); writeBlock(d->ID3v1Tag->render()); + d->hasID3v1 = true; + d->ID3v1Location = findID3v1(); } else if(stripOthers) success = strip(ID3v1) && success; @@ -407,8 +476,14 @@ bool MPEG::File::strip(int tags, bool freeMemory) } // v1 tag location has changed, update if it exists + if(d->ID3v1Tag) d->ID3v1Location = findID3v1(); + + // APE tag location has changed, update if it exists + + if(d->APETag) + d->APELocation = findAPE(); } if((tags & ID3v1) && d->hasID3v1) { @@ -445,30 +520,42 @@ void MPEG::File::setID3v2FrameFactory(const ID3v2::FrameFactory *factory) long MPEG::File::nextFrameOffset(long position) { - // TODO: This will miss syncs spanning buffer read boundaries. + ByteVector buffer; + long endPosition; + long maxScanBytes = getMaxScanBytes(); - ByteVector buffer = readBlock(bufferSize()); - - while(buffer.size() > 0) { + if (maxScanBytes > 0) + endPosition = position + maxScanBytes; + else + endPosition = 0; + do { seek(position); buffer = readBlock(bufferSize()); - for(uint i = 0; i < buffer.size() - 1; i++) { + for(int i = 0; i < int(buffer.size()) - 1; i++) { if(uchar(buffer[i]) == 0xff && secondSynchByte(buffer[i + 1])) return position + i; } - position += bufferSize(); - } + position += bufferSize() - 1; + + if (endPosition && (position >= endPosition)) + break; + } while(buffer.size() > 0); return -1; } long MPEG::File::previousFrameOffset(long position) { - // TODO: This will miss syncs spanning buffer read boundaries. + long endPosition; + long maxScanBytes = getMaxScanBytes(); + if ((maxScanBytes > 0) && (position > maxScanBytes)) + endPosition = position - maxScanBytes; + else + endPosition = 0; while(int(position - bufferSize()) > int(bufferSize())) { - position -= bufferSize(); + position -= bufferSize() - 1; seek(position); ByteVector buffer = readBlock(bufferSize()); @@ -482,6 +569,9 @@ long MPEG::File::previousFrameOffset(long position) if(uchar(buffer[i]) == 0xff && secondSynchByte(buffer[i + 1])) return position + i; } + + if (endPosition && (position <= endPosition)) + break; } return -1; @@ -506,54 +596,6 @@ long MPEG::File::lastFrameOffset() // private members //////////////////////////////////////////////////////////////////////////////// -void MPEG::File::read(bool readProperties, Properties::ReadStyle propertiesStyle) -{ - // Look for an ID3v2 tag - - d->ID3v2Location = findID3v2(); - - if(d->ID3v2Location >= 0) { - - d->ID3v2Tag = new ID3v2::Tag(this, d->ID3v2Location, d->ID3v2FrameFactory); - - d->ID3v2OriginalSize = d->ID3v2Tag->header()->completeTagSize(); - - if(d->ID3v2Tag->header()->tagSize() <= 0) { - delete d->ID3v2Tag; - d->ID3v2Tag = 0; - } - else - d->hasID3v2 = true; - } - - // Look for an ID3v1 tag - - d->ID3v1Location = findID3v1(); - - if(d->ID3v1Location >= 0) { - d->ID3v1Tag = new ID3v1::Tag(this, d->ID3v1Location); - d->hasID3v1 = true; - } - - // Look for an APE tag - - d->APELocation = findAPE(); - - if(d->APELocation >= 0) { - - d->APETag = new APE::Tag(this, d->APELocation); - - d->APEOriginalSize = d->APETag->footer()->completeTagSize(); - - d->APELocation = d->APELocation + d->APETag->footer()->size() - d->APEOriginalSize; - - d->hasAPE = true; - } - - if(readProperties) - d->properties = new Properties(this, propertiesStyle); -} - long MPEG::File::findID3v2() { // This method is based on the contents of TagLib::File::find(), but because @@ -564,7 +606,9 @@ long MPEG::File::findID3v2() // The position in the file that the current buffer starts at. + long maxScanBytes = getMaxScanBytes(); long bufferOffset = 0; + long endBufferOffset; ByteVector buffer; // These variables are used to keep track of a partial match that happens at @@ -578,6 +622,13 @@ long MPEG::File::findID3v2() long originalPosition = tell(); + // Determine where to end search. + + if (maxScanBytes > 0) + endBufferOffset = bufferOffset + maxScanBytes; + else + endBufferOffset = 0; + // Start the search at the beginning of the file. seek(0); @@ -653,6 +704,9 @@ long MPEG::File::findID3v2() previousPartialMatch = buffer.endsWithPartialMatch(ID3v2::Header::fileIdentifier()); bufferOffset += bufferSize(); + + if (endBufferOffset && (bufferOffset >= endBufferOffset)) + break; } // Since we hit the end of the file, reset the status before continuing. diff --git a/Frameworks/TagLib/Files/taglib/mpeg/mpegfile.h b/Frameworks/TagLib/taglib/taglib/mpeg/mpegfile.h old mode 100644 new mode 100755 similarity index 94% rename from Frameworks/TagLib/Files/taglib/mpeg/mpegfile.h rename to Frameworks/TagLib/taglib/taglib/mpeg/mpegfile.h index f8c331478..7a0dedaac --- a/Frameworks/TagLib/Files/taglib/mpeg/mpegfile.h +++ b/Frameworks/TagLib/taglib/taglib/mpeg/mpegfile.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_MPEGFILE_H #define TAGLIB_MPEGFILE_H +#include "taglib_export.h" #include "tfile.h" #include "mpegproperties.h" @@ -44,7 +45,7 @@ namespace TagLib { * to the different ID3 tags. */ - class File : public TagLib::File + class TAGLIB_EXPORT File : public TagLib::File { public: /*! @@ -64,6 +65,12 @@ namespace TagLib { AllTags = 0xffff }; + /*! + * Contructs an MPEG file object without reading a file. Allows object + * fields to be set up before reading. + */ + File(ID3v2::FrameFactory *frameFactory = NULL); + /*! * Contructs an MPEG file from \a file. If \a readProperties is true the * file's audio properties will also be read using \a propertiesStyle. If @@ -116,6 +123,14 @@ namespace TagLib { */ virtual Properties *audioProperties() const; + /*! + * Reads from MPEG file. If \a readProperties is true the file's audio + * properties will also be read using \a propertiesStyle. If false, + * \a propertiesStyle is ignored. + */ + void read(bool readProperties = true, + Properties::ReadStyle propertiesStyle = Properties::Average); + /*! * Save the file. If at least one tag -- ID3v1 or ID3v2 -- exists this * will duplicate its content into the other tag. This returns true @@ -251,7 +266,6 @@ namespace TagLib { File(const File &); File &operator=(const File &); - void read(bool readProperties, Properties::ReadStyle propertiesStyle); long findID3v2(); long findID3v1(); long findAPE(); diff --git a/Frameworks/TagLib/Files/taglib/mpeg/mpegheader.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/mpegheader.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/mpegheader.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/mpegheader.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/mpegheader.h b/Frameworks/TagLib/taglib/taglib/mpeg/mpegheader.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/mpegheader.h rename to Frameworks/TagLib/taglib/taglib/mpeg/mpegheader.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/mpegproperties.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/mpegproperties.cpp old mode 100644 new mode 100755 similarity index 90% rename from Frameworks/TagLib/Files/taglib/mpeg/mpegproperties.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/mpegproperties.cpp index fb816f8d6..de02469c5 --- a/Frameworks/TagLib/Files/taglib/mpeg/mpegproperties.cpp +++ b/Frameworks/TagLib/taglib/taglib/mpeg/mpegproperties.cpp @@ -144,6 +144,8 @@ bool MPEG::Properties::isOriginal() const void MPEG::Properties::read() { + long maxScanBytes = d->file->getMaxScanBytes(); + // Since we've likely just looked for the ID3v1 tag, start at the end of the // file where we're least likely to have to have to move the disk head. @@ -158,6 +160,22 @@ void MPEG::Properties::read() Header lastHeader(d->file->readBlock(4)); long first = d->file->firstFrameOffset(); + long endFirst; + if (maxScanBytes > 0) + endFirst = first + maxScanBytes; + else + endFirst = 0; + while (first >= 0) + { + d->file->seek(first); + Header header(d->file->readBlock(4)); + if (header.isValid()) + break; + if (endFirst && (first >= endFirst)) + first = d->file->nextFrameOffset(first + 1); + else + first = -1; + } if(first < 0) { debug("MPEG::Properties::read() -- Could not find a valid first MPEG frame in the stream."); @@ -167,8 +185,15 @@ void MPEG::Properties::read() if(!lastHeader.isValid()) { long pos = last; + long endPos; - while(pos > first) { + if ((maxScanBytes > 0) && (last > maxScanBytes)) + endPos = last - maxScanBytes; + else + endPos = 0; + if (endPos < first) + endPos = first; + while(pos > endPos) { pos = d->file->previousFrameOffset(pos); @@ -213,7 +238,7 @@ void MPEG::Properties::read() { static const int blockSize[] = { 0, 384, 1152, 1152 }; - double timePerFrame = blockSize[firstHeader.layer()] / firstHeader.sampleRate(); + double timePerFrame = double(blockSize[firstHeader.layer()]) / firstHeader.sampleRate(); d->length = int(timePerFrame * d->xingHeader->totalFrames()); d->bitrate = d->length > 0 ? d->xingHeader->totalSize() * 8 / d->length / 1000 : 0; } diff --git a/Frameworks/TagLib/Files/taglib/mpeg/mpegproperties.h b/Frameworks/TagLib/taglib/taglib/mpeg/mpegproperties.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/mpegproperties.h rename to Frameworks/TagLib/taglib/taglib/mpeg/mpegproperties.h diff --git a/Frameworks/TagLib/Files/taglib/mpeg/xingheader.cpp b/Frameworks/TagLib/taglib/taglib/mpeg/xingheader.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/xingheader.cpp rename to Frameworks/TagLib/taglib/taglib/mpeg/xingheader.cpp diff --git a/Frameworks/TagLib/Files/taglib/mpeg/xingheader.h b/Frameworks/TagLib/taglib/taglib/mpeg/xingheader.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/mpeg/xingheader.h rename to Frameworks/TagLib/taglib/taglib/mpeg/xingheader.h diff --git a/Frameworks/TagLib/Files/taglib/ogg/flac/oggflacfile.cpp b/Frameworks/TagLib/taglib/taglib/ogg/flac/oggflacfile.cpp old mode 100644 new mode 100755 similarity index 99% rename from Frameworks/TagLib/Files/taglib/ogg/flac/oggflacfile.cpp rename to Frameworks/TagLib/taglib/taglib/ogg/flac/oggflacfile.cpp index 132bb80d9..23a93dd59 --- a/Frameworks/TagLib/Files/taglib/ogg/flac/oggflacfile.cpp +++ b/Frameworks/TagLib/taglib/taglib/ogg/flac/oggflacfile.cpp @@ -64,6 +64,11 @@ public: // public members //////////////////////////////////////////////////////////////////////////////// +Ogg::FLAC::File::File() : Ogg::File() +{ + d = new FilePrivate; +} + Ogg::FLAC::File::File(const char *file, bool readProperties, Properties::ReadStyle propertiesStyle) : Ogg::File(file) { @@ -87,36 +92,6 @@ Properties *Ogg::FLAC::File::audioProperties() const } -bool Ogg::FLAC::File::save() -{ - d->xiphCommentData = d->comment->render(); - - // Create FLAC metadata-block: - - // Put the size in the first 32 bit (I assume no more than 24 bit are used) - - ByteVector v = ByteVector::fromUInt(d->xiphCommentData.size()); - - // Set the type of the metadata-block to be a Xiph / Vorbis comment - - v[0] = 4; - - // Append the comment-data after the 32 bit header - - v.append(d->xiphCommentData); - - // Save the packet at the old spot - // FIXME: Use padding if size is increasing - - setPacket(d->commentPacket, v); - - return Ogg::File::save(); -} - -//////////////////////////////////////////////////////////////////////////////// -// private members -//////////////////////////////////////////////////////////////////////////////// - void Ogg::FLAC::File::read(bool readProperties, Properties::ReadStyle propertiesStyle) { // Sanity: Check if we really have an Ogg/FLAC file @@ -150,6 +125,36 @@ void Ogg::FLAC::File::read(bool readProperties, Properties::ReadStyle properties d->properties = new Properties(streamInfoData(), streamLength(), propertiesStyle); } +bool Ogg::FLAC::File::save() +{ + d->xiphCommentData = d->comment->render(); + + // Create FLAC metadata-block: + + // Put the size in the first 32 bit (I assume no more than 24 bit are used) + + ByteVector v = ByteVector::fromUInt(d->xiphCommentData.size()); + + // Set the type of the metadata-block to be a Xiph / Vorbis comment + + v[0] = 4; + + // Append the comment-data after the 32 bit header + + v.append(d->xiphCommentData); + + // Save the packet at the old spot + // FIXME: Use padding if size is increasing + + setPacket(d->commentPacket, v); + + return Ogg::File::save(); +} + +//////////////////////////////////////////////////////////////////////////////// +// private members +//////////////////////////////////////////////////////////////////////////////// + ByteVector Ogg::FLAC::File::streamInfoData() { scan(); diff --git a/Frameworks/TagLib/Files/taglib/ogg/flac/oggflacfile.h b/Frameworks/TagLib/taglib/taglib/ogg/flac/oggflacfile.h old mode 100644 new mode 100755 similarity index 86% rename from Frameworks/TagLib/Files/taglib/ogg/flac/oggflacfile.h rename to Frameworks/TagLib/taglib/taglib/ogg/flac/oggflacfile.h index f1a7452dc..d88b0feb3 --- a/Frameworks/TagLib/Files/taglib/ogg/flac/oggflacfile.h +++ b/Frameworks/TagLib/taglib/taglib/ogg/flac/oggflacfile.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_OGGFLACFILE_H #define TAGLIB_OGGFLACFILE_H +#include "taglib_export.h" #include "oggfile.h" #include "xiphcomment.h" @@ -55,9 +56,15 @@ namespace TagLib { * information specific to Ogg FLAC files. */ - class File : public Ogg::File + class TAGLIB_EXPORT File : public Ogg::File { public: + /*! + * Contructs an Ogg/FLAC file object without reading a file. Allows object + * fields to be set up before reading. + */ + File(); + /*! * Contructs an Ogg/FLAC file from \a file. If \a readProperties is true * the file's audio properties will also be read using \a propertiesStyle. @@ -82,6 +89,14 @@ namespace TagLib { */ virtual Properties *audioProperties() const; + /*! + * Reads from Ogg/FLAC file. If \a readProperties is true the file's + * audio properties will also be read using \a propertiesStyle. If false, + * \a propertiesStyle is ignored. + */ + void read(bool readProperties = true, + Properties::ReadStyle propertiesStyle = Properties::Average); + /*! * Save the file. This will primarily save and update the XiphComment. * Returns true if the save is successful. @@ -98,7 +113,6 @@ namespace TagLib { File(const File &); File &operator=(const File &); - void read(bool readProperties, Properties::ReadStyle propertiesStyle); void scan(); ByteVector streamInfoData(); ByteVector xiphCommentData(); diff --git a/Frameworks/TagLib/Files/taglib/ogg/oggfile.cpp b/Frameworks/TagLib/taglib/taglib/ogg/oggfile.cpp old mode 100644 new mode 100755 similarity index 99% rename from Frameworks/TagLib/Files/taglib/ogg/oggfile.cpp rename to Frameworks/TagLib/taglib/taglib/ogg/oggfile.cpp index 357a30edd..9d90be112 --- a/Frameworks/TagLib/Files/taglib/ogg/oggfile.cpp +++ b/Frameworks/TagLib/taglib/taglib/ogg/oggfile.cpp @@ -204,6 +204,11 @@ bool Ogg::File::save() // protected members //////////////////////////////////////////////////////////////////////////////// +Ogg::File::File() : TagLib::File() +{ + d = new FilePrivate; +} + Ogg::File::File(const char *file) : TagLib::File(file) { d = new FilePrivate; diff --git a/Frameworks/TagLib/Files/taglib/ogg/oggfile.h b/Frameworks/TagLib/taglib/taglib/ogg/oggfile.h old mode 100644 new mode 100755 similarity index 94% rename from Frameworks/TagLib/Files/taglib/ogg/oggfile.h rename to Frameworks/TagLib/taglib/taglib/ogg/oggfile.h index dc7d22484..692a85af4 --- a/Frameworks/TagLib/Files/taglib/ogg/oggfile.h +++ b/Frameworks/TagLib/taglib/taglib/ogg/oggfile.h @@ -19,6 +19,7 @@ * USA * ***************************************************************************/ +#include "taglib_export.h" #include "tfile.h" #include "tbytevectorlist.h" @@ -42,7 +43,7 @@ namespace TagLib { * these available (via subclassing) to the codec meta data implementations. */ - class File : public TagLib::File + class TAGLIB_EXPORT File : public TagLib::File { public: virtual ~File(); @@ -76,6 +77,12 @@ namespace TagLib { virtual bool save(); protected: + /*! + * Contructs an Ogg file object without reading a file. Allows object + * fields to be set up before reading. + */ + File(); + /*! * Contructs an Ogg file from \a file. If \a readProperties is true the * file's audio properties will also be read using \a propertiesStyle. If diff --git a/Frameworks/TagLib/Files/taglib/ogg/oggpage.cpp b/Frameworks/TagLib/taglib/taglib/ogg/oggpage.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/oggpage.cpp rename to Frameworks/TagLib/taglib/taglib/ogg/oggpage.cpp diff --git a/Frameworks/TagLib/Files/taglib/ogg/oggpage.h b/Frameworks/TagLib/taglib/taglib/ogg/oggpage.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/oggpage.h rename to Frameworks/TagLib/taglib/taglib/ogg/oggpage.h diff --git a/Frameworks/TagLib/Files/taglib/ogg/oggpageheader.cpp b/Frameworks/TagLib/taglib/taglib/ogg/oggpageheader.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/oggpageheader.cpp rename to Frameworks/TagLib/taglib/taglib/ogg/oggpageheader.cpp diff --git a/Frameworks/TagLib/Files/taglib/ogg/oggpageheader.h b/Frameworks/TagLib/taglib/taglib/ogg/oggpageheader.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/oggpageheader.h rename to Frameworks/TagLib/taglib/taglib/ogg/oggpageheader.h diff --git a/Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisfile.cpp b/Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisfile.cpp old mode 100644 new mode 100755 similarity index 94% rename from Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisfile.cpp rename to Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisfile.cpp index a6e8b94c9..654e92f0c --- a/Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisfile.cpp +++ b/Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisfile.cpp @@ -57,6 +57,11 @@ namespace TagLib { // public members //////////////////////////////////////////////////////////////////////////////// +Vorbis::File::File() : Ogg::File() +{ + d = new FilePrivate; +} + Vorbis::File::File(const char *file, bool readProperties, Properties::ReadStyle propertiesStyle) : Ogg::File(file) { @@ -79,23 +84,6 @@ Vorbis::Properties *Vorbis::File::audioProperties() const return d->properties; } -bool Vorbis::File::save() -{ - ByteVector v(vorbisCommentHeaderID); - - if(!d->comment) - d->comment = new Ogg::XiphComment; - v.append(d->comment->render()); - - setPacket(1, v); - - return Ogg::File::save(); -} - -//////////////////////////////////////////////////////////////////////////////// -// private members -//////////////////////////////////////////////////////////////////////////////// - void Vorbis::File::read(bool readProperties, Properties::ReadStyle propertiesStyle) { ByteVector commentHeaderData = packet(1); @@ -111,3 +99,17 @@ void Vorbis::File::read(bool readProperties, Properties::ReadStyle propertiesSty if(readProperties) d->properties = new Properties(this, propertiesStyle); } + +bool Vorbis::File::save() +{ + ByteVector v(vorbisCommentHeaderID); + + if(!d->comment) + d->comment = new Ogg::XiphComment; + v.append(d->comment->render()); + + setPacket(1, v); + + return Ogg::File::save(); +} + diff --git a/Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisfile.h b/Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisfile.h old mode 100644 new mode 100755 similarity index 86% rename from Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisfile.h rename to Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisfile.h index 967ae7669..2f344afde --- a/Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisfile.h +++ b/Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisfile.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_VORBISFILE_H #define TAGLIB_VORBISFILE_H +#include "taglib_export.h" #include "oggfile.h" #include "xiphcomment.h" @@ -54,9 +55,15 @@ namespace TagLib { * the codec implementations, in this case Vorbis specifically. */ - class File : public Ogg::File + class TAGLIB_EXPORT File : public Ogg::File { public: + /*! + * Contructs a Vorbis file object without reading a file. Allows object + * fields to be set up before reading. + */ + File(); + /*! * Contructs a Vorbis file from \a file. If \a readProperties is true the * file's audio properties will also be read using \a propertiesStyle. If @@ -83,14 +90,20 @@ namespace TagLib { */ virtual Properties *audioProperties() const; + /*! + * Reads from Vorbis file. If \a readProperties is true the file's audio + * properties will also be read using \a propertiesStyle. If false, + * \a propertiesStyle is ignored. + */ + void read(bool readProperties = true, + Properties::ReadStyle propertiesStyle = Properties::Average); + virtual bool save(); private: File(const File &); File &operator=(const File &); - void read(bool readProperties, Properties::ReadStyle propertiesStyle); - class FilePrivate; FilePrivate *d; }; diff --git a/Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisproperties.cpp b/Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisproperties.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisproperties.cpp rename to Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisproperties.cpp diff --git a/Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisproperties.h b/Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisproperties.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/vorbis/vorbisproperties.h rename to Frameworks/TagLib/taglib/taglib/ogg/vorbis/vorbisproperties.h diff --git a/Frameworks/TagLib/Files/taglib/ogg/xiphcomment.cpp b/Frameworks/TagLib/taglib/taglib/ogg/xiphcomment.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/xiphcomment.cpp rename to Frameworks/TagLib/taglib/taglib/ogg/xiphcomment.cpp diff --git a/Frameworks/TagLib/Files/taglib/ogg/xiphcomment.h b/Frameworks/TagLib/taglib/taglib/ogg/xiphcomment.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/ogg/xiphcomment.h rename to Frameworks/TagLib/taglib/taglib/ogg/xiphcomment.h diff --git a/Frameworks/TagLib/Files/taglib/tag.cpp b/Frameworks/TagLib/taglib/taglib/tag.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/tag.cpp rename to Frameworks/TagLib/taglib/taglib/tag.cpp diff --git a/Frameworks/TagLib/Files/taglib/tag.h b/Frameworks/TagLib/taglib/taglib/tag.h old mode 100644 new mode 100755 similarity index 99% rename from Frameworks/TagLib/Files/taglib/tag.h rename to Frameworks/TagLib/taglib/taglib/tag.h index 46999a9ad..a46694187 --- a/Frameworks/TagLib/Files/taglib/tag.h +++ b/Frameworks/TagLib/taglib/taglib/tag.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_TAG_H #define TAGLIB_TAG_H +#include "taglib_export.h" #include "tstring.h" namespace TagLib { @@ -36,7 +37,7 @@ namespace TagLib { * in TagLib::AudioProperties, TagLib::File and TagLib::FileRef. */ - class Tag + class TAGLIB_EXPORT Tag { public: diff --git a/Frameworks/TagLib/taglib/taglib/taglib_export.h b/Frameworks/TagLib/taglib/taglib/taglib_export.h new file mode 100755 index 000000000..d53703585 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/taglib_export.h @@ -0,0 +1,33 @@ +/* + Copyright (c) 2006 Volker Krause + + This library is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published by + the Free Software Foundation; either version 2 of the License, or (at your + option) any later version. + + This library is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public + License for more details. + + You should have received a copy of the GNU Library General Public License + along with this library; see the file COPYING.LIB. If not, write to the + Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + 02110-1301, USA. +*/ + +#ifndef TAGLIB_EXPORT_H +#define TAGLIB_EXPORT_H + +#if defined(_WIN32) || defined(_WIN64) +#ifdef MAKE_TAGLIB_LIB +#define TAGLIB_EXPORT __declspec(dllexport) +#else +#define TAGLIB_EXPORT __declspec(dllimport) +#endif +#else +#define TAGLIB_EXPORT +#endif + +#endif diff --git a/Frameworks/TagLib/Files/taglib/toolkit/taglib.h b/Frameworks/TagLib/taglib/taglib/toolkit/taglib.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/taglib.h rename to Frameworks/TagLib/taglib/taglib/toolkit/taglib.h diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tbytevector.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/tbytevector.cpp old mode 100644 new mode 100755 similarity index 99% rename from Frameworks/TagLib/Files/taglib/toolkit/tbytevector.cpp rename to Frameworks/TagLib/taglib/taglib/toolkit/tbytevector.cpp index 363b76856..26dd18cbb --- a/Frameworks/TagLib/Files/taglib/toolkit/tbytevector.cpp +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tbytevector.cpp @@ -100,7 +100,7 @@ namespace TagLib { if(pattern.size() == 1) { char p = pattern[0]; for(uint i = offset; i < v.size(); i++) { - if(v[i] == p && i % byteAlign == 0) + if(v[i] == p && (i - offset) % byteAlign == 0) return i; } return -1; @@ -123,7 +123,7 @@ namespace TagLib { --iPattern; } - if(-1 == iPattern && (iBuffer + 1) % byteAlign == 0) + if(-1 == iPattern && (iBuffer + 1 - offset) % byteAlign == 0) return iBuffer + 1; } diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tbytevector.h b/Frameworks/TagLib/taglib/taglib/toolkit/tbytevector.h old mode 100644 new mode 100755 similarity index 98% rename from Frameworks/TagLib/Files/taglib/toolkit/tbytevector.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tbytevector.h index 5dbab36b5..462b0d1d0 --- a/Frameworks/TagLib/Files/taglib/toolkit/tbytevector.h +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tbytevector.h @@ -124,8 +124,8 @@ namespace TagLib { /*! * Searches the ByteVector for \a pattern starting at \a offset and returns * the offset. Returns -1 if the pattern was not found. If \a byteAlign is - * specified the pattern will only be matched if it starts on a byteDivisible - * by \a byteAlign. + * specified the pattern will only be matched if it starts on a byte divisible + * by \a byteAlign (starting from \a offset). */ int find(const ByteVector &pattern, uint offset = 0, int byteAlign = 1) const; @@ -133,7 +133,7 @@ namespace TagLib { * Searches the ByteVector for \a pattern starting from either the end of the * vector or \a offset and returns the offset. Returns -1 if the pattern was * not found. If \a byteAlign is specified the pattern will only be matched - * if it starts on a byteDivisible by \a byteAlign. + * if it starts on a byte divisible by \a byteAlign (starting from \a offset). */ int rfind(const ByteVector &pattern, uint offset = 0, int byteAlign = 1) const; diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tbytevectorlist.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/tbytevectorlist.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tbytevectorlist.cpp rename to Frameworks/TagLib/taglib/taglib/toolkit/tbytevectorlist.cpp diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tbytevectorlist.h b/Frameworks/TagLib/taglib/taglib/toolkit/tbytevectorlist.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tbytevectorlist.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tbytevectorlist.h diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tdebug.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/tdebug.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tdebug.cpp rename to Frameworks/TagLib/taglib/taglib/toolkit/tdebug.cpp diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tdebug.h b/Frameworks/TagLib/taglib/taglib/toolkit/tdebug.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tdebug.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tdebug.h diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tfile.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/tfile.cpp old mode 100644 new mode 100755 similarity index 58% rename from Frameworks/TagLib/Files/taglib/toolkit/tfile.cpp rename to Frameworks/TagLib/taglib/taglib/toolkit/tfile.cpp index 58533fe06..9bfe01dac --- a/Frameworks/TagLib/Files/taglib/toolkit/tfile.cpp +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tfile.cpp @@ -20,26 +20,13 @@ ***************************************************************************/ #include "tfile.h" +#include "tlist.h" +#include "tlocalfileio.h" #include "tstring.h" #include "tdebug.h" #include -#include #include -#ifdef _WIN32 -# include -# define ftruncate _chsize -#else - #include -#endif -#include - -#ifndef R_OK -# define R_OK 4 -#endif -#ifndef W_OK -# define W_OK 2 -#endif using namespace TagLib; @@ -47,9 +34,9 @@ class File::FilePrivate { public: FilePrivate(const char *fileName) : - file(0), + fileIO(NULL), name(fileName), - readOnly(true), + maxScanBytes(0), valid(true), size(0) {} @@ -59,88 +46,112 @@ public: free((void *)name); } - FILE *file; + FileIO *fileIO; const char *name; - bool readOnly; + long maxScanBytes; bool valid; ulong size; static const uint bufferSize = 1024; + static List fileIOTypeResolvers; }; +List File::FilePrivate::fileIOTypeResolvers; + //////////////////////////////////////////////////////////////////////////////// // public members //////////////////////////////////////////////////////////////////////////////// +File::File() +{ + d = new FilePrivate(NULL); +} + File::File(const char *file) { - d = new FilePrivate(::strdup(file)); - - // First try with read/write mode, if that fails, fall back to read only. - // We can't use ::access() since that works in odd ways on some file systems. - - d->file = fopen(file, "rb+"); - - if(d->file) - d->readOnly = false; - else - d->file = fopen(file,"rb"); - - if(!d->file) - debug("Could not open file " + String(file)); + d = new FilePrivate(NULL); + open(file); } File::~File() { - if(d->file) - fclose(d->file); + if(d->fileIO) + delete d->fileIO; delete d; } +void File::open(const char *file) +{ +#ifdef _MSC_VER + d->name = _strdup(file); +#else + d->name = ::strdup(file); +#endif + + List::ConstIterator it = FilePrivate::fileIOTypeResolvers.begin(); + + for(; it != FilePrivate::fileIOTypeResolvers.end(); ++it) { + FileIO *fileIO = (*it)->createFileIO(file); + if(fileIO) { + d->fileIO = fileIO; + break; + } + } + + if (!d->fileIO) + d->fileIO = new LocalFileIO(file); + + if (d->fileIO && !d->fileIO->isOpen()) { + delete d->fileIO; + d->fileIO = NULL; + } + + if(!d->fileIO) + debug("Could not open file " + String(file)); +} + const char *File::name() const { return d->name; } +long File::getMaxScanBytes() +{ + return d->maxScanBytes; +} + +void File::setMaxScanBytes(long maxScanBytes) +{ + d->maxScanBytes = maxScanBytes; +} + ByteVector File::readBlock(ulong length) { - if(!d->file) { + if(!d->fileIO) { debug("File::readBlock() -- Invalid File"); return ByteVector::null; } - if(length > FilePrivate::bufferSize && - length > ulong(File::length())) - { - length = File::length(); - } - - ByteVector v(static_cast(length)); - const int count = fread(v.data(), sizeof(char), length, d->file); - v.resize(count); - return v; + return d->fileIO->readBlock(length); } void File::writeBlock(const ByteVector &data) { - if(!d->file) + if(!d->fileIO) return; - if(d->readOnly) { - debug("File::writeBlock() -- attempted to write to a file that is not writable"); - return; - } - - fwrite(data.data(), sizeof(char), data.size(), d->file); + d->fileIO->writeBlock(data); } long File::find(const ByteVector &pattern, long fromOffset, const ByteVector &before) { - if(!d->file || pattern.size() > d->bufferSize) + if(!d->fileIO || pattern.size() > d->bufferSize) return -1; // The position in the file that the current buffer starts at. + long maxScanBytes = d->maxScanBytes; long bufferOffset = fromOffset; + long endBufferOffset; ByteVector buffer; // These variables are used to keep track of a partial match that happens at @@ -154,6 +165,13 @@ long File::find(const ByteVector &pattern, long fromOffset, const ByteVector &be long originalPosition = tell(); + // Determine where to end search. + + if (maxScanBytes > 0) + endBufferOffset = bufferOffset + maxScanBytes; + else + endBufferOffset = 0; + // Start the search at the offset. seek(fromOffset); @@ -217,6 +235,9 @@ long File::find(const ByteVector &pattern, long fromOffset, const ByteVector &be beforePreviousPartialMatch = buffer.endsWithPartialMatch(before); bufferOffset += d->bufferSize; + + if (endBufferOffset && (bufferOffset >= endBufferOffset)) + break; } // Since we hit the end of the file, reset the status before continuing. @@ -231,7 +252,7 @@ long File::find(const ByteVector &pattern, long fromOffset, const ByteVector &be long File::rfind(const ByteVector &pattern, long fromOffset, const ByteVector &before) { - if(!d->file || pattern.size() > d->bufferSize) + if(!d->fileIO || pattern.size() > d->bufferSize) return -1; // The position in the file that the current buffer starts at. @@ -253,7 +274,9 @@ long File::rfind(const ByteVector &pattern, long fromOffset, const ByteVector &b // Start the search at the offset. + long maxScanBytes = d->maxScanBytes; long bufferOffset; + long endBufferOffset; if(fromOffset == 0) { seek(-1 * int(d->bufferSize), End); bufferOffset = tell(); @@ -263,6 +286,13 @@ long File::rfind(const ByteVector &pattern, long fromOffset, const ByteVector &b bufferOffset = tell(); } + // Determine where to end search. + + if ((maxScanBytes > 0) && (bufferOffset > maxScanBytes)) + endBufferOffset = bufferOffset - maxScanBytes; + else + endBufferOffset = 0; + // See the notes in find() for an explanation of this algorithm. for(buffer = readBlock(d->bufferSize); buffer.size() > 0; buffer = readBlock(d->bufferSize)) { @@ -286,6 +316,9 @@ long File::rfind(const ByteVector &pattern, long fromOffset, const ByteVector &b bufferOffset -= d->bufferSize; seek(bufferOffset); + + if (endBufferOffset && (bufferOffset <= endBufferOffset)) + break; } // Since we hit the end of the file, reset the status before continuing. @@ -299,142 +332,40 @@ long File::rfind(const ByteVector &pattern, long fromOffset, const ByteVector &b void File::insert(const ByteVector &data, ulong start, ulong replace) { - if(!d->file) + if(!d->fileIO) return; - if(data.size() == replace) { - seek(start); - writeBlock(data); - return; - } - else if(data.size() < replace) { - seek(start); - writeBlock(data); - removeBlock(start + data.size(), replace - data.size()); - return; - } - - // Woohoo! Faster (about 20%) than id3lib at last. I had to get hardcore - // and avoid TagLib's high level API for rendering just copying parts of - // the file that don't contain tag data. - // - // Now I'll explain the steps in this ugliness: - - // First, make sure that we're working with a buffer that is longer than - // the *differnce* in the tag sizes. We want to avoid overwriting parts - // that aren't yet in memory, so this is necessary. - - ulong bufferLength = bufferSize(); - while(data.size() - replace > bufferLength) - bufferLength += bufferSize(); - - // Set where to start the reading and writing. - - long readPosition = start + replace; - long writePosition = start; - - ByteVector buffer; - ByteVector aboutToOverwrite(static_cast(bufferLength)); - - // This is basically a special case of the loop below. Here we're just - // doing the same steps as below, but since we aren't using the same buffer - // size -- instead we're using the tag size -- this has to be handled as a - // special case. We're also using File::writeBlock() just for the tag. - // That's a bit slower than using char *'s so, we're only doing it here. - - seek(readPosition); - int bytesRead = fread(aboutToOverwrite.data(), sizeof(char), bufferLength, d->file); - readPosition += bufferLength; - - seek(writePosition); - writeBlock(data); - writePosition += data.size(); - - buffer = aboutToOverwrite; - - // Ok, here's the main loop. We want to loop until the read fails, which - // means that we hit the end of the file. - - while(bytesRead != 0) { - - // Seek to the current read position and read the data that we're about - // to overwrite. Appropriately increment the readPosition. - - seek(readPosition); - bytesRead = fread(aboutToOverwrite.data(), sizeof(char), bufferLength, d->file); - aboutToOverwrite.resize(bytesRead); - readPosition += bufferLength; - - // Check to see if we just read the last block. We need to call clear() - // if we did so that the last write succeeds. - - if(ulong(bytesRead) < bufferLength) - clear(); - - // Seek to the write position and write our buffer. Increment the - // writePosition. - - seek(writePosition); - fwrite(buffer.data(), sizeof(char), bufferLength, d->file); - writePosition += bufferLength; - - // Make the current buffer the data that we read in the beginning. - - buffer = aboutToOverwrite; - - // Again, we need this for the last write. We don't want to write garbage - // at the end of our file, so we need to set the buffer size to the amount - // that we actually read. - - bufferLength = bytesRead; - } + d->fileIO->insert(data, start, replace); } void File::removeBlock(ulong start, ulong length) { - if(!d->file) + if(!d->fileIO) return; - ulong bufferLength = bufferSize(); - - long readPosition = start + length; - long writePosition = start; - - ByteVector buffer(static_cast(bufferLength)); - - ulong bytesRead = 1; - - while(bytesRead != 0) { - seek(readPosition); - bytesRead = fread(buffer.data(), sizeof(char), bufferLength, d->file); - readPosition += bytesRead; - - // Check to see if we just read the last block. We need to call clear() - // if we did so that the last write succeeds. - - if(bytesRead < bufferLength) - clear(); - - seek(writePosition); - fwrite(buffer.data(), sizeof(char), bytesRead, d->file); - writePosition += bytesRead; - } - truncate(writePosition); + d->fileIO->removeBlock(start, length); } bool File::readOnly() const { - return d->readOnly; + if(!d->fileIO) + return true; + + return d->fileIO->readOnly(); } bool File::isReadable(const char *file) { - return access(file, R_OK) == 0; +/*zzz need to implement. */ + return true; } bool File::isOpen() const { - return (d->file != NULL); + if(!d->fileIO) + return false; + + return d->fileIO->isOpen(); } bool File::isValid() const @@ -442,60 +373,59 @@ bool File::isValid() const return isOpen() && d->valid; } -void File::seek(long offset, Position p) +int File::seek(long offset, Position p) { - if(!d->file) { + if(!d->fileIO) { debug("File::seek() -- trying to seek in a file that isn't opened."); - return; + return -1; } - switch(p) { - case Beginning: - fseek(d->file, offset, SEEK_SET); - break; - case Current: - fseek(d->file, offset, SEEK_CUR); - break; - case End: - fseek(d->file, offset, SEEK_END); - break; - } + return d->fileIO->seek(offset, p); } void File::clear() { - clearerr(d->file); + if(!d->fileIO) + return; + + d->fileIO->clear(); } long File::tell() const { - return ftell(d->file); + if(!d->fileIO) + return -1; + + return d->fileIO->tell(); } long File::length() { - // Do some caching in case we do multiple calls. - - if(d->size > 0) - return d->size; - - if(!d->file) + if(!d->fileIO) return 0; - long curpos = tell(); - - seek(0, End); - long endpos = tell(); - - seek(curpos, Beginning); - - d->size = endpos; - return endpos; + return d->fileIO->length(); } bool File::isWritable(const char *file) { - return access(file, W_OK) == 0; +/*zzz need to implement. */ + return false; +} + +const File::FileIOTypeResolver *File::addFileIOTypeResolver(const File::FileIOTypeResolver *resolver) // static +{ + FilePrivate::fileIOTypeResolvers.prepend(resolver); + return resolver; +} + +void File::removeFileIOTypeResolver(const File::FileIOTypeResolver *resolver) // static +{ + List::Iterator it; + + it = FilePrivate::fileIOTypeResolvers.find(resolver); + if (it != FilePrivate::fileIOTypeResolvers.end()) + FilePrivate::fileIOTypeResolvers.erase(it); } //////////////////////////////////////////////////////////////////////////////// @@ -509,7 +439,10 @@ void File::setValid(bool valid) void File::truncate(long length) { - ftruncate(fileno(d->file), length); + if(!d->fileIO) + return; + + d->fileIO->truncate(length); } TagLib::uint File::bufferSize() diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tfile.h b/Frameworks/TagLib/taglib/taglib/toolkit/tfile.h old mode 100644 new mode 100755 similarity index 72% rename from Frameworks/TagLib/Files/taglib/toolkit/tfile.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tfile.h index 02c87816f..4de6344bc --- a/Frameworks/TagLib/Files/taglib/toolkit/tfile.h +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tfile.h @@ -22,8 +22,10 @@ #ifndef TAGLIB_FILE_H #define TAGLIB_FILE_H +#include "taglib_export.h" #include "taglib.h" #include "tbytevector.h" +#include "tfileio.h" namespace TagLib { @@ -39,19 +41,51 @@ namespace TagLib { * ByteVector and a binary search method for finding patterns in a file. */ - class File + class TAGLIB_EXPORT File : public TagLib::FileIO { public: - /*! - * Position in the file used for seeking. - */ - enum Position { - //! Seek from the beginning of the file. - Beginning, - //! Seek from the current position in the file. - Current, - //! Seek from the end of the file. - End + + //! A class for pluggable file I/O type resolution. + + /*! + * This class is used to extend TagLib's very basic file name based file I/O + * type resolution. + * + * This can be accomplished with: + * + * \code + * + * class MyFileIOTypeResolver : FileIOTypeResolver + * { + * TagLib::FileIO *createFileIO(const char *fileName) + * { + * if(someCheckForAnHTTPFile(fileName)) + * return new MyHTTPFileIO(fileName); + * return 0; + * } + * } + * + * File::addFileIOTypeResolver(new MyFileIOTypeResolver); + * + * \endcode + * + * Naturally a less contrived example would be slightly more complex. This + * can be used to add new file I/O types to TagLib. + */ + + class FileIOTypeResolver + { + public: + /*! + * This method must be overriden to provide an additional file I/O type + * resolver. If the resolver is able to determine the file I/O type it + * should return a valid File I/O object; if not it should return 0. + * + * \note The created file I/O is then owned by the File and should not be + * deleted. Deletion will happen automatically when the File passes out + * of scope. + */ + virtual FileIO *createFileIO(const char *fileName) const = 0; }; /*! @@ -59,11 +93,32 @@ namespace TagLib { */ virtual ~File(); + /*! + * Opens the \a file. \a file should be a be a C-string in the local file + * system encoding. + * + * \note Constructor is protected since this class should only be + * instantiated through subclasses. + */ + void open(const char *file); + /*! * Returns the file name in the local file system encoding. */ const char *name() const; + /*! + * Returns the maximum number of bytes to scan when scanning for frames or + * tags. + */ + long getMaxScanBytes(); + + /*! + * Sets the maximum number of bytes to scan when scanning for frames or + * tags to \a maxScanBytes. + */ + void setMaxScanBytes(long maxScanBytes); + /*! * Returns a pointer to this file's tag. This should be reimplemented in * the concrete subclasses. @@ -178,7 +233,7 @@ namespace TagLib { * * \see Position */ - void seek(long offset, Position p = Beginning); + int seek(long offset, Position p = Beginning); /*! * Reset the end-of-file and error flags on the file. @@ -210,7 +265,35 @@ namespace TagLib { */ static bool isWritable(const char *name); + /*! + * Adds \a resolver to the list of FileIOTypeResolvers used by TagLib. Each + * additional FileIOTypeResolver is added to the front of a list of + * resolvers that are tried. If the FileIOTypeResolver returns zero the + * next resolver is tried. + * + * Returns a pointer to the added resolver (the same one that's passed in -- + * this is mostly so that static inialializers have something to use for + * assignment). + * + * \see FileIOTypeResolver + */ + static const FileIOTypeResolver *addFileIOTypeResolver(const FileIOTypeResolver *resolver); + + /*! + * Removes \a resolver from the list of FileIOTypeResolvers used by TagLib. + */ + static void removeFileIOTypeResolver(const FileIOTypeResolver *resolver); + protected: + /*! + * Construct a File object without opening a file. Allows object fields to + * be set up before opening file. + * + * \note Constructor is protected since this class should only be + * instantiated through subclasses. + */ + File(); + /*! * Construct a File object and opens the \a file. \a file should be a * be a C-string in the local file system encoding. diff --git a/Frameworks/TagLib/taglib/taglib/toolkit/tfileio.h b/Frameworks/TagLib/taglib/taglib/toolkit/tfileio.h new file mode 100755 index 000000000..c6d4b1b78 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tfileio.h @@ -0,0 +1,144 @@ +/*************************************************************************** + copyright : (C) 2002, 2003 by Scott Wheeler + email : wheeler@kde.org + ***************************************************************************/ + +/*************************************************************************** + * This library is free software; you can redistribute it and/or modify * + * it under the terms of the GNU Lesser General Public License version * + * 2.1 as published by the Free Software Foundation. * + * * + * This library is distributed in the hope that it will be useful, but * + * WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * Lesser General Public License for more details. * + * * + * You should have received a copy of the GNU Lesser General Public * + * License along with this library; if not, write to the Free Software * + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * + * USA * + ***************************************************************************/ + +#ifndef TAGLIB_FILEIO_H +#define TAGLIB_FILEIO_H + +#include "taglib.h" +#include "tbytevector.h" + +namespace TagLib { + + //! A file I/O class supporting local files + + /*! + * This class is a basic file I/O interface class providing support for + * accessing files. + */ + + class FileIO + { + public: + /*! + * Position in the file used for seeking. + */ + enum Position { + //! Seek from the beginning of the file. + Beginning, + //! Seek from the current position in the file. + Current, + //! Seek from the end of the file. + End + }; + + /*! + * Destroys this FileIO instance. + */ + virtual ~FileIO() {} + + /*! + * Returns the file name in the local file system encoding. + */ + virtual const char *name() const = 0; + + /*! + * Reads a block of size \a length at the current get pointer. + */ + virtual ByteVector readBlock(ulong length) = 0; + + /*! + * Attempts to write the block \a data at the current get pointer. If the + * file is currently only opened read only -- i.e. readOnly() returns true -- + * this attempts to reopen the file in read/write mode. + * + * \note This should be used instead of using the streaming output operator + * for a ByteVector. And even this function is significantly slower than + * doing output with a char[]. + */ + virtual void writeBlock(const ByteVector &data) = 0; + + /*! + * Insert \a data at position \a start in the file overwriting \a replace + * bytes of the original content. + * + * \note This method is slow since it requires rewriting all of the file + * after the insertion point. + */ + virtual void insert(const ByteVector &data, ulong start = 0, ulong replace = 0) = 0; + + /*! + * Removes a block of the file starting a \a start and continuing for + * \a length bytes. + * + * \note This method is slow since it involves rewriting all of the file + * after the removed portion. + */ + virtual void removeBlock(ulong start = 0, ulong length = 0) = 0; + + /*! + * Returns true if the file is read only (or if the file can not be opened). + */ + virtual bool readOnly() const = 0; + + /*! + * Since the file can currently only be opened as an argument to the + * constructor (sort-of by design), this returns if that open succeeded. + */ + virtual bool isOpen() const = 0; + + /*! + * Move the I/O pointer to \a offset in the file from position \a p. This + * defaults to seeking from the beginning of the file. + * + * \see Position + */ + virtual int seek(long offset, Position p = Beginning) = 0; + + /*! + * Reset the end-of-file and error flags on the file. + */ + virtual void clear() = 0; + + /*! + * Returns the current offset withing the file. + */ + virtual long tell() const = 0; + + /*! + * Returns the length of the file. + */ + virtual long length() = 0; + +protected: + /*! + * Truncates the file to a \a length. + */ + virtual void truncate(long length) = 0; + + /* + * The File class manages objects of type FileIO. + */ + friend class File; + }; + +} + +#endif diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tlist.h b/Frameworks/TagLib/taglib/taglib/toolkit/tlist.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tlist.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tlist.h diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tlist.tcc b/Frameworks/TagLib/taglib/taglib/toolkit/tlist.tcc old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tlist.tcc rename to Frameworks/TagLib/taglib/taglib/toolkit/tlist.tcc diff --git a/Frameworks/TagLib/taglib/taglib/toolkit/tlocalfileio.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/tlocalfileio.cpp new file mode 100755 index 000000000..fe90ff80a --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tlocalfileio.cpp @@ -0,0 +1,398 @@ +/*************************************************************************** + copyright : (C) 2002, 2003 by Scott Wheeler + email : wheeler@kde.org + ***************************************************************************/ + +/*************************************************************************** + * This library is free software; you can redistribute it and/or modify * + * it under the terms of the GNU Lesser General Public License version * + * 2.1 as published by the Free Software Foundation. * + * * + * This library is distributed in the hope that it will be useful, but * + * WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * Lesser General Public License for more details. * + * * + * You should have received a copy of the GNU Lesser General Public * + * License along with this library; if not, write to the Free Software * + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * + * USA * + ***************************************************************************/ + +#include "tlocalfileio.h" +#include "tstring.h" +#include "tdebug.h" + +#include +#include +#include + +#ifdef _WIN32 +# include +# define ftruncate _chsize +#else + #include +#endif + +#ifndef R_OK +# define R_OK 4 +#endif +#ifndef W_OK +# define W_OK 2 +#endif + +using namespace TagLib; + +class LocalFileIO::LocalFileIOPrivate +{ +public: + LocalFileIOPrivate(const char *fileName) : + file(0), + name(fileName), + readOnly(true), + valid(true), + size(0) + {} + + ~LocalFileIOPrivate() + { + free((void *)name); + } + + FILE *file; + const char *name; + bool readOnly; + bool valid; + ulong size; + static const uint bufferSize = 1024; +}; + +//////////////////////////////////////////////////////////////////////////////// +// public members +//////////////////////////////////////////////////////////////////////////////// + +LocalFileIO::LocalFileIO(const char *file) +{ +#ifdef _MSC_VER + d = new LocalFileIOPrivate(_strdup(file)); +#else + d = new LocalFileIOPrivate(::strdup(file)); +#endif + + d->readOnly = !isWritable(file); + d->file = fopen(file, d->readOnly ? "rb" : "rb+"); + + // On Mac, fopen for write can sometimes still fail even if isWritable is + // true (e.g., when file is on an SMB share). + if (!d->file && !d->readOnly && (errno == EACCES)) { + d->readOnly = true; + d->file = fopen(file, d->readOnly ? "rb" : "rb+"); + } + + if(!d->file) + debug("Could not open file " + String(file)); +} + +LocalFileIO::~LocalFileIO() +{ + if(d->file) + fclose(d->file); + delete d; +} + +const char *LocalFileIO::name() const +{ + return d->name; +} + +ByteVector LocalFileIO::readBlock(ulong length) +{ + if(!d->file) { + debug("LocalFileIO::readBlock() -- Invalid File"); + return ByteVector::null; + } + + if(length > LocalFileIOPrivate::bufferSize && + length > ulong(LocalFileIO::length())) + { + length = LocalFileIO::length(); + } + + ByteVector v(static_cast(length)); + const int count = fread(v.data(), sizeof(char), length, d->file); + v.resize(count); + return v; +} + +void LocalFileIO::writeBlock(const ByteVector &data) +{ + if(!d->file) + return; + + if(d->readOnly) { + debug("LocalFileIO::writeBlock() -- attempted to write to a file that is not writable"); + return; + } + + fwrite(data.data(), sizeof(char), data.size(), d->file); +} + +void LocalFileIO::insert(const ByteVector &data, ulong start, ulong replace) +{ + if(!d->file) + return; + + if(data.size() == replace) { + seek(start); + writeBlock(data); + return; + } + else if(data.size() < replace) { + seek(start); + writeBlock(data); + removeBlock(start + data.size(), replace - data.size()); + return; + } + + // Woohoo! Faster (about 20%) than id3lib at last. I had to get hardcore + // and avoid TagLib's high level API for rendering just copying parts of + // the file that don't contain tag data. + // + // Now I'll explain the steps in this ugliness: + + // First, make sure that we're working with a buffer that is longer than + // the *differnce* in the tag sizes. We want to avoid overwriting parts + // that aren't yet in memory, so this is necessary. + + ulong bufferLength = bufferSize(); + + while(data.size() - replace > bufferLength) + bufferLength += bufferSize(); + + // Set where to start the reading and writing. + + long readPosition = start + replace; + long writePosition = start; + + ByteVector buffer; + ByteVector aboutToOverwrite(static_cast(bufferLength)); + + // This is basically a special case of the loop below. Here we're just + // doing the same steps as below, but since we aren't using the same buffer + // size -- instead we're using the tag size -- this has to be handled as a + // special case. We're also using LocalFileIO::writeBlock() just for the tag. + // That's a bit slower than using char *'s so, we're only doing it here. + + seek(readPosition); + int bytesRead = fread(aboutToOverwrite.data(), sizeof(char), bufferLength, d->file); + readPosition += bufferLength; + + seek(writePosition); + writeBlock(data); + writePosition += data.size(); + + buffer = aboutToOverwrite; + + // In case we've already reached the end of file... + + buffer.resize(bytesRead); + + // Ok, here's the main loop. We want to loop until the read fails, which + // means that we hit the end of the file. + + while(!buffer.isEmpty()) { + + // Seek to the current read position and read the data that we're about + // to overwrite. Appropriately increment the readPosition. + + seek(readPosition); + bytesRead = fread(aboutToOverwrite.data(), sizeof(char), bufferLength, d->file); + aboutToOverwrite.resize(bytesRead); + readPosition += bufferLength; + + // Check to see if we just read the last block. We need to call clear() + // if we did so that the last write succeeds. + + if(ulong(bytesRead) < bufferLength) + clear(); + + // Seek to the write position and write our buffer. Increment the + // writePosition. + + seek(writePosition); + fwrite(buffer.data(), sizeof(char), buffer.size(), d->file); + writePosition += buffer.size(); + + // Make the current buffer the data that we read in the beginning. + + buffer = aboutToOverwrite; + + // Again, we need this for the last write. We don't want to write garbage + // at the end of our file, so we need to set the buffer size to the amount + // that we actually read. + + bufferLength = bytesRead; + } +} + +void LocalFileIO::removeBlock(ulong start, ulong length) +{ + if(!d->file) + return; + + ulong bufferLength = bufferSize(); + + long readPosition = start + length; + long writePosition = start; + + ByteVector buffer(static_cast(bufferLength)); + + ulong bytesRead = 1; + + while(bytesRead != 0) { + seek(readPosition); + bytesRead = fread(buffer.data(), sizeof(char), bufferLength, d->file); + readPosition += bytesRead; + + // Check to see if we just read the last block. We need to call clear() + // if we did so that the last write succeeds. + + if(bytesRead < bufferLength) + clear(); + + seek(writePosition); + fwrite(buffer.data(), sizeof(char), bytesRead, d->file); + writePosition += bytesRead; + } + truncate(writePosition); +} + +bool LocalFileIO::readOnly() const +{ + return d->readOnly; +} + +bool LocalFileIO::isReadable(const char *file) +{ +#ifdef _MSC_VER + return _access(file, R_OK) == 0; +#else + return access(file, R_OK) == 0; +#endif +} + +bool LocalFileIO::isOpen() const +{ + return (d->file != NULL); +} + +int LocalFileIO::seek(long offset, Position p) +{ + if(!d->file) { + debug("LocalFileIO::seek() -- trying to seek in a file that isn't opened."); + return -1; + } + + switch(p) { + case Beginning: + fseek(d->file, offset, SEEK_SET); + break; + case Current: + fseek(d->file, offset, SEEK_CUR); + break; + case End: + fseek(d->file, offset, SEEK_END); + break; + } + + return 0; +} + +void LocalFileIO::clear() +{ + clearerr(d->file); +} + +long LocalFileIO::tell() const +{ + return ftell(d->file); +} + +long LocalFileIO::length() +{ + // Do some caching in case we do multiple calls. + + if(d->size > 0) + return d->size; + + if(!d->file) + return 0; + + long curpos = tell(); + + seek(0, End); + long endpos = tell(); + + seek(curpos, Beginning); + + d->size = endpos; + return endpos; +} + +bool LocalFileIO::isWritable(const char *file) +{ +#ifdef _MSC_VER + return _access(file, W_OK) == 0; +#else + return access(file, W_OK) == 0; +#endif +} + +//////////////////////////////////////////////////////////////////////////////// +// protected members +//////////////////////////////////////////////////////////////////////////////// + +void LocalFileIO::truncate(long length) +{ +#ifdef _MSC_VER + _chsize(_fileno(d->file), length); +#else + ftruncate(fileno(d->file), length); +#endif +} + +TagLib::uint LocalFileIO::bufferSize() +{ + return LocalFileIOPrivate::bufferSize; +} + + +/******************************************************************************* + ******************************************************************************* + * + * Compatibility services. + *zzz should move to another file. + ******************************************************************************* + ******************************************************************************/ + +extern "C" +{ + +/* + * __stack_chk_fail + * + * This function is a stub for the glibc 2.4 __stack_chk_fail function. This + * function is referenced by non-shared functions within glibc 2.4 (e.g., stat, + * fstat, etc.) that are linked at compiled time. This function is provided by + * the glibc shared library version 2.4 but not 2.3 or earlier. This stub is + * provided for compatibility with systems providing versions of the glib shared + * library earlier than 2.4. + */ + +void __stack_chk_fail(void) +{ +} + +} /* extern "C" */ + + diff --git a/Frameworks/TagLib/taglib/taglib/toolkit/tlocalfileio.h b/Frameworks/TagLib/taglib/taglib/toolkit/tlocalfileio.h new file mode 100755 index 000000000..203eae239 --- /dev/null +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tlocalfileio.h @@ -0,0 +1,158 @@ +/*************************************************************************** + copyright : (C) 2002, 2003 by Scott Wheeler + email : wheeler@kde.org + ***************************************************************************/ + +/*************************************************************************** + * This library is free software; you can redistribute it and/or modify * + * it under the terms of the GNU Lesser General Public License version * + * 2.1 as published by the Free Software Foundation. * + * * + * This library is distributed in the hope that it will be useful, but * + * WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * Lesser General Public License for more details. * + * * + * You should have received a copy of the GNU Lesser General Public * + * License along with this library; if not, write to the Free Software * + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * + * USA * + ***************************************************************************/ + +#ifndef TAGLIB_LOCALFILE_H +#define TAGLIB_LOCALFILE_H + +#include "taglib.h" +#include "tbytevector.h" +#include "tfileio.h" + +namespace TagLib { + + //! A file I/O class supporting local files + + /*! + * This class is a basic file I/O class providing support for accessing local + * files. + */ + + class LocalFileIO : public TagLib::FileIO + { + public: + + /*! + * Construct a File I/O object and opens the \a file. \a file should be a + * be a C-string in the local file system encoding. + */ + LocalFileIO(const char *file); + + /*! + * Destroys this File instance. + */ + virtual ~LocalFileIO(); + + /*! + * Returns the file name in the local file system encoding. + */ + virtual const char *name() const; + + /*! + * Reads a block of size \a length at the current get pointer. + */ + virtual ByteVector readBlock(ulong length); + + /*! + * Attempts to write the block \a data at the current get pointer. If the + * file is currently only opened read only -- i.e. readOnly() returns true -- + * this attempts to reopen the file in read/write mode. + * + * \note This should be used instead of using the streaming output operator + * for a ByteVector. And even this function is significantly slower than + * doing output with a char[]. + */ + virtual void writeBlock(const ByteVector &data); + + /*! + * Insert \a data at position \a start in the file overwriting \a replace + * bytes of the original content. + * + * \note This method is slow since it requires rewriting all of the file + * after the insertion point. + */ + virtual void insert(const ByteVector &data, ulong start = 0, ulong replace = 0); + + /*! + * Removes a block of the file starting a \a start and continuing for + * \a length bytes. + * + * \note This method is slow since it involves rewriting all of the file + * after the removed portion. + */ + virtual void removeBlock(ulong start = 0, ulong length = 0); + + /*! + * Returns true if the file is read only (or if the file can not be opened). + */ + virtual bool readOnly() const; + + /*! + * Since the file can currently only be opened as an argument to the + * constructor (sort-of by design), this returns if that open succeeded. + */ + virtual bool isOpen() const; + + /*! + * Move the I/O pointer to \a offset in the file from position \a p. This + * defaults to seeking from the beginning of the file. + * + * \see Position + */ + virtual int seek(long offset, Position p = Beginning); + + /*! + * Reset the end-of-file and error flags on the file. + */ + virtual void clear(); + + /*! + * Returns the current offset withing the file. + */ + virtual long tell() const; + + /*! + * Returns the length of the file. + */ + virtual long length(); + + /*! + * Returns true if \a file can be opened for reading. If the file does not + * exist, this will return false. + */ + static bool isReadable(const char *file); + + /*! + * Returns true if \a file can be opened for writing. + */ + static bool isWritable(const char *name); + + protected: + /*! + * Truncates the file to a \a length. + */ + virtual void truncate(long length); + + /*! + * Returns the buffer size that is used for internal buffering. + */ + static uint bufferSize(); + + private: + LocalFileIO(const LocalFileIO &); + LocalFileIO &operator=(const LocalFileIO &); + + class LocalFileIOPrivate; + LocalFileIOPrivate *d; + }; + +} + +#endif diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tmap.h b/Frameworks/TagLib/taglib/taglib/toolkit/tmap.h old mode 100644 new mode 100755 similarity index 88% rename from Frameworks/TagLib/Files/taglib/toolkit/tmap.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tmap.h index 620c2983c..ae13d0217 --- a/Frameworks/TagLib/Files/taglib/toolkit/tmap.h +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tmap.h @@ -22,9 +22,10 @@ #ifndef TAGLIB_MAP_H #define TAGLIB_MAP_H -#include "taglib.h" - #include +using namespace std; + +#include "taglib.h" namespace TagLib { @@ -40,8 +41,21 @@ namespace TagLib { { public: #ifndef DO_NOT_DOCUMENT +#ifdef WANT_CLASS_INSTANTIATION_OF_MAP + // Some STL implementations get snippy over the use of the + // class keyword to distinguish different templates; Sun Studio + // in particular finds multiple specializations in certain rare + // cases and complains about that. GCC doesn't seem to mind, + // and uses the typedefs further below without the class keyword. + // Not all the specializations of Map can use the class keyword + // (when T is not actually a class type), so don't apply this + // generally. + typedef typename std::map::iterator Iterator; + typedef typename std::map::const_iterator ConstIterator; +#else typedef typename std::map::iterator Iterator; typedef typename std::map::const_iterator ConstIterator; +#endif #endif /*! diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tmap.tcc b/Frameworks/TagLib/taglib/taglib/toolkit/tmap.tcc old mode 100644 new mode 100755 similarity index 93% rename from Frameworks/TagLib/Files/taglib/toolkit/tmap.tcc rename to Frameworks/TagLib/taglib/taglib/toolkit/tmap.tcc index b01517ec1..b7ed7b3a3 --- a/Frameworks/TagLib/Files/taglib/toolkit/tmap.tcc +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tmap.tcc @@ -26,13 +26,18 @@ namespace TagLib { //////////////////////////////////////////////////////////////////////////////// template -template class Map::MapPrivate : public RefCounter +template +class Map::MapPrivate : public RefCounter { public: MapPrivate() : RefCounter() {} - MapPrivate(const std::map &m) : RefCounter(), map(m) {} - +#ifdef WANT_CLASS_INSTANTIATION_OF_MAP + MapPrivate(const std::map& m) : RefCounter(), map(m) {} + std::map map; +#else + MapPrivate(const std::map& m) : RefCounter(), map(m) {} std::map map; +#endif }; template diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tstring.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/tstring.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tstring.cpp rename to Frameworks/TagLib/taglib/taglib/toolkit/tstring.cpp diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tstring.h b/Frameworks/TagLib/taglib/taglib/toolkit/tstring.h old mode 100644 new mode 100755 similarity index 99% rename from Frameworks/TagLib/Files/taglib/toolkit/tstring.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tstring.h index 5bd8a9a02..70e82b1a6 --- a/Frameworks/TagLib/Files/taglib/toolkit/tstring.h +++ b/Frameworks/TagLib/taglib/taglib/toolkit/tstring.h @@ -22,6 +22,7 @@ #ifndef TAGLIB_STRING_H #define TAGLIB_STRING_H +#include "taglib_export.h" #include "taglib.h" #include "tbytevector.h" @@ -60,7 +61,7 @@ namespace TagLib { * possible encodings, which are the four supported by the ID3v2 standard. */ - class String + class TAGLIB_EXPORT String { public: diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tstringlist.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/tstringlist.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tstringlist.cpp rename to Frameworks/TagLib/taglib/taglib/toolkit/tstringlist.cpp diff --git a/Frameworks/TagLib/Files/taglib/toolkit/tstringlist.h b/Frameworks/TagLib/taglib/taglib/toolkit/tstringlist.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/tstringlist.h rename to Frameworks/TagLib/taglib/taglib/toolkit/tstringlist.h diff --git a/Frameworks/TagLib/Files/taglib/toolkit/unicode.cpp b/Frameworks/TagLib/taglib/taglib/toolkit/unicode.cpp old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/unicode.cpp rename to Frameworks/TagLib/taglib/taglib/toolkit/unicode.cpp diff --git a/Frameworks/TagLib/Files/taglib/toolkit/unicode.h b/Frameworks/TagLib/taglib/taglib/toolkit/unicode.h old mode 100644 new mode 100755 similarity index 100% rename from Frameworks/TagLib/Files/taglib/toolkit/unicode.h rename to Frameworks/TagLib/taglib/taglib/toolkit/unicode.h