working on my current project, an audio cd analyzer, I noticed, that
libcdio's cd-text extraction does not give me the expected results.
After reading through the source code an the equivalent part in cdda2wav,
I wrote a small patch for libcdio's cdtext.c:
adding isrc and mcn extraction from cd-text.
should also work more reliable now, when binary fields are present.
work on double-byte characters.
Currently only block 0 out of 0-7 is read. Is that intended? Are there any
audio CDs using more than block 0? If so, we should add a way to read
I could not find any information on the data format for binary cd-text
fields. Does anybody know more? Would be neat to also extract those
Concerning double-byte characters: Should we leave it to the user to work
with that or should the library convert it to a standard like encoding
utf8? Either way, it lacks a field in cdtext_t indicating double-byte
characters or the encoding.
I was also wondering why the cdtext functions do not have a cdio_ prefix.
Oh. And I found a little bug in the cdtext example code in the line:
const cdtext_t *cdtext = cdio_get_cdtext(p_cdio, 0);
I think the 0 should be substituted with i_track.
I just found some other issues.
cdio_get_cdtext even returns a cdtext_t object, if there is no cdtext
information available. The documentation says, it would return NULL in
that case. Would be kind of nice to get that fixed.
I started to work on proper GENRE and DISC_ID field extraction today.
Might take a while though, because the documentation on the internet is
very thin and even inconsistent in the case if DISC_ID is binary or char.
I am also not at home right now, so I do not have access to very many test
I also intend to implement extraction of the other 7 blocks and relate
them to their languages. Dunno how to do that, without breaking the API at
this point. Have to think about it a little more.
If anybody has information about CD-Text specifications and use other from
MMC3 draft, I would really appreciate to see them.