1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-23 01:55:48 -05:00

ATV Demod: integer number of points per line is simply an Euclidean division

This commit is contained in:
f4exb 2020-08-20 08:50:44 +02:00
parent 0c04560b3c
commit cbc81b8769

View File

@ -318,15 +318,6 @@ float ATVDemodSettings::getRFBandwidthDivisor(ATVModulation modulation)
void ATVDemodSettings::getBaseValues(int sampleRate, int linesPerSecond, uint32_t& nbPointsPerLine)
{
int maxPoints = sampleRate / linesPerSecond;
int i = maxPoints;
for (; i > 0; i--)
{
if ((i * linesPerSecond) % 10 == 0) {
break;
}
}
nbPointsPerLine = i == 0 ? maxPoints : i;
nbPointsPerLine = sampleRate / linesPerSecond;
nbPointsPerLine = nbPointsPerLine == 0 ? 1 : nbPointsPerLine;
}