Is there a device to normalize a clip to -6db peak?

fabio m's icon

As for the title I'm looking for a way t onormalize a clip to -6dB peak.

If there is not, would it be possible to create one with Max?

Any help or link will be appreciated.

Thx.

Nodanoma's icon

when you say 'clip', are you referring to a clip in Ableton Live, perhaps?
'clip' in Max terminology would merely refer to 'clipping' values into range, and speaking of audio one would think of it as 'buffer'…

An audio clip in Ableton only references (a section of) an audiofile on disk which you would need to load, analyse and then normalise to a desired gain. This can be done in Max, but takes a few steps and the certainty that it will be worth implementing. Also seeing that the connection between the clip and the audiofile is not (necessarily) obvious to the Max API..

fabio m's icon

Yes, I was referring to a clip in Live. I didn't specify it because I started the thread choosing the category "Max for live" but that must have been lost on the way...

And yes, I'm not an audio engineer nor a Max coder (I only painstakenly created from scratch (zero knoledge of Max language) a remote control in 2022 to be able to control A.Live from my music stand while playing the guitar or singing, with the help of TouchOSC and OSC) so I don't know the right approach to do this kind of things. And the fact that in Live a clip can (or usually is) just a part of a whole file would probably require some dividing and or copying before applyng the result of an analisys...

And that tells why in Live you have to consolidate to be able to normalize a clip or a bunch of clips...

Anyway, I was just asking if it would be possible.

Thank you.

melt's icon

Are you referring to a clip in the arrangement view, or in the session view?

A section of audio in the arrangement view could be a smaller piece of a larger file, which complicates the normalization process for sure.

A clip in the session view is not part of a larger file. You can use the Live Object Model to get the file path on disk for that clip and then run your normalization operation on that file.

You can also use the Live Object Model to get a Clip ID of a piece of audio in the arrangement view. Then you can get the file path of that Clip ID and run your normalization. But if that is the same file on disk used by other clips in your arrangement, you will run into problems (in that I don't see a way of isolating that audio to run your operations on).

Check the Live Object Model, perhaps you will find something useful - https://docs.cycling74.com/apiref/lom/