getmusicbee.com

MusicBee & Add-Ons => Customizations => Plugins => Topic started by: zkhcohen on March 18, 2019, 11:14:20 PM

Title: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 18, 2019, 11:14:20 PM
This is the page for tracking the development of a plugin which will display / tag files with their associated EBU R128 loudness metrics:

  Integrated loudness:
    I:          (LUFS)
    Threshold: (LUFS)

  Loudness range:
    LRA:         (LU)
    Threshold:  (LUFS)
    LRA low:    (LUFS)
    LRA high:    (LUFS)

  True peak:
    Peak:         (dBFS)

The stats will be displayed in a panel plugin, and it will (optionally) write them to tags in your files.

The plugin leverages the FFMPEG audio library.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 18, 2019, 11:15:16 PM
COPIED FROM THE OLD THREAD

I tried running that one in conjunction with the VST support plugin for Music Bee, but I haven't had any luck yet.

Still looking into alternatives.

The documentation indicates that there is both a stand-alone and VST version in the TT-DR installer--did you try the standalone version?  I was thinking that might be convenient to run via MB Tools on selected libray files.  I'd try it myself but DR analysis has really no interest for me, but Mr. Trev might give it a shot.  I did extract the installer via 7-Zip and it shows a "DR-Offline.exe" file and its own folder structure with own graphics as well as a VST dll in a separate folder.

I was thinking about doing a conversion of the TT-DR CLI someone made for Linux but then I found the ebur128 library in FFMPEG:

Code
FOR %a IN ("*.mp3") DO (ffmpeg -i "%a" -af ebur128=peak=true -f null - 2>&1 | FINDSTR /BIC:" ")


...should analyze every mp3 in a folder and spit out data like this:

Code
  Integrated loudness:
    I:         -12.9 LUFS
    Threshold: -23.3 LUFS
  Loudness range:
    LRA:        11.2 LU
    Threshold: -33.3 LUFS
    LRA low:   -20.7 LUFS
    LRA high:   -9.5 LUFS
  True peak:
    Peak:        0.2 dBFS

This is really efficient and the output is easy to work with. I'm no audio engineer, so it'll take a while for me to determine whether this is the best approach.

https://auphonic.com/blog/2012/08/02/loudness-measurement-and-normalization-ebu-r128-calm-act/


EDIT:


The following command will create a text file for each .mp3 which includes the data at the end:

Code
FOR %a IN ("*.mp3") DO (ffmpeg -i "%a" -af ebur128=peak=true -f null - > %a-output.txt 2>&1)


This would be really easy to implement into a MusicBee Plugin.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: sveakul on March 19, 2019, 12:22:19 AM
Thanks for this new project which I'm sure many MB users will be glad to add to their config!  Excellent on making tagging vs. values display optional.  If the Spectrogram plugin is any indication, I can see you flying through this one :)  Please offer use of an external path to ffmpeg as before.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: alec.tron on March 24, 2019, 09:47:51 AM
Neat! If this were a MB plug-in that optionally writes the info to metadata as well, this would be well useful. With additional txt files (if I understood correctly) I'll need to see if this would fit my library. But very interesting to see this realized either way!
Thanks a lot!
c.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 24, 2019, 04:41:32 PM
Neat! If this were a MB plug-in that optionally writes the info to metadata as well, this would be well useful. With additional txt files (if I understood correctly) I'll need to see if this would fit my library. But very interesting to see this realized either way!
Thanks a lot!
c.


Yep! Working on the part which writes to the file's metadata right this second.

Hoping to have updates very soon.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 25, 2019, 05:01:38 AM
Here's the first alpha release:

http://www.mediafire.com/file/nx3xtcyxqiaiib9/BETA_-_mb_Loudness_Analyzer.zip/file


PLEASE READ THIS:

Firstly, this is in ALPHA - you've been warned. There is plenty of room for improvement here, but I want to make it available to you guys for testing.

ALSO NOTE: This current implementation will OVERWRITE Custom Tag 10-16. For the love of God, do NOT run this on your DB and then complain that you lost those tags. You've been warned.


Installation:

