From taglib-devel Wed Jan 17 19:51:46 2007 From: "Xavier Duret" Date: Wed, 17 Jan 2007 19:51:46 +0000 To: taglib-devel Subject: [PATCH] Add support for CBR Xing headers Message-Id: X-MARC-Message: https://marc.info/?l=taglib-devel&m=116906352431980 This patch adds support for "Info" headers. This type of header is used in CBR files. It contains the number of frames in the file which allows calculating the song duration more accurately than by using other techniques. diff -ruN taglib.old/taglib/mpeg/xingheader.cpp taglib/taglib/mpeg/xingheader.cpp --- taglib.old/taglib/mpeg/xingheader.cpp 2007-01-17 16:01:31.000000000 +0100 +++ taglib/taglib/mpeg/xingheader.cpp 2007-01-17 19:25:56.000000000 +0100 @@ -88,7 +88,7 @@ { // Check to see if a valid Xing header is available. - if(!data.startsWith("Xing")) + if(!data.startsWith("Xing") && !data.startsWith("Info")) return; // If the XingHeader doesn't contain the number of frames and the total stream _______________________________________________ taglib-devel mailing list taglib-devel@kde.org https://mail.kde.org/mailman/listinfo/taglib-devel