chat gpt dissapointed me

This commit is contained in:
Kuba 2023-11-15 18:25:01 +00:00
parent 76e0d5b837
commit 523c73c58c
1 changed files with 4 additions and 7 deletions

View File

@ -48,11 +48,8 @@ float carrier_38[] = {0.0, 0.8660254037844386, 0.8660254037844388, 1.22464679914
float carrier_19[] = {0.0, 0.5, 0.8660254037844386, 1.0, 0.8660254037844388, 0.5, 1.2246467991473532e-16, -0.5, -0.8660254037844384, -1.0, -0.8660254037844386, -0.5};
float carrier_31[] = {0.0, 0.7071067811865475, 1.0, 0.7071067811865476, 1.2246467991473532e-16, -0.7071067811865474, -1.0, -0.7071067811865477}; //chatgpt i have hope
int phase_38 = 0;
int phase_19 = 0;
int phase_31 = 0;
float downsample_factor;
@ -333,11 +330,11 @@ int fm_mpx_get_samples(float *mpx_buffer, int drds, float compressor_decay, floa
if(phase_38 >= 6) phase_38 = 0;
} else { // polar stereo (https://forums.stereotool.com/viewtopic.php?t=6233)
mpx_buffer[i] += 4.05*(out_left+out_right) + // Stereo sum signal (L+R)
4.05 * carrier_31[phase_31] * (out_left-out_right) + // Stereo difference signal
4.05 * carrier_38[phase_38] * (out_left-out_right) + // Stereo difference signal
//NO PIOT TONE!!!!!!!!!!!!!!!!!!!!!!!!!!!!
phase_31++;
if(phase_31 >= 8) phase_31 = 0;
phase_38++;
if(phase_38 >= 6) phase_38 = 0;
}
} else {
mpx_buffer[i] =