DSP performance upgrades + bugfix

This commit is contained in:
Ryzerth
2021-03-29 21:53:43 +02:00
parent b72246d769
commit 27394a091f
29 changed files with 942 additions and 355 deletions

View File

@ -219,8 +219,8 @@ private:
// Read samples here
_this->client.receiveData(inBuf, blockSize * 2);
for (int i = 0; i < blockSize; i++) {
_this->stream.writeBuf[i].q = ((double)inBuf[i * 2] - 128.0) / 128.0;
_this->stream.writeBuf[i].i = ((double)inBuf[(i * 2) + 1] - 128.0) / 128.0;
_this->stream.writeBuf[i].re = ((double)inBuf[i * 2] - 128.0) / 128.0;
_this->stream.writeBuf[i].im = ((double)inBuf[(i * 2) + 1] - 128.0) / 128.0;
}
if (!_this->stream.swap(blockSize)) { break; };
}