Unsolved Qaudioinput
-
Why int len = audio_input->bytesReady(); is not fixed in linux 64 but in windows is fixed in
1280audio format is
format.setSampleRate(16000);
format.setChannelCount(1);
format.setSampleSize(16);
format.setSampleType(QAudioFormat::SignedInt);
format.setByteOrder(QAudioFormat::LittleEndian);
format.setCodec("audio/pcm"); -
Hi @ericMath,
Why audio_input->bytesReady(); is not fixed in linux 64 but in windows is fixed in1280
Its probably to do with the underlying OS services / drivers being completely different. For example, compare then implementations for ALSA vs Windows:
- https://github.com/qt/qtmultimedia/blob/5.10/src/plugins/alsa/qalsaaudioinput.cpp#L491
- https://github.com/qt/qtmultimedia/blob/5.10/src/plugins/windowsaudio/qwindowsaudioinput.cpp#L447
Either way, you should not assume the return value to be consistent on any platform, even if it is on whatever current version of Qt you're using.
Cheers.