MCPcopy Create free account
hub / github.com/BespokeSynth/BespokeSynth / WriteInterpolatedSample

Function WriteInterpolatedSample

Source/SynthGlobals.cpp:459–468  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

457}
458
459void WriteInterpolatedSample(double offset, float* buffer, int bufferSize, float sample)
460{
461 offset = DoubleWrap(offset, bufferSize);
462 int pos = int(offset);
463 int posNext = int(offset + 1) % bufferSize;
464
465 float a = offset - pos;
466 buffer[pos] += (1 - a) * sample;
467 buffer[posNext] += a * sample;
468}
469
470std::string GetRomanNumeralForDegree(int degree)
471{

Callers 1

ProcessMethod · 0.85

Calls 1

DoubleWrapFunction · 0.85

Tested by

no test coverage detected