id3lib-devel Mailing List for id3lib
Brought to you by:
t1mpy
You can subscribe to this list here.
2000 |
Jan
|
Feb
(6) |
Mar
(4) |
Apr
(86) |
May
(81) |
Jun
(53) |
Jul
(30) |
Aug
(14) |
Sep
(16) |
Oct
(14) |
Nov
(9) |
Dec
(17) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(6) |
Feb
(41) |
Mar
(26) |
Apr
(10) |
May
(6) |
Jun
(17) |
Jul
(22) |
Aug
(51) |
Sep
(19) |
Oct
(19) |
Nov
(36) |
Dec
(83) |
2002 |
Jan
(31) |
Feb
(40) |
Mar
(45) |
Apr
(22) |
May
(6) |
Jun
(20) |
Jul
(58) |
Aug
(66) |
Sep
(54) |
Oct
(42) |
Nov
(49) |
Dec
(37) |
2003 |
Jan
(38) |
Feb
(36) |
Mar
(51) |
Apr
(41) |
May
(37) |
Jun
(41) |
Jul
(41) |
Aug
(31) |
Sep
(17) |
Oct
(33) |
Nov
(2) |
Dec
(23) |
2004 |
Jan
(27) |
Feb
(18) |
Mar
(24) |
Apr
(11) |
May
(16) |
Jun
(13) |
Jul
(20) |
Aug
(17) |
Sep
(3) |
Oct
(9) |
Nov
(2) |
Dec
(15) |
2005 |
Jan
(11) |
Feb
(15) |
Mar
(4) |
Apr
(4) |
May
(1) |
Jun
(6) |
Jul
|
Aug
(6) |
Sep
(2) |
Oct
(26) |
Nov
(5) |
Dec
(2) |
2006 |
Jan
(4) |
Feb
(3) |
Mar
(1) |
Apr
(3) |
May
|
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
(3) |
Nov
(6) |
Dec
(3) |
2007 |
Jan
(5) |
Feb
|
Mar
(7) |
Apr
(1) |
May
(12) |
Jun
(3) |
Jul
(1) |
Aug
(4) |
Sep
|
Oct
|
Nov
(7) |
Dec
|
2008 |
Jan
(3) |
Feb
|
Mar
(2) |
Apr
(2) |
May
(3) |
Jun
(2) |
Jul
(3) |
Aug
|
Sep
(1) |
Oct
(4) |
Nov
|
Dec
|
2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(8) |
2010 |
Jan
|
Feb
|
Mar
(2) |
Apr
(1) |
May
(3) |
Jun
(1) |
Jul
|
Aug
(4) |
Sep
|
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
(2) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2013 |
Jan
|
Feb
(2) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(7) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
2022 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
From: Đoàn T. C. D. <con...@gm...> - 2022-09-15 15:52:30
|
Hello, id3lib is failed to be built with C99 due to conflict types for bool. C99 defines bool as a typedef for _Bool in stdbool.h, which could be included transitively via stdlib.h. We can fix the build by guarding the typedef with #ifdef __bool_true_false_are_defined However, that would not be ideal, and some buggy C99 version doesn't define that macro, either. That raises another issue, id3lib's bool is a typedef of int, which is typically 4 or 8 bytes in major architecture. However, C99 and C++ bool is typically 1 byte. Hence, the current code is already broken for C++ because struct Mp3_Headerinfo has different layout for C and C++ (in C++, privatebit, copyrighted, and original are squeezed into 1 word, but in old C, it's in 3 different words). It's also broken if id3lib was built with C99 (with patch for typedef) and its dependants with old C, and vice versus. In addition, passing bool as parameter and return bool are also broken in big-endian C++, and C99. The only way the keep id3lib buildable and not break ABI is changing all C facing interface bool to int. Here is a patch to do that. --- --- a/include/id3.h +++ b/include/id3.h @@ -47,12 +47,12 @@ extern "C" ID3_C_EXPORT ID3Tag* CCONV ID3Tag_New (void); ID3_C_EXPORT void CCONV ID3Tag_Delete (ID3Tag *tag); ID3_C_EXPORT void CCONV ID3Tag_Clear (ID3Tag *tag); - ID3_C_EXPORT bool CCONV ID3Tag_HasChanged (const ID3Tag *tag); - ID3_C_EXPORT void CCONV ID3Tag_SetUnsync (ID3Tag *tag, bool unsync); - ID3_C_EXPORT void CCONV ID3Tag_SetExtendedHeader (ID3Tag *tag, bool ext); - ID3_C_EXPORT void CCONV ID3Tag_SetPadding (ID3Tag *tag, bool pad); + ID3_C_EXPORT ID3_Bool CCONV ID3Tag_HasChanged (const ID3Tag *tag); + ID3_C_EXPORT void CCONV ID3Tag_SetUnsync (ID3Tag *tag, ID3_Bool unsync); + ID3_C_EXPORT void CCONV ID3Tag_SetExtendedHeader (ID3Tag *tag, ID3_Bool ext); + ID3_C_EXPORT void CCONV ID3Tag_SetPadding (ID3Tag *tag, ID3_Bool pad); ID3_C_EXPORT void CCONV ID3Tag_AddFrame (ID3Tag *tag, const ID3Frame *frame); - ID3_C_EXPORT bool CCONV ID3Tag_AttachFrame (ID3Tag *tag, ID3Frame *frame); + ID3_C_EXPORT ID3_Bool CCONV ID3Tag_AttachFrame (ID3Tag *tag, ID3Frame *frame); ID3_C_EXPORT void CCONV ID3Tag_AddFrames (ID3Tag *tag, const ID3Frame *frames, size_t num); ID3_C_EXPORT ID3Frame* CCONV ID3Tag_RemoveFrame (ID3Tag *tag, const ID3Frame *frame); ID3_C_EXPORT ID3_Err CCONV ID3Tag_Parse (ID3Tag *tag, const uchar header[ID3_TAGHEADERSIZE], const uchar *buffer); @@ -66,7 +66,7 @@ extern "C" ID3_C_EXPORT ID3Frame* CCONV ID3Tag_FindFrameWithASCII (const ID3Tag *tag, ID3_FrameID id, ID3_FieldID fld, const char *data); ID3_C_EXPORT ID3Frame* CCONV ID3Tag_FindFrameWithUNICODE (const ID3Tag *tag, ID3_FrameID id, ID3_FieldID fld, const unicode_t *data); ID3_C_EXPORT size_t CCONV ID3Tag_NumFrames (const ID3Tag *tag); - ID3_C_EXPORT bool CCONV ID3Tag_HasTagType (const ID3Tag *tag, ID3_TagType); + ID3_C_EXPORT ID3_Bool CCONV ID3Tag_HasTagType (const ID3Tag *tag, ID3_TagType); ID3_C_EXPORT ID3TagIterator* CCONV ID3Tag_CreateIterator (ID3Tag *tag); ID3_C_EXPORT ID3TagConstIterator* CCONV ID3Tag_CreateConstIterator (const ID3Tag *tag); @@ -83,8 +83,8 @@ extern "C" ID3_C_EXPORT void CCONV ID3Frame_SetID (ID3Frame *frame, ID3_FrameID id); ID3_C_EXPORT ID3_FrameID CCONV ID3Frame_GetID (const ID3Frame *frame); ID3_C_EXPORT ID3Field* CCONV ID3Frame_GetField (const ID3Frame *frame, ID3_FieldID name); - ID3_C_EXPORT void CCONV ID3Frame_SetCompression (ID3Frame *frame, bool comp); - ID3_C_EXPORT bool CCONV ID3Frame_GetCompression (const ID3Frame *frame); + ID3_C_EXPORT void CCONV ID3Frame_SetCompression (ID3Frame *frame, ID3_Bool comp); + ID3_C_EXPORT ID3_Bool CCONV ID3Frame_GetCompression (const ID3Frame *frame); /* field wrappers */ ID3_C_EXPORT void CCONV ID3Field_Clear (ID3Field *field); @@ -116,7 +116,7 @@ extern "C" ID3_C_EXPORT flags_t CCONV ID3FrameInfo_FieldFlags (ID3_FrameID frameid, int fieldnum); /* Deprecated */ - ID3_C_EXPORT void CCONV ID3Tag_SetCompression (ID3Tag *tag, bool comp); + ID3_C_EXPORT void CCONV ID3Tag_SetCompression (ID3Tag *tag, ID3_Bool comp); #ifdef __cplusplus } --- a/include/id3/globals.h +++ b/include/id3/globals.h @@ -82,14 +82,10 @@ #define ID3_C_VAR extern -#ifndef __cplusplus - -typedef int bool; -# define false (0) -# define true (!false) - -#endif /* __cplusplus */ +typedef int ID3_Bool; +# define ID3_False 0 +# define ID3_True 1 ID3_C_VAR const char * const ID3LIB_NAME; ID3_C_VAR const char * const ID3LIB_RELEASE; ID3_C_VAR const char * const ID3LIB_FULL_NAME; @@ -532,9 +530,9 @@ ID3_STRUCT(Mp3_Headerinfo) uint32 framesize; uint32 frames; // nr of frames uint32 time; // nr of seconds in song - bool privatebit; - bool copyrighted; - bool original; + ID3_Bool privatebit; + ID3_Bool copyrighted; + ID3_Bool original; }; #define ID3_NR_OF_V1_GENRES 148 --- a/src/c_wrapper.cpp +++ b/src/c_wrapper.cpp @@ -72,10 +72,10 @@ extern "C" } - ID3_C_EXPORT bool CCONV + ID3_C_EXPORT ID3_Bool CCONV ID3Tag_HasChanged(const ID3Tag *tag) { - bool changed = false; + ID3_Bool changed = ID3_False; if (tag) { @@ -87,7 +87,7 @@ extern "C" ID3_C_EXPORT void CCONV - ID3Tag_SetUnsync(ID3Tag *tag, bool unsync) + ID3Tag_SetUnsync(ID3Tag *tag, ID3_Bool unsync) { if (tag) { @@ -97,7 +97,7 @@ extern "C" ID3_C_EXPORT void CCONV - ID3Tag_SetExtendedHeader(ID3Tag *tag, bool ext) + ID3Tag_SetExtendedHeader(ID3Tag *tag, ID3_Bool ext) { if (tag) { @@ -106,7 +106,7 @@ extern "C" } ID3_C_EXPORT void CCONV - ID3Tag_SetPadding(ID3Tag *tag, bool pad) + ID3Tag_SetPadding(ID3Tag *tag, ID3_Bool pad) { if (tag) { @@ -125,10 +125,10 @@ extern "C" } - ID3_C_EXPORT bool CCONV + ID3_C_EXPORT ID3_Bool CCONV ID3Tag_AttachFrame(ID3Tag *tag, ID3Frame *frame) { - bool b = false; + ID3_Bool b = ID3_False; if (tag) { ID3_CATCH(b = reinterpret_cast<ID3_Tag *>(tag)->AttachFrame(reinterpret_cast<ID3_Frame *>(frame))); @@ -303,10 +303,10 @@ extern "C" } - ID3_C_EXPORT bool CCONV + ID3_C_EXPORT ID3_Bool CCONV ID3Tag_HasTagType(const ID3Tag *tag, ID3_TagType tt) { - bool has_tt = false; + ID3_Bool has_tt = ID3_False; if (tag) { @@ -459,7 +459,7 @@ extern "C" ID3_C_EXPORT void CCONV - ID3Frame_SetCompression(ID3Frame *frame, bool comp) + ID3Frame_SetCompression(ID3Frame *frame, ID3_Bool comp) { if (frame) { @@ -468,10 +468,10 @@ extern "C" } - ID3_C_EXPORT bool CCONV + ID3_C_EXPORT ID3_Bool CCONV ID3Frame_GetCompression(const ID3Frame *frame) { - bool compressed = false; + ID3_Bool compressed = ID3_False; if (frame) { ID3_CATCH(compressed = reinterpret_cast<const ID3_Frame *>(frame)->GetCompression()); -- Danh |
From: John P. <pfu...@po...> - 2020-11-01 13:06:53
|
I'm trying to build from id3lib-3.8.3.tar.gz on Ubuntu and am hitting an error running the configure script: ...checking for iostream... yeschecking iomanip usability... yeschecking iomanip presence... yeschecking for iomanip... yeschecking vector usability... yeschecking vector presence... yeschecking for vector... yeschecking string usability... yeschecking string presence... yeschecking for string... yeschecking iomanip.h usability... nochecking iomanip.h presence... nochecking for iomanip.h... noconfigure: error: Missing a vital header file for id3lib$ I've see old posts about this and suggested changes but I don't understand how to apply the solutions. I'm especially confused because the configure script appears to detect iomanip correctly but does not find iomanip.h. Can anyone help? Where do I get iomanip.h? Should iomanip be sufficient? |
From: T K. <th...@xs...> - 2017-06-24 06:11:50
|
Indeed. I didn’t know about tag lib, i’ll contact Scott and see if we can merge them. Scott was also instrumental in the development of id3lib back in the past. I might just hand over the domain to him.. > On 22 Jun 2017, at 10:53, jon bird <ne...@on...> wrote: > > Id3lib is pretty ancient and I don't think is being maintained anymore. Checkout taglib instead I switched to that years ago. > > > On 22 June 2017 06:02:50 BST, GARIMA SINGH <hgn...@gm...> wrote: >> what are the steps to build this id3lib library ? please,if someone >> could >> provide the steps urgently ? >> >> thanks. >> >> >> On Mon, Jun 19, 2017 at 7:10 PM, GARIMA SINGH <hgn...@gm...> >> wrote: >> >>> can anyone tell the procedure to include this library in my code step >> by >>> step? It is always saying unrecognized directory >>> >> ------------------------------------------------------------------------------ >> Check out the vibrant tech community on one of the world's most >> engaging tech sites, Slashdot.org! http://sdm.link/slashdot >> _______________________________________________ >> id3lib-devel mailing list >> id3...@li... >> https://lists.sourceforge.net/lists/listinfo/id3lib-devel > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > id3lib-devel mailing list > id3...@li... > https://lists.sourceforge.net/lists/listinfo/id3lib-devel |
From: jon b. <ne...@on...> - 2017-06-22 09:20:06
|
Id3lib is pretty ancient and I don't think is being maintained anymore. Checkout taglib instead I switched to that years ago. On 22 June 2017 06:02:50 BST, GARIMA SINGH <hgn...@gm...> wrote: >what are the steps to build this id3lib library ? please,if someone >could >provide the steps urgently ? > >thanks. > > >On Mon, Jun 19, 2017 at 7:10 PM, GARIMA SINGH <hgn...@gm...> >wrote: > >> can anyone tell the procedure to include this library in my code step >by >> step? It is always saying unrecognized directory >> >------------------------------------------------------------------------------ >Check out the vibrant tech community on one of the world's most >engaging tech sites, Slashdot.org! http://sdm.link/slashdot >_______________________________________________ >id3lib-devel mailing list >id3...@li... >https://lists.sourceforge.net/lists/listinfo/id3lib-devel |
From: GARIMA S. <hgn...@gm...> - 2017-06-22 05:03:37
|
what are the steps to build this id3lib library ? please,if someone could provide the steps urgently ? thanks. On Mon, Jun 19, 2017 at 7:10 PM, GARIMA SINGH <hgn...@gm...> wrote: > can anyone tell the procedure to include this library in my code step by > step? It is always saying unrecognized directory > |
From: GARIMA S. <hgn...@gm...> - 2017-06-19 13:45:19
|
how to include it in my compiler's path? On Mon, Jun 19, 2017 at 7:10 PM, GARIMA SINGH <hgn...@gm...> wrote: > can anyone tell the procedure to include this library in my code step by > step? It is always saying unrecognized directory > ------------------------------------------------------------ > ------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > id3lib-devel mailing list > id3...@li... > https://lists.sourceforge.net/lists/listinfo/id3lib-devel > |
From: GARIMA S. <hgn...@gm...> - 2017-06-19 13:41:12
|
can anyone tell the procedure to include this library in my code step by step? It is always saying unrecognized directory |
From: GARIMA S. <hgn...@gm...> - 2017-06-11 16:03:08
|
Hi all, Is there any way to change the encoding format of a particular id3 frame only like from ISO to UTF ? |
From: GARIMA S. <hgn...@gm...> - 2017-06-11 16:02:17
|
Hi all, Is there any way to seek through a particular number of id3 frames and know the position ? |
From: Jeremy G. <jer...@gm...> - 2013-12-01 23:09:18
|
Hi all, I finally noticed my little tagging program doesn't handle Unicode in the slightest :). Does anyone have suggestions on handling Unicode files? I'm on an English (United States) Windows XP install trying to build with Visual C++. To deal with the headache that is passing Unicode Parameters I use URI Encoding (like here http://meyerweb.com/eric/tools/dencoder/) to encode the parameters to a command line program I wrote and then decode them as they come in. This part seems to work since I can decode the strings and write them to tags with the Unicode intact. But when I try to write tags to a file on a Unicode path it fails :(. Right no I'm using QT's library to handle the strings because of a stackoverflow post I found where the guy had good luck with it, but darned if I can get it working. int main(int argc, char *argv[]) { TagLib::List<TagLib::FileRef> fileList; std::string fileName( "c:\\temp\\debug " ); std::string extension (".txt"); ofstream a_file ( fileName + extension ); QString filepath ( argv[argc - 1] ); QString url = QUrl::fromPercentEncoding( filepath.toUtf8() ); a_file << "Param: " << url.toStdString() << "\n\n"; QFile myQfile ( url ); if( !myQfile.exists() ){ a_file << "The param \"" << myQfile.error() << "\" is not a file."; }//END IF TagLib::FileRef f( QFile::encodeName(url).constData() ); if(!f.isNull() && f.tag()) fileList.append(f); argc--; a_file.close(); //... If I get this far I can start applying tags. The above works great until I try it with a unicode path, like "C:\temp\私\Power Up!.mp3" which I encode as C%3A%5Ctemp%5C%E7%A7%81%5CPower%20Up!.mp3 I know I'm at least getting the string decoded right since I write it to a text file and it looks right in notepad++ encoded in UTF-8 without the BOM. -- Jeremy D Gregorio Sr Consultant #: 520-275-5352 fax: 520-747-2540 <http://www.linkedin.com/pub/jeremy-gregorio/36/302/429> <http://www.glimmersoft.com/socialmedia/btn_viewmy_160x33.png> |
From: Ankur M. <ank...@gm...> - 2013-03-28 11:13:18
|
Hi, I am evaluating id3lib for decoding ID3 tags having COMR fields. I know that is not common frame so i don't find its parsing implemented in most of the id3 editor / libraries. I could only find it details in id3tag library. I understand if I update code (src/field.cpp) I can get it parsed like other fields and its looks few lines of code (+ verification). My query is, is there any reason other than not much used and nobody needed/used... why its not implemented yet in id3lib. Also is there any tag available which I can use for verifying if I add support for it. One another basic query: I am planning to use buffer based input, rather then providing file of id3. I understand I should use MemoryReader object in Tag.Link() instead of passing filename/filepath... Is my understanding correct? Regards, Ankur |
From: Cedric T. <sha...@us...> - 2013-02-22 08:40:50
|
id3lib is effectively unmaintained at this point. On 2/18/2013 10:08 AM, Matt DeLuco wrote: > Any chance of getting in an update that makes id3lib a little more c99 friendly? > > I'm using id3lib in a Cocoa project on OS X, and the foundation library includes stdbool.h which typedefs bool and defines true and false. I've appended a condition to define bool in the absence of __bool_true_false_are_defined, which is defined in stdbool.h: > > Index: include/id3/globals.h > =================================================================== > RCS file: /cvsroot/id3lib/id3lib-devel/include/id3/globals.h,v > retrieving revision 1.56 > diff -r1.56 globals.h > 113c113 > < #ifndef __cplusplus > --- >> #if !defined(__cplusplus) && !defined(__bool_true_false_are_defined) > 119c119 > < #endif /* __cplusplus */ > --- >> #endif /* __cplusplus __bool_true_false_are_defined */ > MD > ------------------------------------------------------------------------------ > The Go Parallel Website, sponsored by Intel - in partnership with Geeknet, > is your hub for all things parallel software development, from weekly thought > leadership blogs to news, videos, case studies, tutorials, tech docs, > whitepapers, evaluation guides, and opinion stories. Check out the most > recent posts - join the conversation now. http://goparallel.sourceforge.net/ > _______________________________________________ > id3lib-devel mailing list > id3...@li... > https://lists.sourceforge.net/lists/listinfo/id3lib-devel > |
From: Matt D. <ma...@de...> - 2013-02-18 18:08:23
|
Any chance of getting in an update that makes id3lib a little more c99 friendly? I'm using id3lib in a Cocoa project on OS X, and the foundation library includes stdbool.h which typedefs bool and defines true and false. I've appended a condition to define bool in the absence of __bool_true_false_are_defined, which is defined in stdbool.h: Index: include/id3/globals.h =================================================================== RCS file: /cvsroot/id3lib/id3lib-devel/include/id3/globals.h,v retrieving revision 1.56 diff -r1.56 globals.h 113c113 < #ifndef __cplusplus --- > #if !defined(__cplusplus) && !defined(__bool_true_false_are_defined) 119c119 < #endif /* __cplusplus */ --- > #endif /* __cplusplus __bool_true_false_are_defined */ MD |
From: Romain B. <to...@ra...> - 2011-08-23 04:46:26
|
Hi Guys! I have the following test code: ----- #include <id3/tag.h> #include <stdio.h> int main() { ID3_Tag *tag = new ID3_Tag(); ID3_Frame *frame = new ID3_Frame(ID3FID_TITLE); frame->GetField(ID3FN_TEXT)->Set("foo"); tag->AttachFrame(frame); size_t size = tag->Size(); printf("Size: %lu\n",size); uchar *buffer = new uchar[size]; size_t len = tag->Render(buffer); printf("Render: %lu\n",len); return 0; } ----- Which outputs: Size: 2038 Render: 2048 The problem is that Render > Size despite what the doc says.. And it gets even worse with padding disabled.. Am I doing something wrong? Romain |
From: Valentyn P. <val...@gm...> - 2011-07-08 12:50:52
|
Hi, I'm working on a commercial project using id3lib and looks like I've found a bug in size_t ID3_Tag::Render(ID3_Writer& writer, ID3_TagType tt) const (tag.cpp, line ~654) Its code is the following: size_t ID3_Tag::Render(ID3_Writer& writer, ID3_TagType tt) const { ID3_Writer::pos_type beg = writer.getCur(); if (ID3TT_ID3V2 & tt) { id3::v2::render(writer, *this); } else if (ID3TT_ID3V1 & tt) { id3::v1::render(writer, *this); } return writer.getCur() - beg; } But both id3::v2::render() and id3::v1::render() take const ID3_TagImpl& as the second parameter. This causes creation of a temporary ID3_TagImpl with a destructor that destroys all frames owned by original ID3_Tag::_impl. I get a crash in ID3_TagImpl::~ID3_TagImpl() after trying to use ID3_Tag::Render(). I think the correct code must be the following: size_t ID3_Tag::Render(ID3_Writer& writer, ID3_TagType tt) const { ID3_Writer::pos_type beg = writer.getCur(); if (ID3TT_ID3V2 & tt) { id3::v2::render(writer, *(this->_impl)); } else if (ID3TT_ID3V1 & tt) { id3::v1::render(writer, *(this->_impl)); } return writer.getCur() - beg; } This code works fine in my case. -- Best regards, Valentyn Pavliuchenko -- Best regards, Valentyn Pavliuchenko |
From: Lukas D. <luk...@ho...> - 2011-03-01 09:14:46
|
Hi all In Mozilla, there is a new feature allowing developers to use an external dll and call functions without having to write a single line of binary code (Ctypes: https://developer.mozilla.org/en/JavaScript_code_modules/ctypes.jsm). Since I have no knowledge about C++, I thought I could try that to use id3lib in my XULRunner (Mozilla runtime environment) application. I then saw that that there is an id3lib implementation in C. My questions now: Where can I get the C version (and are there compilation instructuions/precompiled dlls)? I have to define objects and functions I use. Is there any further documentation on what datatypes are used (see: https://developer.mozilla.org/en/js-ctypes/Examples/Add_to_iPhoto#Select_API.c2.a0declarations for an example) Hope someone can help me with that. Have a nice day ~Lukas |
From: Jeremy G. <jer...@gm...> - 2011-02-27 05:34:56
|
Hi all, How do I write an ID3v2 Tag to an MP3? I want to be able to write unicode characters to my mp3s, but ID3v1.X doesn't support unicode... I wrote a simple tagging function trying to make a v2 tag, like so: //The following includes are to make the ID3v2 stuff compile... #include "id3v2tag.h" #include "mpegfile.h" #include <tlist.h> #include <fileref.h> #include <tfile.h> #include <tag.h> Tag(const wchar_t *path, const wchar_t *title, const wchar_t *artist, const wchar_t *album, const wchar_t *comment, const wchar_t *genre, const wchar_t *year, const wchar_t *track) {// Function takes 8 parameters. TagLib::FileName fs(path); TagLib::MPEG::File f(fs); TagLib::ID3v2::Tag *t = f.ID3v2Tag(true); TagLib::String tlTitle(title); t->setTitle(tlTitle); f.save(); }//END FUNCTION TAG But it only creates v1 tags, and so if there are unicode characters (like Japanese, Korean, Chinese, etc), it can't/doesn't write the tag. How do I force a v2 tag to be written? |
From: Patrick <hum...@gm...> - 2011-02-11 18:43:35
|
Hello, I am trying to send the binary (raw) picture data stream out to the cli using cout or something equivalent. I tried this..... if ( myFrame = myTag.Find ( ID3FID_PICTURE ) ) { uchar buffer[ 4096 ]; myFrame->Field ( ID3FN_DATA ).Get ( buffer, sizeof ( buffer ) ); cout << "data: " << buffer << endl; } and this.... ID3_Field* img = myFrame->GetField(ID3FN_DATA); if (img) { uchar data[4096]; const uchar *p1; img->Get(data, 4096); p1=img->GetRawBinary(); cout << "data: " << p1 << endl; } But neither will print the binary characters onto the screen. Can someone help me with this. I would greatly appreciate it. Thanks! Pat |
From: Geoffrey L. <ge...@hu...> - 2010-08-20 22:22:48
|
In this situation, I'd look at the difference between ID3v2.3.0 tags ID3v2.4.0 tags, and hack taglib. As taglib has a full archive of past releases, you might even find a version that suits your needs without modification. On 08/20/2010 09:31:35 AM, Thomas wrote: > Hi Geoffrey, > > I already tried taglib. It is able to read all kind of tags, but it > generates ID3v2.4.0 tags only. For compatibility reasons I want to > generate > ID3v2.3.0 tags and avoid ID3v2.4.0 tags. > > Generating ID3v2.3.0 tag seems to be a very challenging > requirement... > > Greetings > Thomas > > On Fri, Aug 20, 2010 at 6:14 PM, Geoffrey Leach <ge...@hu...> > wrote: > > > id3lib has not been maintained for some time. taglib -- > > http://developer.kde.org/~wheeler/taglib.html<http:// > developer.kde.org/%7Ewheeler/taglib.html>-- > is an excellent > > alternative. > > > > On 08/20/2010 12:19:10 AM, Thomas Salm wrote: > > > Hi there, > > > > > > I am using id3lib 3.8.3 to implement an application that tags my > MP3 > > > files. This is what I am doing: > > > > > > // create a tag > > > ID3_Tag *tag = new ID3_Tag(filename.c_str()); > > > ID3_Field *id3_field; > > > > > > // tag the file > > > ID3_Frame *title_frame = new ID3_Frame(ID3FID_TITLE); > > > if((id3_field = title_frame->GetField(ID3FN_TEXT))) { > > > id3_field->Set(podcast->get_title().c_str()); > > > tag->AttachFrame(title_frame); > > > } > > > ... > > > > > > // setup rendering parameters > > > tag->SetUnsync(true); > > > tag->SetExtendedHeader(true); > > > tag->SetCompression(false); > > > tag->SetPadding(true); > > > > > > tag->Update(ID3TT_ID3V1 |ID3TT_ID3V2); > > > > > > Unfortunately, the program generates ID3v1 tags only. I want to > > > generate > > > ID3v2.3.0 tags. Any suggestions? > > > > > > Greetings > > > Thomas > > > > > > ------------------------------------------------------------------------------ > > > This SF.net email is sponsored by > > > > > > Make an app they can't live without > > > Enter the BlackBerry Developer Challenge > > > http://p.sf.net/sfu/RIM-dev2dev > > > _______________________________________________ > > > id3lib-devel mailing list > > > id3...@li... > > > https://lists.sourceforge.net/lists/listinfo/id3lib-devel > > > > > > > > > > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by > > Make an app they can't live without > Enter the BlackBerry Developer Challenge > http://p.sf.net/sfu/RIM-dev2dev > _______________________________________________ > id3lib-devel mailing list > id3...@li... > https://lists.sourceforge.net/lists/listinfo/id3lib-devel > |
From: Thomas <to...@gm...> - 2010-08-20 16:31:42
|
Hi Geoffrey, I already tried taglib. It is able to read all kind of tags, but it generates ID3v2.4.0 tags only. For compatibility reasons I want to generate ID3v2.3.0 tags and avoid ID3v2.4.0 tags. Generating ID3v2.3.0 tag seems to be a very challenging requirement... Greetings Thomas On Fri, Aug 20, 2010 at 6:14 PM, Geoffrey Leach <ge...@hu...> wrote: > id3lib has not been maintained for some time. taglib -- > http://developer.kde.org/~wheeler/taglib.html<http://developer.kde.org/%7Ewheeler/taglib.html>-- is an excellent > alternative. > > On 08/20/2010 12:19:10 AM, Thomas Salm wrote: > > Hi there, > > > > I am using id3lib 3.8.3 to implement an application that tags my MP3 > > files. This is what I am doing: > > > > // create a tag > > ID3_Tag *tag = new ID3_Tag(filename.c_str()); > > ID3_Field *id3_field; > > > > // tag the file > > ID3_Frame *title_frame = new ID3_Frame(ID3FID_TITLE); > > if((id3_field = title_frame->GetField(ID3FN_TEXT))) { > > id3_field->Set(podcast->get_title().c_str()); > > tag->AttachFrame(title_frame); > > } > > ... > > > > // setup rendering parameters > > tag->SetUnsync(true); > > tag->SetExtendedHeader(true); > > tag->SetCompression(false); > > tag->SetPadding(true); > > > > tag->Update(ID3TT_ID3V1 |ID3TT_ID3V2); > > > > Unfortunately, the program generates ID3v1 tags only. I want to > > generate > > ID3v2.3.0 tags. Any suggestions? > > > > Greetings > > Thomas > > > ------------------------------------------------------------------------------ > > This SF.net email is sponsored by > > > > Make an app they can't live without > > Enter the BlackBerry Developer Challenge > > http://p.sf.net/sfu/RIM-dev2dev > > _______________________________________________ > > id3lib-devel mailing list > > id3...@li... > > https://lists.sourceforge.net/lists/listinfo/id3lib-devel > > > > > > |
From: Geoffrey L. <ge...@hu...> - 2010-08-20 16:14:38
|
id3lib has not been maintained for some time. taglib -- http://developer.kde.org/~wheeler/taglib.html -- is an excellent alternative. On 08/20/2010 12:19:10 AM, Thomas Salm wrote: > Hi there, > > I am using id3lib 3.8.3 to implement an application that tags my MP3 > files. This is what I am doing: > > // create a tag > ID3_Tag *tag = new ID3_Tag(filename.c_str()); > ID3_Field *id3_field; > > // tag the file > ID3_Frame *title_frame = new ID3_Frame(ID3FID_TITLE); > if((id3_field = title_frame->GetField(ID3FN_TEXT))) { > id3_field->Set(podcast->get_title().c_str()); > tag->AttachFrame(title_frame); > } > ... > > // setup rendering parameters > tag->SetUnsync(true); > tag->SetExtendedHeader(true); > tag->SetCompression(false); > tag->SetPadding(true); > > tag->Update(ID3TT_ID3V1 |ID3TT_ID3V2); > > Unfortunately, the program generates ID3v1 tags only. I want to > generate > ID3v2.3.0 tags. Any suggestions? > > Greetings > Thomas > ------------------------------------------------------------------------------ > This SF.net email is sponsored by > > Make an app they can't live without > Enter the BlackBerry Developer Challenge > http://p.sf.net/sfu/RIM-dev2dev > _______________________________________________ > id3lib-devel mailing list > id3...@li... > https://lists.sourceforge.net/lists/listinfo/id3lib-devel > |
From: Thomas S. <to...@gm...> - 2010-08-20 07:19:18
|
Hi there, I am using id3lib 3.8.3 to implement an application that tags my MP3 files. This is what I am doing: // create a tag ID3_Tag *tag = new ID3_Tag(filename.c_str()); ID3_Field *id3_field; // tag the file ID3_Frame *title_frame = new ID3_Frame(ID3FID_TITLE); if((id3_field = title_frame->GetField(ID3FN_TEXT))) { id3_field->Set(podcast->get_title().c_str()); tag->AttachFrame(title_frame); } ... // setup rendering parameters tag->SetUnsync(true); tag->SetExtendedHeader(true); tag->SetCompression(false); tag->SetPadding(true); tag->Update(ID3TT_ID3V1 |ID3TT_ID3V2); Unfortunately, the program generates ID3v1 tags only. I want to generate ID3v2.3.0 tags. Any suggestions? Greetings Thomas |
From: Damon R. <dre...@cl...> - 2010-06-12 15:49:24
|
On 5/9/2010 7:26 AM, jon bird wrote: > v2.4 in a v2.4 tag. Idlib is pretty much dead these days, I would > suggest using another library - taglib for example. I ported my code to > use this about 2 years ago. I wondered about that. Are there others besides tablib? Is this the favorite? Damon Register |
From: Brian R. <ra...@gm...> - 2010-05-27 16:51:30
|
I was considering how to write my own application to read SYLT frame information from an ID3 tag, but do not know enough about the MPEG format to know how to convert MPEG frame timing to real time in the case that the SYLT header indicates frame timing instead of millisecond timing. What's the minimum amount of handling I need to implement to ensure that I can account for the timing conversion in both a static or a variable bit rate audio file? Thanks in advance for any help you could provide. |
From: jon b. <ne...@on...> - 2010-05-09 12:38:05
|
In article <q2g...@ma...>, Rosa Maria Durante <ro...@gm...> writes >Hi everyone! > >I'm developing an id3 tag editor and i'm using id3lib. I have a problem with >version 4 of id3v2: when i link a file and check its version this way > >audio_file.link("song.mp3", ID3TT_ALL); >audio_file.SetSpec(ID3V2_4_0) >cout << audio_file.GetSpec() << endl; > >i get -1 (unknown) instead of 3 (ID3V2_4_0). So i can't read the file's >tags in this version. >There is another way to read it and modify it? > >Thanks a lot. > Id3v2.4 isn't supported in the library. I did do a hack on mine sometime ago to allow it to *read* those tags which are common to both v2.3 and v2.4 in a v2.4 tag. Idlib is pretty much dead these days, I would suggest using another library - taglib for example. I ported my code to use this about 2 years ago. -- == jon bird - software engineer == <reply to address _may_ be invalid, real mail below> == <reduce rsi, stop using the shift key> == posted as: news 'at' onastick 'dot' clara.co.uk |