mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-02-03 09:44:01 -05:00
SoapySDR: Process number of elements that actually were returned, not requested
This commit is contained in:
parent
3388e385b6
commit
21255f8d82
@ -160,24 +160,24 @@ void SoapySDRInputThread::run()
|
||||
{
|
||||
if (m_nbChannels > 1)
|
||||
{
|
||||
callbackMIIQ(buffs, numElems*2); // size given in number of I or Q samples (2 items per sample)
|
||||
callbackMIIQ(buffs, ret*2); // size given in number of I or Q samples (2 items per sample)
|
||||
}
|
||||
else
|
||||
{
|
||||
switch (m_decimatorType)
|
||||
{
|
||||
case Decimator8:
|
||||
callbackSI8IQ((const qint8*) buffs[0], numElems*2);
|
||||
callbackSI8IQ((const qint8*) buffs[0], ret*2);
|
||||
break;
|
||||
case Decimator12:
|
||||
callbackSI12IQ((const qint16*) buffs[0], numElems*2);
|
||||
callbackSI12IQ((const qint16*) buffs[0], ret*2);
|
||||
break;
|
||||
case Decimator16:
|
||||
callbackSI16IQ((const qint16*) buffs[0], numElems*2);
|
||||
callbackSI16IQ((const qint16*) buffs[0], ret*2);
|
||||
break;
|
||||
case DecimatorFloat:
|
||||
default:
|
||||
callbackSIFIQ((const float*) buffs[0], numElems*2);
|
||||
callbackSIFIQ((const float*) buffs[0], ret*2);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -185,24 +185,24 @@ void SoapySDRInputThread::run()
|
||||
{
|
||||
if (m_nbChannels > 1)
|
||||
{
|
||||
callbackMIQI(buffs, numElems*2); // size given in number of I or Q samples (2 items per sample)
|
||||
callbackMIQI(buffs, ret*2); // size given in number of I or Q samples (2 items per sample)
|
||||
}
|
||||
else
|
||||
{
|
||||
switch (m_decimatorType)
|
||||
{
|
||||
case Decimator8:
|
||||
callbackSI8QI((const qint8*) buffs[0], numElems*2);
|
||||
callbackSI8QI((const qint8*) buffs[0], ret*2);
|
||||
break;
|
||||
case Decimator12:
|
||||
callbackSI12QI((const qint16*) buffs[0], numElems*2);
|
||||
callbackSI12QI((const qint16*) buffs[0], ret*2);
|
||||
break;
|
||||
case Decimator16:
|
||||
callbackSI16QI((const qint16*) buffs[0], numElems*2);
|
||||
callbackSI16QI((const qint16*) buffs[0], ret*2);
|
||||
break;
|
||||
case DecimatorFloat:
|
||||
default:
|
||||
callbackSIFQI((const float*) buffs[0], numElems*2);
|
||||
callbackSIFQI((const float*) buffs[0], ret*2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user