I have been pulling my hair out on this one, probably an easy one:
void processSample(float* in) noexcept
{
const float input = *in;
data[currentPos] = input;
outPos = currentPos - delay;
//if (outPos < 0) outPos += dataLength;
*in = data[outPos];
++currentPos;
if (currentPos >= dataLength) currentPos -= dataLength;
}
When I remove the //, or change it in to if (outPos < 0) outPos = 0;, it crashes AUValTool and I do not understand why. Anyone any hint for me?