1. Copy the plugins folder into your MusicBee directory, merging it with your default Plugins folder (or copy the .dll to that location).
2. Copy the Dependencies folder to your MusicBee AppData directory. Copy the ENTIRE folder, not just its contents.
3. Configure the names for your Custom Tags (10-16) and displayed columns. This is the format:

Custom Tag 10: Integrated Loudness
Custom Tag 11: IL Threshold
Custom Tag 12: LRA (Dynamic Range)
Custom Tag 13: Threshold
Custom Tag 14: LRA Low
Custom Tag 15: LRA High
Custom Tag 16: True Peak

...and here's a (rough) example of what it can look like:


(https://i.imgur.com/Rh4DUmG.png)


Usage:

1. Select 1+ files that you'd like to tag (I don't recommend more than 10 at a time on a low-powered machine with this current alpha build, but up to 100 on a high-powered machine).
2. Right-click and then click "EBU R128 Tag" from the Context Menu.
3. Accept the prompt to begin the tagging process. Wait for a couple of seconds (up to 5 for the first file) and then the file tags should quickly begin populating.

NOTE: You may have to click between files to see the tags updating in your columns. I plan on fixing this.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: sveakul on March 25, 2019, 05:51:26 AM
Some questions:

1.  In its current alpha state, does it only write to tags, or can it just do a pop-up GUI value display and NOT write to tags?

2.  Can a path be supplied to an external ffmpeg.exe?

This is just for my own curiosity.  The best testers will be those who actually apply and use R128/ReplayGain tags.  Good luck on your new project!
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 25, 2019, 05:56:30 AM
There's no pop-up at the moment since I'm guessing that very few (if any) people will need this info on the fly. I've adjusted the purpose of this plugin to be a pure substitute to the functionality of Foobar2000 and the Dynamic Range Analyzer plugin.

Yeah - you can create a path.txt file in the dependencies folder with the path to FFMPEG contained within it.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: sveakul on March 25, 2019, 06:03:40 AM
Thanks for the info!
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: Mr. Trev on March 25, 2019, 05:28:37 PM
Nice. I'll play around with this later.

Quick question…

Am I correct to assume that tag 12 (LRA) is the equivalent of the numbers spit out on http://dr.loudness-war.info?
Does this also give an album average or just on a per track basis?
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 25, 2019, 05:40:30 PM
Nice. I'll play around with this later.

Quick question…

Am I correct to assume that tag 12 (LRA) is the equivalent of the numbers spit out on http://dr.loudness-war.info?
Does this also give an album average or just on a per track basis?

Yes - LRA (Loudness Range) is the rough equivalent to the dynamic range number spit out by MAAT.

https://ask.audio/articles/demystifying-the-confusion-around-loudness-metering-levels

It uses a different algorithm so it doesn't always line up perfectly, but EBU R128 is generally considered a better standard.

This does not currently give an album-rating. To be honest, I'm not sure why that number is useful beyond comparing/complaining about the Loudness War. I'm not an audio engineer, so let me know if there's another reason.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: Mr. Trev on March 25, 2019, 08:42:43 PM
Nice. I'll play around with this later.

Quick question…

Am I correct to assume that tag 12 (LRA) is the equivalent of the numbers spit out on http://dr.loudness-war.info?
Does this also give an album average or just on a per track basis?

Yes - LRA (Loudness Range) is the rough equivalent to the dynamic range number spit out by MAAT.

https://ask.audio/articles/demystifying-the-confusion-around-loudness-metering-levels

It uses a different algorithm so it doesn't always line up perfectly, but EBU R128 is generally considered a better standard.

This does not currently give an album-rating. To be honest, I'm not sure why that number is useful beyond comparing/complaining about the Loudness War. I'm not an audio engineer, so let me know if there's another reason.

I'm not concerned if it aligns perfectly with MAAT - I've just gotten used to the 1-14+ scale they use.

As far as the album average rating, what I would use it for is for determining what music I want to compress and what I want to leave lossless on my portable devices. I look at the DR range for the album, see where it sits on that 1-14+ scale. If it has a low DR rating than i will convert the files to AAC to save space and max the amount of music that'll fit on my sd cards. I'll leave lossless for the albums where the artist/producers make to most of the DR range (basically comparing/complaining about loudness wars)
 
