File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -608,7 +608,7 @@ class OutputMixer : public Print {
608608 const float factor = weights[j] / total_weights;
609609 // Read int16_t samples and convert to float
610610 for (uint16_t i = 0 ; i < samples; i++) {
611- int16_t s = 0 ;
611+ T s = 0 ;
612612 buffers[j]->read (s);
613613 temp[i] = static_cast <float >(s) * factor;
614614 }
@@ -619,7 +619,7 @@ class OutputMixer : public Print {
619619 output.resize (samples);
620620 for (size_t i = 0 ; i < samples; i++) {
621621 float v = mix_out[i];
622- output[i] = static_cast <int16_t >(v);
622+ output[i] = static_cast <T >(v);
623623 }
624624#else
625625 // Fallback: original scalar code
@@ -628,9 +628,9 @@ class OutputMixer : public Print {
628628 for (int j = 0 ; j < output_count; j++) {
629629 float factor = weights[j] / total_weights;
630630 for (int i = 0 ; i < samples; i++) {
631- int16_t sample = 0 ;
631+ T sample = 0 ;
632632 buffers[j]->read (sample);
633- output[i] += static_cast <int16_t >(factor * sample);
633+ output[i] += static_cast <T >(factor * sample);
634634 }
635635 }
636636#endif
You can’t perform that action at this time.
0 commit comments