LancePutnam / Gamma

Generic (Sound) Synthesis Library
Other
458 stars 54 forks source link

DSF antialias() not compiling on Windows #61

Closed mhetrick closed 1 year ago

mhetrick commented 1 year ago

I'm running into an unusual compilation issue on Windows when using the DSF oscillator. If I attempt to call the antialias() function, compilation fails when trying to resolve this->freq() inside of DSF::maxHarmonics().

I've attached two images below. The compiler seems to not see the getter freq() inherited from AccumPhase and is instead complaining that the setter freq(TV v) is missing arguments.

Once I remove the call to antialias() the project compiles as expected.

image

image

LancePutnam commented 1 year ago

I get the same error with GCC 10.3. Apparently I haven't called that function in a while. :) freq(void) is a member of the base class, but it gets hidden since DSF overloads it with freq(Tv v). C++ hides base class members when they get overloaded, so you have to use an explicit namespace. That should be fixed now in master.