ebu / ebu_adm_renderer

The EBU ADM Renderer, written in Python, is the reference implementation of EBU Tech 3388
https://ear.readthedocs.io
BSD 3-Clause Clear License
80 stars 14 forks source link

ear-utils: add possibility to replace chna #81

Open WernerBleisteiner opened 5 days ago

WernerBleisteiner commented 5 days ago

All along, ear-utils offers the possibility to extract ADM's axml and chna chunks. Yet it only allows to add/replace (modified) axml (back). More and more there occur use cases that also require to modify chna data. So it'd be very helpful to do this with a similar process via ear-utils (other ways tend to be tricky and tedious)

tomjnixon commented 5 days ago

Yeah, i agree that would be useful. The issue I have is that it's not clear what file format should be used to specify the new CHNA items.

I suppose CSV would work, but it's not a pleasant format, and dump_chna already produces a format wich would be annoying to parse.

I think the --gen-chna option should cover most use cases, except those where you need more than one CHNA entry per track. This works by assuming that, for example, ATU_00000002 is the second track.

WernerBleisteiner commented 5 days ago

Thanks. Yeah, that's an interesting question. Just found out (when tweaking chna with HEXFIEND) that ear-utils dumps an easier readable output. Ideally, I'd prefer to take just that format, make changes and inject it again. Is there a --gen-chna option in ear-utils? Mine does not seem to know it. Which version of EAR?

tomjnixon commented 2 days ago

Ideally, I'd prefer to take just that format, make changes and inject it again.

Yeah, that workflow makes sense. Probably the best approach would be to change the output of ear-utils dump_chna to something more sensible.

Is there a --gen-chna option in ear-utils? Mine does not seem to know it. Which version of EAR?

It's an option for ear-utils replace_axml -- you should be able to see it with ear-utils replace_axml --help. It's been there since version 1!

WernerBleisteiner commented 1 day ago

Thanks @tomjnixon ! Gotta check it out, wasn't aware of that (some utilities seem to be too well hidden🙄)