mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-25 09:18:54 -05:00
Add explicit typecasting that was missing
This commit is contained in:
parent
277b2b4d18
commit
7f9ed6df6d
@ -864,7 +864,7 @@ void GLSpectrumGUI::setAveragingToolitp()
|
||||
{
|
||||
QString s;
|
||||
int averagingIndex = m_settings.m_averagingMode == SpectrumSettings::AvgModeNone ? 0 : m_settings.m_averagingIndex;
|
||||
float overlapFactor = (m_settings.m_fftSize - m_settings.m_fftOverlap) / m_settings.m_fftSize;
|
||||
float overlapFactor = (m_settings.m_fftSize - m_settings.m_fftOverlap) / (float)m_settings.m_fftSize;
|
||||
float averagingTime = (m_settings.m_fftSize * (SpectrumSettings::getAveragingValue(averagingIndex, m_settings.m_averagingMode) == 0 ?
|
||||
1 :
|
||||
SpectrumSettings::getAveragingValue(averagingIndex, m_settings.m_averagingMode))) / (float) m_glSpectrum->getSampleRate();
|
||||
|
@ -2735,7 +2735,7 @@ void GLSpectrumView::applyChanges()
|
||||
float timeScaleDiv = ((float)m_sampleRate / (float)m_timingRate);
|
||||
|
||||
if (m_fftSize > m_fftOverlap) {
|
||||
timeScaleDiv *= m_fftSize / (m_fftSize - m_fftOverlap);
|
||||
timeScaleDiv *= m_fftSize / (float)(m_fftSize - m_fftOverlap);
|
||||
}
|
||||
|
||||
if (!m_invertedWaterfall) {
|
||||
@ -2828,7 +2828,7 @@ void GLSpectrumView::applyChanges()
|
||||
float timeScaleDiv = ((float)m_sampleRate / (float)m_timingRate);
|
||||
|
||||
if (m_fftSize > m_fftOverlap) {
|
||||
timeScaleDiv *= m_fftSize / (m_fftSize - m_fftOverlap);
|
||||
timeScaleDiv *= m_fftSize / (float)(m_fftSize - m_fftOverlap);
|
||||
}
|
||||
|
||||
if (!m_invertedWaterfall) {
|
||||
|
Loading…
Reference in New Issue
Block a user