This is probably a very user specific reason, but its my reason anyways. Personally, I really can't say I need anything other than an album average rating TBH (I don't use replaygain or anything like it)

Cheers, looking forward to see what comes next
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: frankz on March 25, 2019, 10:38:01 PM
Don't go by me and start feeling pressured to add features based on what I think because the chances I'll ever use this are small (although it looks very cool), but Album DR ranges are useful in identifying specific sources and masterings for albums of which there are many different releases, vinyl vs CD versions, remasters, remixes, etc which aren't always identified in the tags when you "acquire" them.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 25, 2019, 11:34:51 PM
Thanks for the suggestions.

I'll look into adding an album DR rating.

I'll almost certainly implement it as a second sub-menu item that averages the DR over the selected songs (assuming that's how MAAT calculates it).
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 28, 2019, 02:18:07 AM
Hi folks,

Reposting this since it was lost in the migration.

The link has been updated with version 1.1. This update includes a context menu option for averaging the dynamic range values for a selection of files.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: sveakul on March 28, 2019, 03:13:31 AM
Thanks!  It would probably be best to move the whole content of your Reply#5 post to the the first post, so finding the current version and the installation/usage instructions is easy.
Title: Re: EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on March 29, 2019, 09:43:05 PM
Thanks!  It would probably be best to move the whole content of your Reply#5 post to the the first post, so finding the current version and the installation/usage instructions is easy.

Will do.

Hoping to get some feedback from the people who plan on using it before finalizing the README and creating a beta release.

