[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Libcdio-devel] Miscellaneous questions, primarily on design

From: Leon Merten Lohse
Subject: Re: [Libcdio-devel] Miscellaneous questions, primarily on design
Date: Sun, 22 Mar 2020 10:16:50 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.6.0


On 21.03.20 21:41, Samuel May wrote:

Thomas Schmitt wrote:
* What about changing the language of a block?  I know libcdio isn't
primarily a disc-authoring library, though with cdtext_set(..) and
cdio_get_cdtext_raw(..) it can definitely be used constructively

Indeed ? Does it burn audio CDs ?

I was maybe a bit over-generous in that description -- I mainly meant
that if someone wanted to use libcdio as an over-qualified CDTEXT binary
editor, they for the most part could.  (Though see my next response to
Rocky below.)

I believe there is a slight misunderstanding here.

libcdio parses the raw CDTEXT and stores it in an internal data structure. The raw CDTEXT can either be read from an audio CD or from a "raw CDTEXT dump".

The inverse (packing the internal data structure into raw CDTEXT) is not implemented, as far as I remember. So I would say libcdio is very far from being a CDTEXT binary editor.
IMHO Thomas' libburnia is a much better option here.

cdio_get_cdtext_raw dumps the raw CDTEXT from the current audio CD and has nothing to do with the CDTEXT parser.

cdtext_set is merely the "setter" for the internal data structure and should not be called from outside the library. I believe it is mainly exposed because at some point there was the idea to move the CDTEXT parser into an external library (which was later given up due to mutual dependencies).

Multi-language support was added at a much later stage so there was not so much freedom in the API, it needed to be backwards compatible, and not so many people were interested in it at the time. (To my knowledge) only very expensive mastering software even supported it then and I could not find any examples in the wild.
(Arguably the API could still have been designed better.)

Ah, right.  Do one thing but do it well.  I'm going to blame this on
getting distracted by the presence of cdtext_set(..) -- there's no way
to set the genre code either.  I'm guessing that cdtext_set(..) is in
there primarily because it's needed for cdtext_data_init(..), and there
wasn't much reason /not/ to add it to the interface?  Thanks for pulling
me back to the proper scope!


Best regards

reply via email to

[Prev in Thread] Current Thread [Next in Thread]