Error in the coeffcients of IIR makePeakFilter

HI i am getting an error as shown above. I am not able to understand the cause of that error when going through this youtube []
EQ tutorial.

The jasserts are there to make sure you don’t call this method with silly/invalid values.
The offending line checks, that the frequency is not 0 and below the nyquist frequency (sampleRate * 0.5).
So you need to step out the call stack and check a) what is frequency and b) how did it end up being an invalid value.

Hello Daniel
Thanks for the reply
I checked the frequency from my cpp scripts it shows as 0.0000

Could you please help me solve this error as my project submission is in a week and i have been searching for this error past 2 days.

Thank you

You found the error yourself. According to the library authors makePeakFilter cannot work with a frequency of 0, that’s why they added the jassert to give you a heads up.

Only you can answer, why you set the frequency to 0. Was that intentional?

As per the youtube tutorial i followed the steps it did work for him but it didnt for me.

First initiated the params (the above image)

Second, applied those in the preparetoplay and processblock functions.

I am not familiar with that video, and the link above doesn’t seem to work.

You should pick another default value to initialise the frequencies. Have a look at the default value you set in the parameters and initialise the peakFreq, lowCutFreq etc. all with the values you set as default in the parameters, that way you might not end up in this situation.

As of right now i have no idea what to do would you suggest me what to do for clearing this error out.

The video link

Done figuring it out daniel
Thanks for your support


Glad you found a solution.