I'm not interested in adding too much more, but I definitely want to add some customization for the result set.
Title: Re: (ALPHA 1.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: captain_paranoia on April 25, 2019, 01:39:03 AM
Just gave it a try.
Put the DLL in the MusicBee Plugins install directory.
Put the Dependencies folder in the 'C:\Users\User\AppData\Roaming\MusicBee' folder
Started MB.
Needed to add the plugin in Preferences.
Needed to restart MB to get the DR tool to appear in the context menu
Selected an album (Metallica's notorious 'Death Magnetic', in FLAC) in AlbumArt view, and hit the EBU R128 option.
Generated this eror report, which closed MB on clicking 'OK':

MusicBee v3.2.6760.38310 (Win6.1), 25 Apr 2019 1:28:

System.IO.FileNotFoundException: Could not find file 'C:\Users\User\AppData\Roaming\MusicBee\Dependencies\LoudnessTextFiles\Broken,Beat&Scarred-Metallica-FLACaudiofile-625.txt'.
File name: 'C:\Users\User\AppData\Roaming\MusicBee\Dependencies\LoudnessTextFiles\Broken,Beat&Scarred-Metallica-FLACaudiofile-625.txt'
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.StreamReader..ctor(String path, Encoding encoding, Boolean detectEncodingFromByteOrderMarks, Int32 bufferSize, Boolean checkHost)
   at System.IO.StreamReader..ctor(String path)
   at MusicBeePlugin.Plugin.ParseValues(Int32 currentSong)
   at MusicBeePlugin.Plugin.<>c__DisplayClass21_0.<AnalyzeSong>b__0(Object sender, EventArgs e)
   at System.Diagnostics.Process.OnExited()
   at System.Diagnostics.Process.RaiseOnExited()
   at System.Diagnostics.Process.CompletionCallback(Object context, Boolean wasSignaled)
   at System.Threading._ThreadPoolWaitOrTimerCallback.WaitOrTimerCallback_Context(Object state, Boolean timedOut)
   at System.Threading._ThreadPoolWaitOrTimerCallback.WaitOrTimerCallback_Context_f(Object state)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading._ThreadPoolWaitOrTimerCallback.PerformWaitOrTimerCallback(Object state, Boolean timedOut)

Is it essential to name the custom tags...? I didn't...
Title: Re: (ALPHA 1.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on April 25, 2019, 04:17:08 AM


System.IO.FileNotFoundException: Could not find file 'C:\Users\User\AppData\Roaming\MusicBee\Dependencies\LoudnessTextFiles\Broken,Beat&Scarred-Metallica-FLACaudiofile-625.txt'.

File name: 'C:\Users\User\AppData\Roaming\MusicBee\Dependencies\LoudnessTextFiles\Broken,Beat&Scarred-Metallica-FLACaudiofile-625.txt'



Does this file exist? Does the filename match the one above, exactly?

It sounds like it either didn't generate the file, or maybe permissions are preventing it from reading it.

Do any files work?

Please let me know! I'm going to begin updating this plugin and refining it.


Title: Re: (ALPHA 1.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: captain_paranoia on April 25, 2019, 08:53:34 AM
The folder exists (as copied; didn't need admin rights to copy, unlike the DLL), the files don't.

I tried with MP3 files, with the same result.

Permissions struck me as a possibility, but MB is able to copy the plugin to the AppData folder. It look like it wasn't generated; maybe ffmpeg didn't execute?
Title: Re: (ALPHA 1.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: captain_paranoia on April 26, 2019, 12:39:42 AM
This was the problem...

C:\Users\User\AppData\Roaming\MusicBee\Dependencies>ffmpeg
This version of C:\Users\User\AppData\Roaming\MusicBee\Dependencies\ffmpeg.exe is not compatible with the version of Windows you're running.
Check your computer's system information to see whether you need a x86 (32-bit) or x64 (64-bit) version of the program, and then contact the software publisher.

I downloaded the latest static, 32-bit x86 build from https://ffmpeg.zeranoe.com/builds/ and I can now run ffmpeg from the command line. And the EBU R128 tagger now runs, launching lots of copies of ffmpeg, taking quite a long time on my bedroom media all-in-one PC...

So it looks like your plug-in will need to have 32-bit & 64-bit option downloads, or else refer people to get their own ffmpeg.

I might also suggest the plug-in be configurable to allow the maximum number of ffmpeg instances it will launch in parallel to be user specified.

Thanks for this plug-in; I've been looking for a DR tagger for some time. I'll have to install it on my main PC to get it to process all 70k tracks I've got...
Title: Re: (ALPHA 1.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: sveakul on April 26, 2019, 12:52:17 AM
Is it essential to name the custom tags...? I didn't...

captain_paranoia:  did you need to first create the custom tag labels for it to start working, or was just getting the right ffmpeg.exe enough?  I agree with you on having a user-selectable option for maximum running instances of ffmpeg.
Title: Re: (ALPHA 1.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: captain_paranoia on April 26, 2019, 12:57:27 AM
I tried adding the tag labels last night; no joy. I'm pretty sure it was just the incompatible ffmpeg.exe, which is why it crashed out with an error message so quickly. The expected text files are now created by the correct ffmpeg.exe
Title: Re: (ALPHA 1.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on April 26, 2019, 09:46:23 AM
This was the problem...

C:\Users\User\AppData\Roaming\MusicBee\Dependencies>ffmpeg
This version of C:\Users\User\AppData\Roaming\MusicBee\Dependencies\ffmpeg.exe is not compatible with the version of Windows you're running.
Check your computer's system information to see whether you need a x86 (32-bit) or x64 (64-bit) version of the program, and then contact the software publisher.

I downloaded the latest static, 32-bit x86 build from https://ffmpeg.zeranoe.com/builds/ and I can now run ffmpeg from the command line. And the EBU R128 tagger now runs, launching lots of copies of ffmpeg, taking quite a long time on my bedroom media all-in-one PC...

So it looks like your plug-in will need to have 32-bit & 64-bit option downloads, or else refer people to get their own ffmpeg.

I might also suggest the plug-in be configurable to allow the maximum number of ffmpeg instances it will launch in parallel to be user specified.

Thanks for this plug-in; I've been looking for a DR tagger for some time. I'll have to install it on my main PC to get it to process all 70k tracks I've got...

Shoot. I totally forgot to mention that for this plugin. I did mention the 64 bit requirement for my other plugin which utilizes FFMPEG.

I've got a couple of big improvements in the pipeline, so keep posted.
Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on April 30, 2019, 02:50:07 AM
Update:

Added a settings panel which allows you to select which stats to collect and which Custom Tags to use:


(https://i.imgur.com/N9ZFVC3.png)




Consolidated menu items into subfolder:

(https://i.imgur.com/ETTmqhC.png)




Added prompt notifying end of tagging process:

(https://i.imgur.com/TMpHTBj.png)

Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on April 30, 2019, 03:44:40 PM
Great idea and work zkhcohen!

I have a suggestion/request:

Would it be possible to add the option to populate a custom tag with the Integrated Loudness of a track, taking into account the adjustment that will be made by the calculated adjustment value present in the Tack Gain tag?
Then you could easily see if the resulting integrated loudness after gain adjustment is what you are aiming for.

For example, I am usually aiming for -21 LUFS for my non-classical library tracks. (-3 on MB's slider)
But currently it is hard to know if tracks that have a track gain tag present were calculated with the aim of -21 LUFS, and thus, how loud they will actually be playing.
Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on April 30, 2019, 04:03:47 PM
And a suggestion for the user interface:

When you initiate the tag function, a popup displays 'Tagging selected files...' and a button labeled 'OK'.

Firstly, at first encounter it is not clear what 'OK' would do. Is it a confirmation to begin tagging?
No it isn't, tagging is in progress already.
So if you would want a button there, maybe something like 'cancel' or perhaps 'hide' would be appropriate, but 'OK' is a bit vague.

Secondly, if you don't press OK and are waiting until the operation has finished, you keep waiting, since the popup will not disappear after tagging has concluded.
Only after you finally do press 'OK' at some point, then you get the popup 'Tagging complete'.

Maybe the first popup could disappear automatically after tagging has completed?
Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on April 30, 2019, 10:25:05 PM
Those suggestions shouldn't be too difficult to implement.

I'll try to do it ASAP.
Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 01, 2019, 01:07:11 AM
Great idea and work zkhcohen!

I have a suggestion/request:

Would it be possible to add the option to populate a custom tag with the Integrated Loudness of a track, taking into account the adjustment that will be made by the calculated adjustment value present in the Tack Gain tag?
Then you could easily see if the resulting integrated loudness after gain adjustment is what you are aiming for.

For example, I am usually aiming for -21 LUFS for my non-classical library tracks. (-3 on MB's slider)
But currently it is hard to know if tracks that have a track gain tag present were calculated with the aim of -21 LUFS, and thus, how loud they will actually be playing.


Would you simply want the option to map the input_i parameter with with IL and MusicBee's track gain, or did you want to just input your own target value?

https://peterforgacs.github.io/2018/05/20/Audio-normalization-with-ffmpeg/

OR... were you looking for double-pass normalization?

Just a soft reminder that I'm not an audio engineer so I'm doing this through Google and your recommendations.
Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 01, 2019, 07:46:05 AM
Would you simply want the option to map the input_i parameter with with IL and MusicBee's track gain, or did you want to just input your own target value?

How I am guessing this would work is that your plugin does everything it is already doing, but additionally looks for an existing track gain tag value in a track, and adds/substracts that value to/from the integrated loudness value that your plugin has calculated, and writes that value to a custom tag.

So e.g. if a track already has a track gain tag present of let's say +3 dB, and your plugin calculates an integrated loudness of -20 LUFS for it, you can have it write a custom tag saying -17 LUFS.

That will make it possible to see how loud the track will actually be playing.
That is something MusicBee cannot do.


edit:
Thinking it a bit through, perhaps it would be better to create a virtual tag for this, since that would show and update that value after MB has performed a loudness analysis.
So before you put any work into this, let's first see how that would work.

edit2:
It looks like virtual tags cannot perform simple mathematical functions such as add/subtract.
(somebody please correct me if I am wrong)
That means you would additionally need to install and setup the Additional Tagging Tools plugin.

So I think it would indeed be nice if your plugin could do this by itself.
Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 04, 2019, 05:43:15 PM
Would you simply want the option to map the input_i parameter with with IL and MusicBee's track gain, or did you want to just input your own target value?

How I am guessing this would work is that your plugin does everything it is already doing, but additionally looks for an existing track gain tag value in a track, and adds/substracts that value to/from the integrated loudness value that your plugin has calculated, and writes that value to a custom tag.

So e.g. if a track already has a track gain tag present of let's say +3 dB, and your plugin calculates an integrated loudness of -20 LUFS for it, you can have it write a custom tag saying -17 LUFS.

That will make it possible to see how loud the track will actually be playing.
That is something MusicBee cannot do.



Interesting. Yeah - that seems to work. Adding the MusicBee-calculated Track Gain to the EBU R128-calculated Integrated Loudness does result in the -18LUFS target loudness when using the EBU R128 test-set. Of course if you adjust the volume target to -5.0db in MusicBee, then you end up with the -23LUFS target of EBU R128.

I'll try to implement this soon.


EditL Haven't had time to work on this quite yet due to my schedule. It's going to happen, though.
Title: Re: (Version 1.2) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 13, 2019, 09:37:59 PM
BETA 1.3: Added the ability to calculate and tag the current loudness (IL + Track Gain) of selected tracks. Added tagging options for both the "Current Loudness" (required) and "Average Songs" (optional) features.
Title: Re: (Version 1.3) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 13, 2019, 10:50:03 PM
Thanks for the update and the additions.

I'm sorry to say that after only doing very quick testing I have had a few crashes, error popups, MB closing, etc.
Also I noticed that for one album that I checked for Current Loudness, the plugin reported various levels between -140 and -190 LUFS for the tracks.
(which obviously can't be right, since in this specific case it should have been -23 LUFS, and the same value for all tracks)

This reply is just a primal and brief notification of issues I experienced.
Of course you deserve and need a more detailed report on when what and how these issues occur, and I will do that within a couple of days.
But considering the MB crashes I experienced I thought to let you know this asap.
Title: Re: (Version 1.3) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 13, 2019, 10:52:01 PM
Thanks for the update and the additions.

I'm sorry to say that after only doing very quick testing I have had a few crashes, error popups, MB closing, etc.
Also I noticed that for one album that I checked for Current Loudness, the plugin reported various levels between -140 and -190 LUFS for the tracks.
(which obviously can't be right, since in this specific case it should have been -23 LUFS, and the same value for all tracks)

This reply is just a primal and brief notification of issues I experienced.
Of course you deserve and need a more detailed report on when what and how these issues occur, and I will do that within a couple of days.
But considering the MB crashes I experienced I thought to let you know this asap.

Wow, that's weird.

Definitely give me screenshots and crash reports! I'll fix all of them when I have more information.
Title: Re: (Version 1.3) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 13, 2019, 10:58:58 PM
Thanks for the update and the additions.

I'm sorry to say that after only doing very quick testing I have had a few crashes, error popups, MB closing, etc.
Also I noticed that for one album that I checked for Current Loudness, the plugin reported various levels between -140 and -190 LUFS for the tracks.
(which obviously can't be right, since in this specific case it should have been -23 LUFS, and the same value for all tracks)

Did you overwrite the config file with the new one I put in the Dependencies folder?
Title: Re: (Version 1.3) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 13, 2019, 11:05:36 PM
Did you overwrite the config file with the new one I put in the Dependencies folder?

I used a recent and clean portable MB installation that didn't have your plugin installed before.
(I have a couple of those for different usage/testing)
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 13, 2019, 11:17:20 PM
Did you overwrite the config file with the new one I put in the Dependencies folder?

I used a recent and clean portable MB installation that didn't have your plugin installed before.
(I have a couple of those for different usage/testing)

Fixed a couple of crashes and uploaded version 1.3.1.

Hopefully this version works better.

If you still get miscalculations, can you send me the file?

Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 14, 2019, 12:02:46 AM
If you still get miscalculations, can you send me the file?

Thnx, I will do that.
(It will be a few days though, since I would like to give you a dependable account, and not some impulsive cry-wolf response)
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 14, 2019, 08:24:39 AM
A quick observation:

The weird and very high 'current loudness' values are probably due to regional settings. I noticed that I have Track Gain decimals comma separated, but the values that your plugin writes are period separated.
Except for the current loudness, which is comma separated again.
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 16, 2019, 07:43:44 AM
A quick observation:

The weird and very high 'current loudness' values are probably due to regional settings. I noticed that I have Track Gain decimals comma separated, but the values that your plugin writes are period separated.
Except for the current loudness, which is comma separated again.

Thanks. You're correct. I'm working on a fix but I'm abroad atm.
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 21, 2019, 09:31:29 AM
BETA 1.3.2: Fixes for localization errors. Fixes for index exception.

http://www.mediafire.com/file/nx3xtcyxqiaiib9/mb_Loudness-Analyzer.zip/file
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 21, 2019, 06:11:03 PM
Something is wrong.

When I have tracks with existing Track Gain values, their TG values are displayed correctly in the column browser.
If I then only enable your plugin (not even running it on the files) and I rescan the files, the TG values for all the files in the column browser suddenly display as "0.0 dB".
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 21, 2019, 06:14:36 PM
Something is wrong.

When I have tracks with existing Track Gain values, their TG values are displayed correctly in the column browser.
If I then only enable your plugin (not even running it on the files) and I rescan the files, the TG values for all the files in the column browser suddenly display as "0.0 dB".

Ehhh? That's super weird. Can you send me a screenshot.

I'm not experiencing this.
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 21, 2019, 06:19:51 PM
(https://i.imgur.com/0HyZDCT.png)

If after that I disable your plugin, restart MB, and rescan the files, they will show the correct TG value in the column browser again.
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 22, 2019, 08:08:44 AM
(https://i.imgur.com/0HyZDCT.png)

If after that I disable your plugin, restart MB, and rescan the files, they will show the correct TG value in the column browser again.


(https://i.imgur.com/kmqMHLu.png)


My Track Gain tags and column look fine.

What's your MusicBee version number?

Any chance you can send me your MB settings?

I feel like I'm running into issues I can't replicate with all of my add-ins and I'm confused as to what's different about my configuration...
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 22, 2019, 08:49:35 AM
Any chance you can send me your MB settings?

I'll do better, I've send you my complete portable testing installation.
(see PM)
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on May 26, 2019, 11:40:21 AM
Any chance you can send me your MB settings?

I'll do better, I've send you my complete portable testing installation.
(see PM)

I just had a chance to test it. I can confirm that the issue is due to your localization settings: French (France) doesn't work, but English (United States) does.

I'm not sure why this is occurring yet.
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on May 26, 2019, 06:52:04 PM
Thanks for taking a further look at this.

What surprised me also about this, is that when you have only activated the plugin but haven't performed any action with it, it obviously affects how MusicBee displays this field.

So it looks like it is running some process in the background even when you have not triggered any action. Is that needed?
I was expecting that only when you run it, it would do an analysis, then write the requested tags, and then terminates.
Is it however nesting itself a bit deeper into the functioning of MusicBee?
Title: Re: (Version 1.3.1) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on June 05, 2019, 11:55:02 PM
Thanks for taking a further look at this.

What surprised me also about this, is that when you have only activated the plugin but haven't performed any action with it, it obviously affects how MusicBee displays this field.

So it looks like it is running some process in the background even when you have not triggered any action. Is that needed?
I was expecting that only when you run it, it would do an analysis, then write the requested tags, and then terminates.
Is it however nesting itself a bit deeper into the functioning of MusicBee?

Fixed.

https://www.mediafire.com/file/nx3xtcyxqiaiib9/mb_Loudness-Analyzer.zip/file
Title: Re: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on June 07, 2019, 02:58:03 PM
1.3.4: Implemented better fix for localization errors.
Title: Re: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: Thalion Korvhas on August 21, 2021, 10:31:45 PM
Is this plugin still being actively developed? Ever since I discovered Foobar's dynamic range plugin, I use it religiously. It is a great tool. So I am excited to see work being done for one in MusicBee. I played around with it a bit & some of my observations:

1) I thought there would be a file created in the directory of the track / album that was tagged. Is that not implemented yet? A permanent record would be very useful. I run the tags by albums & keep Foobar's file in the album folder for future reference. It is also easier imo to open the text files side by side of two albums than trying to compare them vs each other in the MusicBee panel (In fact I am not sure you can at all). I compare different masterings of the same ablum side by side all the time.

2) I guess I did not understand the discussion of a popup panel to view the newly created tags at a glance? I did not see one, so I went to the main music panel, changed to album/tracks view, added display options for the new tags, then went to the custom tag settings (tag (1)) and renamed them accordingly.

3) There really needs to be a couple of better descriptions in the settings panel. I understand the terms dynamic range, peak, rms, dynamic range low, dynamic range high. You are using more exact terms & it is a bit confusing. I keep having to look up the terms to coordinate with what I know. For example: The term RMS does not appear at all in the settings panel. I finally figured out that Integrated Loudness was RMS. Please add (RMS) to the front like you did (Peak) with True Peak. Maybe it is my ignorance, but I will have to do more reading to understand what the thresholds mean.

4) Any chance to allow us to change the name of this plugin to a custom name? I would prefer a more layman's name so that in 6 month's to a year I come back wondering what this plugin is.

5) It would be nice to see the values to at least 2 decimals. Values for say peak as -1.14 instead of just -1.1, etc. A bit more accuracy is nice especially when comparing similar masterings.

6) I have only used one program such as this. I thought the values between the two should be comparable. The peak & rms values are sort of close. They are often 1 unit off from the foobar one (I.E. rms 17.6 vs 18.5). The dynamic range average/high/low are very far off in multiple tracks vs what I am used to seeing in the Foobar plugin (I.E. Foobar will give a value of 12, this plugin will say 6.34). I do not intend to be rude, but that is not correct. a DR of 6.34 means this track is compressed and it is not I can tell by listening when it is compressed. Because of this I really do not think I can trust this plugin. Please do not think I am being rude, just giving feedback.

The good news is that I got this plugin with MB to add the new tags to the files & populate them as I would expect them to. I really think this will add nice functionality to MB. Thanks for the efforts.
Title: Re: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on August 21, 2021, 10:39:17 PM
Is this plugin still being actively developed?

You make a lot of great suggestions, but I haven't had the time to work on any of my plugins for a very long time.

Unfortunately I barely knew what I was doing when these were written, so there are a lot of improvements that could be made.

That being said, the source code for all of my plugins is public on my GitHub: https://github.com/zkhcohen/mb_Loudness-Analyzer
Title: Re: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: Thalion Korvhas on August 22, 2021, 01:25:51 AM
Is this plugin still being actively developed?

You make a lot of great suggestions, but I haven't had the time to work on any of my plugins for a very long time.

Unfortunately I barely knew what I was doing when these were written, so there are a lot of improvements that could be made.

That being said, the source code for all of my plugins is public on my GitHub: https://github.com/zkhcohen/mb_Loudness-Analyzer

If you ever find the time to perfect it, it would be a great addition to MB. The Foobar plugin is not being developed either. The biggest problem with it is, you cannot customize the tags that it writes. It only writes 2 tags - album DR and track DR. Yours will write so much more.
Title: Re: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: hiccup on July 02, 2022, 06:34:16 PM
Hi zkhcohen.

Is it safe to assume this plugin will not be developed any further?
(I'm probably asking the obvious, since you have already explained elsewhere how busy you are in real life these days)
Title: Re: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on July 02, 2022, 07:03:06 PM
Hi zkhcohen.

Is it safe to assume this plugin will not be developed any further?
(I'm probably asking the obvious, since you have already explained elsewhere how busy you are in real life these days)


You're right, I honestly don't have the time to maintain them. The only plugin I really utilize (and every day, for that matter) is the Spectrogram plugin I created, so if I ever run into an issue with that, I would definitely update it immediately.

I think I'm going to transfer all of these repos to a new GitHub profile and make them public. I'll set a reminder to do that later today.
Title: Re: (Version 1.3.4) EBUR 128 - Loudness and Dynamic Range Plugin / Tagging Tool
Post by: zkhcohen on August 02, 2022, 06:16:43 PM
Hi zkhcohen.

Is it safe to assume this plugin will not be developed any further?
(I'm probably asking the obvious, since you have already explained elsewhere how busy you are in real life these days)


All of the repos for my plugins are available on my github: https://github.com/zkhcohen/