jaakkopasanen / AutoEq

Automatic headphone equalization from frequency responses
MIT License
13.21k stars 2.47k forks source link

AutoEQ incorrectly using LS instead of LSC #610

Closed coda101 closed 1 year ago

coda101 commented 1 year ago

Describe the bug When comparing an EQ result that only use peaking filters to that of AutoEQ precomputed results (that use shelve filters) the sound of either is not identical. This is because AutoEQ is incorrectly labelling the filters as an "LS" instead of "LSC".

To Reproduce Use crin graph or squig to create a Harman EQ for example, and compare the resulting sound with AutoEQ's precomputed result. You can use only peaking filters if you want or a bass shelf because the default will be LSC for the online graph tool.

Expected behavior The bass should be the same, but it sounds different (fuller, in my case, because AutoEQ was boosting mid bass too much).

coda101 commented 1 year ago

I think it may be more noticeable with high gain shelf filters. Low gain seems indistinguishable.

coda101 commented 1 year ago

Also using HS instead of HSC

jaakkopasanen commented 1 year ago

Fixed! Thanks a lot for pointing this out to me!

bhack commented 1 year ago

@wwmm Is this going to break easyeffects APO parsing?

wwmm commented 1 year ago

Is this going to break easyeffects APO parsing?

@Digitalone1 was direct involved in the APO preset parsing implementation and will be able to give a better answer. But in a quick look at the code my guess is that if the label was wrong in the preset file its corresponding value will go the the wrong place. In other words the parsing will work but the value will not be saved where the person that created the preset intended because the label is wrong.

wwmm commented 1 year ago

Forget it. I think that our parsing is handling these labels in the same way. It is better to wait for @Digitalone1 answer.

Digitalone1 commented 1 year ago

@wwmm Is this going to break easyeffects APO parsing?

I'm not an expert of audio filters, anyway looking at the code, LCS will apply Low-shelf filter.

https://github.com/wwmm/easyeffects/blob/master/src/equalizer_ui.cpp#L42

Then it will parse the gain and, if the quality is not present, it's set as 2/3 float:

https://github.com/wwmm/easyeffects/blob/master/src/equalizer_ui.cpp#L248-L253

Don't know if this is what you want, I hope it's enough. The code was imported from LSP equalizer plugin.

wwmm commented 1 year ago

Thanks @Digitalone1. I had forgotten we are doing the same as LSP. So it is probably fine. I just wonder why LS and LSC are both mapped to low shelf. @bhack what is the difference between them? I have never used APO.

jaakkopasanen commented 1 year ago

LS is a fixed slope low-shelf filter and is approximately 0.67 Q. LSC is the one where you can control Q. Using LS instead of LSC was simply a mistake on my part.

bhack commented 1 year ago

It seems that we have an extra parameter but I don't know if we have it in LSP equalizer. See the filter table at https://sourceforge.net/p/equalizerapo/wiki/Configuration%20reference/

There was also an old thread on reddit/oratory1990: https://www.reddit.com/r/oratory1990/comments/qkhunz/ls_or_lsc_setting_in_config/

bhack commented 1 year ago

LS is a fixed slope low-shelf filter and is approximately 0.67 Q. LSC is the one where you can control Q. Using LS instead of LSC was simply a mistake on my part.

Yes it is the extra Q so if we don't have a problem mapping LCS/HCS string and its Q the parser is working ok.