Sfoglia il codice sorgente

Update audio_raw_stream.c (#3624)

AudioInputCallBack has this
    audioFrequency += 1.0f;
    audioFrequency -= 1.0f;

cancels out each others
pull/3628/head
riadbettole 1 anno fa
committed by GitHub
parent
commit
31d3ed97c7
Non sono state trovate chiavi note per questa firma nel database ID Chiave GPG: 4AEE18F83AFDEB23
1 ha cambiato i file con 1 aggiunte e 2 eliminazioni
  1. +1
    -2
      examples/audio/audio_raw_stream.c

+ 1
- 2
examples/audio/audio_raw_stream.c Vedi File

@ -38,8 +38,7 @@ float sineIdx = 0.0f;
void AudioInputCallback(void *buffer, unsigned int frames)
{
audioFrequency = frequency + (audioFrequency - frequency)*0.95f;
audioFrequency += 1.0f;
audioFrequency -= 1.0f;
float incr = audioFrequency/44100.0f;
short *d = (short *)buffer;

Caricamento…
Annulla
Salva