Skip to content

Commit

Permalink
Sine OSC Feedback Modulation Fix
Browse files Browse the repository at this point in the history
The Sin OSC feedback evaluated whether feedback was negative
per block not per sample, making it somewhat discontinuous
when modulated.

Addresses surge-synthesizer#7353
  • Loading branch information
baconpaul committed Jan 14, 2024
1 parent 23d9ee0 commit 5f5f73a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/common/dsp/oscillators/SineOscillator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -640,7 +640,6 @@ void SineOscillator::process_block_internal(float pitch, float drift, float fmde
p[i] = 0.0;

auto outattensse = _mm_set1_ps(out_attenuation);
auto fbnegmask = _mm_cmplt_ps(_mm_set1_ps(fb_val), _mm_setzero_ps());
__m128 playramp[4], dramp[4];
if (firstblock)
{
Expand Down Expand Up @@ -686,6 +685,7 @@ void SineOscillator::process_block_internal(float pitch, float drift, float fmde
float fmpd = FM ? FMdepth.v * master_osc[k] : 0.f;
auto fmpds = _mm_set1_ps(fmpd);
auto fbv = _mm_set1_ps(FB.v);
auto fbnegmask = _mm_cmplt_ps(fbv, _mm_setzero_ps());

for (int u = 0; u < n_unison; u += 4)
{
Expand Down

0 comments on commit 5f5f73a

Please sign in to comment.