added: use a separate variable for fps
This commit is contained in:
parent
651f8d93e5
commit
566c19161c
2 changed files with 3 additions and 1 deletions
|
@ -48,6 +48,7 @@ CBitVis::CBitVis(int argc, char *argv[])
|
||||||
m_nrbins = 1024;
|
m_nrbins = 1024;
|
||||||
m_nrcolumns = 120;
|
m_nrcolumns = 120;
|
||||||
m_decay = 0.5;
|
m_decay = 0.5;
|
||||||
|
m_fps = 30;
|
||||||
|
|
||||||
m_fontheight = 0;
|
m_fontheight = 0;
|
||||||
InitChars();
|
InitChars();
|
||||||
|
@ -253,7 +254,7 @@ void CBitVis::ProcessAudio()
|
||||||
m_fftbuf[j] += cabsf(m_fft.m_outbuf[j]) / m_fft.m_bufsize;
|
m_fftbuf[j] += cabsf(m_fft.m_outbuf[j]) / m_fft.m_bufsize;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_samplecounter % (samplerate / 30) == 0)
|
if (m_samplecounter % (samplerate / m_fps) == 0)
|
||||||
{
|
{
|
||||||
float start = 0.0f;
|
float start = 0.0f;
|
||||||
float add = 1.0f;
|
float add = 1.0f;
|
||||||
|
|
|
@ -53,6 +53,7 @@ class CBitVis
|
||||||
int m_nrlines;
|
int m_nrlines;
|
||||||
int m_fontdisplay;
|
int m_fontdisplay;
|
||||||
float m_decay;
|
float m_decay;
|
||||||
|
int m_fps;
|
||||||
int m_fontheight;
|
int m_fontheight;
|
||||||
int m_scrolloffset;
|
int m_scrolloffset;
|
||||||
int64_t m_songupdatetime;
|
int64_t m_songupdatetime;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue