kopia lustrzana https://gitlab.com/eliggett/wfview
Merge branch 'master' into shuttle
commit
93f18fae9e
|
@ -7,4 +7,6 @@ wfview-debug
|
|||
wfserver-debug
|
||||
wfview-release
|
||||
wfserver-release
|
||||
ui_*
|
||||
ui_*
|
||||
portaudio_x86.dll
|
||||
qcustomplot2.dll
|
||||
|
|
26
WHATSNEW
26
WHATSNEW
|
@ -30,7 +30,31 @@ The following highlights are in this 1.51-release ince v1.50:
|
|||
Add AR Cluster support
|
||||
+1.54 Various wfserver fixes
|
||||
logging using termbin edge case fix
|
||||
|
||||
+1.55 Compiles with QT5 and 6 now
|
||||
Many audio-fixes
|
||||
Fix wfserver device detection
|
||||
Prevent memory leak on exit
|
||||
Dawid Szymanski - SQ6EMM/SN6M 'standardHFfix'; fixed missing 160m band
|
||||
Support hotplug audio on QT6+
|
||||
Remove Exception from RT audio as it doesn't exist in newer versions of RTAudio
|
||||
Tidy-up device enumeration for Qt audio
|
||||
Log enumeration of audio devices
|
||||
Fix codec selection issue in both QT5 and 6
|
||||
Make sure compilation with QT5 still works
|
||||
+1.56 Rename in/out Formats to avoid confusion
|
||||
Fix all audio formats and some compile warnings!
|
||||
Add function to handle connect/disconnect
|
||||
Add option of popup alert
|
||||
Change serial port signal for QT6.
|
||||
Various audio fixes (needs checking with Qt5)
|
||||
Fix portaudio
|
||||
Fix for QTAudio when using QT6 and above.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Notes:
|
||||
|
||||
- We know about high CPU usage on RPi.
|
||||
|
|
|
@ -6,33 +6,41 @@ audioConverter::audioConverter(QObject* parent) : QObject(parent)
|
|||
{
|
||||
}
|
||||
|
||||
bool audioConverter::init(QAudioFormat inFormat, QAudioFormat outFormat, quint8 opusComplexity, quint8 resampleQuality)
|
||||
bool audioConverter::init(QAudioFormat inFormat, codecType inCodec, QAudioFormat outFormat, codecType outCodec, quint8 opusComplexity, quint8 resampleQuality)
|
||||
{
|
||||
|
||||
this->inFormat = inFormat;
|
||||
this->outFormat = outFormat;
|
||||
this->opusComplexity = opusComplexity;
|
||||
this->inCodec = inCodec;
|
||||
this->outFormat = outFormat;
|
||||
this->outCodec = outCodec;
|
||||
this->opusComplexity = opusComplexity;
|
||||
this->resampleQuality = resampleQuality;
|
||||
|
||||
qInfo(logAudioConverter) << "Starting audioConverter() Input:" << inFormat.channelCount() << "Channels of" << inFormat.codec() << inFormat.sampleRate() << inFormat.sampleType() << inFormat.sampleSize() <<
|
||||
"Output:" << outFormat.channelCount() << "Channels of" << outFormat.codec() << outFormat.sampleRate() << outFormat.sampleType() << outFormat.sampleSize();
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qInfo(logAudioConverter) << "Starting audioConverter() Input:" << inFormat.channelCount() << "Channels of" << inCodec << inFormat.sampleRate() << inFormat.sampleType() << inFormat.sampleSize() <<
|
||||
"Output:" << outFormat.channelCount() << "Channels of" << outCodec << outFormat.sampleRate() << outFormat.sampleType() << outFormat.sampleSize();
|
||||
|
||||
if (inFormat.byteOrder() != outFormat.byteOrder()) {
|
||||
if (inFormat.byteOrder() != outFormat.byteOrder()) {
|
||||
qInfo(logAudioConverter) << "Byteorder mismatch in:" << inFormat.byteOrder() << "out:" << outFormat.byteOrder();
|
||||
}
|
||||
#else
|
||||
qInfo(logAudioConverter) << "Starting audioConverter() Input:" << inFormat.channelCount() << "Channels of" << inCodec << inFormat.sampleRate() << inFormat.sampleFormat() <<
|
||||
"Output:" << outFormat.channelCount() << "Channels of" << outCodec << outFormat.sampleRate() << outFormat.sampleFormat();
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
if (inFormat.codec() == "audio/opus")
|
||||
{
|
||||
// Create instance of opus decoder
|
||||
int opus_err = 0;
|
||||
opusDecoder = opus_decoder_create(inFormat.sampleRate(), inFormat.channelCount(), &opus_err);
|
||||
qInfo(logAudioConverter()) << "Creating opus decoder: " << opus_strerror(opus_err);
|
||||
}
|
||||
if (inCodec == OPUS)
|
||||
{
|
||||
// Create instance of opus decoder
|
||||
int opus_err = 0;
|
||||
opusDecoder = opus_decoder_create(inFormat.sampleRate(), inFormat.channelCount(), &opus_err);
|
||||
qInfo(logAudioConverter()) << "Creating opus decoder: " << opus_strerror(opus_err);
|
||||
}
|
||||
|
||||
if (outFormat.codec() == "audio/opus")
|
||||
{
|
||||
// Create instance of opus encoder
|
||||
if (outCodec == OPUS)
|
||||
{
|
||||
// Create instance of opus encoder
|
||||
int opus_err = 0;
|
||||
opusEncoder = opus_encoder_create(outFormat.sampleRate(), outFormat.channelCount(), OPUS_APPLICATION_AUDIO, &opus_err);
|
||||
//opus_encoder_ctl(opusEncoder, OPUS_SET_LSB_DEPTH(16));
|
||||
|
@ -60,8 +68,13 @@ bool audioConverter::init(QAudioFormat inFormat, QAudioFormat outFormat, quint8
|
|||
audioConverter::~audioConverter()
|
||||
{
|
||||
|
||||
qInfo(logAudioConverter) << "Closing audioConverter() Input:" << inFormat.channelCount() << "Channels of" << inFormat.codec() << inFormat.sampleRate() << inFormat.sampleType() << inFormat.sampleSize() <<
|
||||
"Output:" << outFormat.channelCount() << "Channels of" << outFormat.codec() << outFormat.sampleRate() << outFormat.sampleType() << outFormat.sampleSize();
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qInfo(logAudioConverter) << "Closing audioConverter() Input:" << inFormat.channelCount() << "Channels of" << inCodec << inFormat.sampleRate() << inFormat.sampleType() << inFormat.sampleSize() <<
|
||||
"Output:" << outFormat.channelCount() << "Channels of" << outCodec << outFormat.sampleRate() << outFormat.sampleType() << outFormat.sampleSize();
|
||||
#else
|
||||
qInfo(logAudioConverter) << "Closing audioConverter() Input:" << inFormat.channelCount() << "Channels of" << inCodec << inFormat.sampleRate() << inFormat.sampleFormat() <<
|
||||
"Output:" << outFormat.channelCount() << "Channels of" << outCodec << outFormat.sampleRate() << outFormat.sampleFormat();
|
||||
#endif
|
||||
|
||||
if (opusEncoder != Q_NULLPTR) {
|
||||
qInfo(logAudioConverter()) << "Destroying opus encoder";
|
||||
|
@ -87,7 +100,7 @@ bool audioConverter::convert(audioPacket audio)
|
|||
if (audio.data.size() > 0)
|
||||
{
|
||||
|
||||
if (inFormat.codec() == "audio/opus")
|
||||
if (inCodec == OPUS)
|
||||
{
|
||||
unsigned char* in = (unsigned char*)audio.data.data();
|
||||
|
||||
|
@ -110,7 +123,7 @@ bool audioConverter::convert(audioPacket audio)
|
|||
audio.data.clear();
|
||||
audio.data = outPacket; // Replace incoming data with converted.
|
||||
}
|
||||
else if (inFormat.codec() == "audio/PCMU")
|
||||
else if (inCodec == PCMU)
|
||||
{
|
||||
// Current packet is "technically" 8bit so need to create a new buffer that is 16bit
|
||||
QByteArray outPacket((int)audio.data.length() * 2, (char)0xff);
|
||||
|
@ -125,33 +138,49 @@ bool audioConverter::convert(audioPacket audio)
|
|||
}
|
||||
|
||||
Eigen::VectorXf samplesF;
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
if (inFormat.sampleType() == QAudioFormat::SignedInt && inFormat.sampleSize() == 32)
|
||||
#else
|
||||
if (inFormat.sampleFormat() == QAudioFormat::Int32)
|
||||
#endif
|
||||
{
|
||||
Eigen::Ref<VectorXint32> samplesI = Eigen::Map<VectorXint32>(reinterpret_cast<qint32*>(audio.data.data()), audio.data.size() / int(sizeof(qint32)));
|
||||
samplesF = samplesI.cast<float>() / float(std::numeric_limits<qint32>::max());
|
||||
}
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
else if (inFormat.sampleType() == QAudioFormat::SignedInt && inFormat.sampleSize() == 16)
|
||||
#else
|
||||
else if (inFormat.sampleFormat() == QAudioFormat::Int16)
|
||||
#endif
|
||||
{
|
||||
Eigen::Ref<VectorXint16> samplesI = Eigen::Map<VectorXint16>(reinterpret_cast<qint16*>(audio.data.data()), audio.data.size() / int(sizeof(qint16)));
|
||||
samplesF = samplesI.cast<float>() / float(std::numeric_limits<qint16>::max());
|
||||
}
|
||||
else if (inFormat.sampleType() == QAudioFormat::SignedInt && inFormat.sampleSize() == 8)
|
||||
{
|
||||
Eigen::Ref<VectorXint8> samplesI = Eigen::Map<VectorXint8>(reinterpret_cast<qint8*>(audio.data.data()), audio.data.size() / int(sizeof(qint8)));
|
||||
samplesF = samplesI.cast<float>() / float(std::numeric_limits<qint8>::max());;
|
||||
}
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
else if (inFormat.sampleType() == QAudioFormat::UnSignedInt && inFormat.sampleSize() == 8)
|
||||
#else
|
||||
else if (inFormat.sampleFormat() == QAudioFormat::UInt8)
|
||||
#endif
|
||||
{
|
||||
Eigen::Ref<VectorXuint8> samplesI = Eigen::Map<VectorXuint8>(reinterpret_cast<quint8*>(audio.data.data()), audio.data.size() / int(sizeof(quint8)));
|
||||
samplesF = samplesI.cast<float>() / float(std::numeric_limits<quint8>::max());;
|
||||
}
|
||||
else if (inFormat.sampleType() == QAudioFormat::Float) {
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
else if (inFormat.sampleType() == QAudioFormat::Float)
|
||||
#else
|
||||
else if (inFormat.sampleFormat() == QAudioFormat::Float)
|
||||
#endif
|
||||
{
|
||||
|
||||
samplesF = Eigen::Map<Eigen::VectorXf>(reinterpret_cast<float*>(audio.data.data()), audio.data.size() / int(sizeof(float)));
|
||||
}
|
||||
else
|
||||
{
|
||||
qInfo(logAudio()) << "Unsupported Input Sample Type:" << inFormat.sampleType() << "Size:" << inFormat.sampleSize();
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qInfo(logAudio()) << "Unsupported Input Sample Type:" << inFormat.sampleType() << "Size:" << inFormat.sampleSize();
|
||||
#else
|
||||
qInfo(logAudio()) << "Unsupported Input Sample Format:" << inFormat.sampleFormat();
|
||||
#endif
|
||||
}
|
||||
|
||||
if (samplesF.size() > 0)
|
||||
|
@ -218,7 +247,7 @@ bool audioConverter::convert(audioPacket audio)
|
|||
If output is Opus so encode it now, don't do any more conversion on the output of Opus.
|
||||
*/
|
||||
|
||||
if (outFormat.codec() == "audio/opus")
|
||||
if (outCodec == OPUS)
|
||||
{
|
||||
float* in = (float*)samplesF.data();
|
||||
QByteArray outPacket(1275, (char)0xff); // Preset the output buffer size to MAXIMUM possible Opus frame size
|
||||
|
@ -246,45 +275,58 @@ bool audioConverter::convert(audioPacket audio)
|
|||
*/
|
||||
audio.data.clear();
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
if (outFormat.sampleType() == QAudioFormat::UnSignedInt && outFormat.sampleSize() == 8)
|
||||
#else
|
||||
if (outFormat.sampleFormat() == QAudioFormat::UInt8)
|
||||
#endif
|
||||
{
|
||||
Eigen::VectorXf samplesITemp = samplesF * float(std::numeric_limits<qint8>::max());
|
||||
samplesITemp.array() += 127;
|
||||
VectorXuint8 samplesI = samplesITemp.cast<quint8>();
|
||||
audio.data = QByteArray(reinterpret_cast<char*>(samplesI.data()), int(samplesI.size()) * int(sizeof(quint8)));
|
||||
}
|
||||
else if (outFormat.sampleType() == QAudioFormat::SignedInt && outFormat.sampleSize() == 8)
|
||||
{
|
||||
Eigen::VectorXf samplesITemp = samplesF * float(std::numeric_limits<qint8>::max());
|
||||
VectorXint8 samplesI = samplesITemp.cast<qint8>();
|
||||
audio.data = QByteArray(reinterpret_cast<char*>(samplesI.data()), int(samplesI.size()) * int(sizeof(qint8)));
|
||||
}
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
else if (outFormat.sampleType() == QAudioFormat::SignedInt && outFormat.sampleSize() == 16)
|
||||
#else
|
||||
else if (outFormat.sampleFormat() == QAudioFormat::Int16)
|
||||
#endif
|
||||
{
|
||||
Eigen::VectorXf samplesITemp = samplesF * float(std::numeric_limits<qint16>::max());
|
||||
VectorXint16 samplesI = samplesITemp.cast<qint16>();
|
||||
audio.data = QByteArray(reinterpret_cast<char*>(samplesI.data()), int(samplesI.size()) * int(sizeof(qint16)));
|
||||
}
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
else if (outFormat.sampleType() == QAudioFormat::SignedInt && outFormat.sampleSize() == 32)
|
||||
#else
|
||||
else if (outFormat.sampleFormat() == QAudioFormat::Int32)
|
||||
#endif
|
||||
{
|
||||
Eigen::VectorXf samplesITemp = samplesF * float(std::numeric_limits<qint32>::max());
|
||||
VectorXint32 samplesI = samplesITemp.cast<qint32>();
|
||||
audio.data = QByteArray(reinterpret_cast<char*>(samplesI.data()), int(samplesI.size()) * int(sizeof(qint32)));
|
||||
}
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
else if (outFormat.sampleType() == QAudioFormat::Float)
|
||||
#else
|
||||
else if (outFormat.sampleFormat() == QAudioFormat::Float)
|
||||
#endif
|
||||
{
|
||||
audio.data = QByteArray(reinterpret_cast<char*>(samplesF.data()), int(samplesF.size()) * int(sizeof(float)));
|
||||
}
|
||||
else {
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qInfo(logAudio()) << "Unsupported Output Sample Type:" << outFormat.sampleType() << "Size:" << outFormat.sampleSize();
|
||||
#else
|
||||
qInfo(logAudio()) << "Unsupported Output Sample Type:" << outFormat.sampleFormat();
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
As we currently don't have a float based uLaw encoder, this must be done
|
||||
after all other conversion has taken place.
|
||||
*/
|
||||
|
||||
if (outFormat.codec() == "audio/PCMU")
|
||||
if (outCodec == PCMU)
|
||||
{
|
||||
QByteArray outPacket((int)audio.data.length() / 2, (char)0xff);
|
||||
qint16* in = (qint16*)audio.data.data();
|
||||
|
|
|
@ -6,7 +6,17 @@
|
|||
#include <QMap>
|
||||
#include <QDebug>
|
||||
#include <QAudioFormat>
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
#include <QAudioDeviceInfo>
|
||||
#include <QAudioInput>
|
||||
#include <QAudioOutput>
|
||||
#else
|
||||
#include <QMediaDevices>
|
||||
#include <QAudioDevice>
|
||||
#include <QAudioSource>
|
||||
#include <QAudioSink>
|
||||
#endif
|
||||
|
||||
/* Opus and Eigen */
|
||||
#ifdef Q_OS_WIN
|
||||
|
@ -42,7 +52,11 @@ struct audioSetup {
|
|||
bool ulaw = false;
|
||||
bool isinput;
|
||||
quint32 sampleRate;
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
QAudioDeviceInfo port;
|
||||
#else
|
||||
QAudioDevice port;
|
||||
#endif
|
||||
int portInt;
|
||||
quint8 resampleQuality;
|
||||
unsigned char localAFgain;
|
||||
|
@ -59,7 +73,7 @@ public:
|
|||
~audioConverter();
|
||||
|
||||
public slots:
|
||||
bool init(QAudioFormat inFormat, QAudioFormat outFormat, quint8 opusComplexity, quint8 resampleQuality);
|
||||
bool init(QAudioFormat inFormat, codecType inCodec, QAudioFormat outFormat, codecType outCodec, quint8 opusComplexity, quint8 resampleQuality);
|
||||
bool convert(audioPacket audio);
|
||||
|
||||
signals:
|
||||
|
@ -75,6 +89,8 @@ protected:
|
|||
quint8 resampleQuality = 4;
|
||||
double resampleRatio=1.0; // Default resample ratio is 1:1
|
||||
quint32 lastAudioSequence;
|
||||
codecType inCodec;
|
||||
codecType outCodec;
|
||||
};
|
||||
|
||||
|
||||
|
@ -99,21 +115,31 @@ static inline QAudioFormat toQAudioFormat(quint8 codec, quint32 sampleRate)
|
|||
0x40 Opus 1ch
|
||||
0x80 Opus 2ch
|
||||
*/
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
format.setByteOrder(QAudioFormat::LittleEndian);
|
||||
format.setCodec("audio/pcm");
|
||||
#endif
|
||||
|
||||
format.setSampleRate(sampleRate);
|
||||
|
||||
if (codec == 0x01 || codec == 0x20) {
|
||||
/* Set sample to be what is expected by the encoder and the output of the decoder */
|
||||
format.setSampleSize(16);
|
||||
format.setSampleType(QAudioFormat::SignedInt);
|
||||
format.setCodec("audio/PCMU");
|
||||
}
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
format.setSampleSize(16);
|
||||
format.setSampleType(QAudioFormat::SignedInt);
|
||||
format.setCodec("audio/PCMU");
|
||||
#else
|
||||
format.setSampleFormat(QAudioFormat::Int16);
|
||||
#endif
|
||||
}
|
||||
|
||||
if (codec == 0x02 || codec == 0x08) {
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
format.setSampleSize(8);
|
||||
format.setSampleType(QAudioFormat::UnSignedInt);
|
||||
#else
|
||||
format.setSampleFormat(QAudioFormat::UInt8);
|
||||
#endif
|
||||
}
|
||||
if (codec == 0x08 || codec == 0x10 || codec == 0x20 || codec == 0x80) {
|
||||
format.setChannelCount(2);
|
||||
|
@ -122,14 +148,22 @@ static inline QAudioFormat toQAudioFormat(quint8 codec, quint32 sampleRate)
|
|||
}
|
||||
|
||||
if (codec == 0x04 || codec == 0x10) {
|
||||
format.setSampleSize(16);
|
||||
format.setSampleType(QAudioFormat::SignedInt);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
format.setSampleSize(16);
|
||||
format.setSampleType(QAudioFormat::SignedInt);
|
||||
#else
|
||||
format.setSampleFormat(QAudioFormat::Int16);
|
||||
#endif
|
||||
}
|
||||
|
||||
if (codec == 0x40 || codec == 0x80) {
|
||||
format.setSampleSize(32);
|
||||
format.setSampleType(QAudioFormat::Float);
|
||||
format.setCodec("audio/opus");
|
||||
if (codec == 0x40 || codec == 0x80) {
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
format.setSampleSize(32);
|
||||
format.setSampleType(QAudioFormat::Float);
|
||||
format.setCodec("audio/opus");
|
||||
#else
|
||||
format.setSampleFormat(QAudioFormat::Float);
|
||||
#endif
|
||||
}
|
||||
|
||||
return format;
|
||||
|
|
|
@ -0,0 +1,448 @@
|
|||
/*
|
||||
wfview class to enumerate audio devices and assist with matching saved devices
|
||||
|
||||
Written by Phil Taylor M0VSE Nov 2022.
|
||||
|
||||
*/
|
||||
|
||||
#include "audiodevices.h"
|
||||
#include "logcategories.h"
|
||||
|
||||
audioDevices::audioDevices(audioType type, QFontMetrics fm, QObject* parent) :
|
||||
QObject(parent),
|
||||
system(type),
|
||||
fm(fm)
|
||||
{
|
||||
|
||||
#if (QT_VERSION >= QT_VERSION_CHECK(6,0,0))
|
||||
connect(&mediaDevices, &QMediaDevices::audioInputsChanged, this, &audioDevices::enumerate);
|
||||
connect(&mediaDevices, &QMediaDevices::audioOutputsChanged, this, &audioDevices::enumerate);
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
|
||||
void audioDevices::enumerate()
|
||||
{
|
||||
numInputDevices = 0;
|
||||
numOutputDevices = 0;
|
||||
numCharsIn = 0;
|
||||
numCharsOut = 0;
|
||||
inputs.clear();
|
||||
outputs.clear();
|
||||
|
||||
switch (system)
|
||||
{
|
||||
case qtAudio:
|
||||
{
|
||||
Pa_Terminate();
|
||||
|
||||
qInfo(logAudio()) << "Audio device(s) found (*=default)";
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
foreach(const QAudioDeviceInfo & deviceInfo, QAudioDeviceInfo::availableDevices(QAudio::AudioInput))
|
||||
#else
|
||||
const auto audioInputs = mediaDevices.audioInputs();
|
||||
for (const QAudioDevice& deviceInfo : audioInputs)
|
||||
#endif
|
||||
{
|
||||
bool isDefault = false;
|
||||
if (numInputDevices == 0) {
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
defaultInputDeviceName = QString(deviceInfo.deviceName());
|
||||
#else
|
||||
defaultInputDeviceName = QString(deviceInfo.description());
|
||||
#endif
|
||||
}
|
||||
#if (defined(Q_OS_WIN) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
if (deviceInfo.realm() == audioApi || audioApi == "") {
|
||||
#endif
|
||||
/* Append Input Device Here */
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
if (deviceInfo.deviceName() == defaultInputDeviceName) {
|
||||
#else
|
||||
if (deviceInfo.description() == defaultInputDeviceName) {
|
||||
#endif
|
||||
isDefault = true;
|
||||
}
|
||||
|
||||
#if ((QT_VERSION >= QT_VERSION_CHECK(5,15,0)) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
inputs.append(audioDevice(deviceInfo.deviceName(), deviceInfo, deviceInfo.realm(), isDefault));
|
||||
qInfo(logAudio()) << (deviceInfo.deviceName() == defaultInputDeviceName ? "*" : " ") <<
|
||||
"(" << numInputDevices <<" " << deviceInfo.realm() << ") Input Device : " <<
|
||||
deviceInfo.deviceName();
|
||||
#elif (QT_VERSION < QT_VERSION_CHECK(5,15,0))
|
||||
inputs.append(audioDevice(deviceInfo.deviceName(), deviceInfo, "", isDefault));
|
||||
qInfo(logAudio()) << (deviceInfo.deviceName() == defaultInputDeviceName ? "*" : " ") <<
|
||||
"(" << numInputDevices << ") Input Device : " << deviceInfo.deviceName();
|
||||
#else
|
||||
inputs.append(audioDevice(deviceInfo.description(), deviceInfo, "", isDefault));
|
||||
qInfo(logAudio()) << (deviceInfo.description() == defaultInputDeviceName ? "*" : " ") <<
|
||||
"(" << numInputDevices << ") Input Device : " << deviceInfo.description();
|
||||
#endif
|
||||
|
||||
#ifndef BUILD_WFSERVER
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
if (fm.boundingRect(deviceInfo.deviceName()).width() > numCharsIn)
|
||||
numCharsIn = fm.boundingRect(deviceInfo.deviceName()).width();
|
||||
#else
|
||||
if (fm.boundingRect(deviceInfo.description()).width() > numCharsIn)
|
||||
numCharsIn = fm.boundingRect(deviceInfo.description()).width();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if (defined(Q_OS_WIN) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
}
|
||||
#endif
|
||||
numInputDevices++;
|
||||
}
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
foreach(const QAudioDeviceInfo & deviceInfo, QAudioDeviceInfo::availableDevices(QAudio::AudioOutput))
|
||||
#else
|
||||
const auto audioOutputs = mediaDevices.audioOutputs();
|
||||
for (const QAudioDevice& deviceInfo : audioOutputs)
|
||||
#endif
|
||||
{
|
||||
bool isDefault = false;
|
||||
if (numOutputDevices == 0)
|
||||
{
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
defaultOutputDeviceName = QString(deviceInfo.deviceName());
|
||||
#else
|
||||
defaultOutputDeviceName = QString(deviceInfo.description());
|
||||
#endif
|
||||
}
|
||||
|
||||
#if (defined(Q_OS_WIN) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
if (deviceInfo.realm() == "wasapi") {
|
||||
#endif
|
||||
/* Append Output Device Here */
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
if (deviceInfo.deviceName() == defaultOutputDeviceName) {
|
||||
#else
|
||||
if (deviceInfo.description() == defaultOutputDeviceName) {
|
||||
#endif
|
||||
isDefault = true;
|
||||
}
|
||||
|
||||
#if ((QT_VERSION >= QT_VERSION_CHECK(5,15,0)) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
outputs.append(audioDevice(deviceInfo.deviceName(), deviceInfo, deviceInfo.realm() , isDefault));
|
||||
qInfo(logAudio()) << (deviceInfo.deviceName() == defaultOutputDeviceName ? "*" : " ") <<
|
||||
"(" << numOutputDevices << " " << deviceInfo.realm() << ") Output Device : " <<
|
||||
deviceInfo.deviceName();
|
||||
#elif (QT_VERSION < QT_VERSION_CHECK(5,15,0))
|
||||
outputs.append(audioDevice(deviceInfo.deviceName(), deviceInfo, "", isDefault));
|
||||
qInfo(logAudio()) << (deviceInfo.deviceName() == defaultOutputDeviceName ? "*" : " ") <<
|
||||
"(" << numOutputDevices << ") Output Device : " << deviceInfo.deviceName();
|
||||
#else
|
||||
outputs.append(audioDevice(deviceInfo.description(), deviceInfo, "", isDefault));
|
||||
qInfo(logAudio()) << (deviceInfo.description() == defaultOutputDeviceName ? "*" : " ") <<
|
||||
"(" << numOutputDevices << ") Output Device : " << deviceInfo.description();
|
||||
#endif
|
||||
|
||||
#ifndef BUILD_WFSERVER
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
if (fm.boundingRect(deviceInfo.deviceName()).width() > numCharsOut)
|
||||
numCharsOut = fm.boundingRect(deviceInfo.deviceName()).width();
|
||||
#else
|
||||
if (fm.boundingRect(deviceInfo.description()).width() > numCharsOut)
|
||||
numCharsOut = fm.boundingRect(deviceInfo.description()).width();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if (defined(Q_OS_WIN) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
}
|
||||
#endif
|
||||
numOutputDevices++;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case portAudio:
|
||||
{
|
||||
PaError err;
|
||||
|
||||
err = Pa_Initialize();
|
||||
|
||||
if (err != paNoError)
|
||||
{
|
||||
qInfo(logAudio()) << "ERROR: Cannot initialize Portaudio";
|
||||
return;
|
||||
}
|
||||
|
||||
qInfo(logAudio()) << "PortAudio version: " << Pa_GetVersionInfo()->versionText;
|
||||
|
||||
int numDevices = Pa_GetDeviceCount();
|
||||
qInfo(logAudio()) << "Pa_CountDevices returned" << numDevices << "audio device(s) (*=default)";
|
||||
|
||||
|
||||
const PaDeviceInfo* info;
|
||||
for (int i = 0; i < numDevices; i++)
|
||||
{
|
||||
info = Pa_GetDeviceInfo(i);
|
||||
if (info->maxInputChannels > 0) {
|
||||
bool isDefault = false;
|
||||
numInputDevices++;
|
||||
qInfo(logAudio()) << (i == Pa_GetDefaultInputDevice() ? "*" : " ") << "(" << i << ") Input Device : " << QString(info->name);
|
||||
if (i == Pa_GetDefaultInputDevice()) {
|
||||
defaultInputDeviceName = info->name;
|
||||
isDefault = true;
|
||||
}
|
||||
inputs.append(audioDevice(QString(info->name), i,isDefault));
|
||||
#ifndef BUILD_WFSERVER
|
||||
if (fm.boundingRect(QString(info->name)).width() > numCharsIn)
|
||||
numCharsIn = fm.boundingRect(QString(info->name)).width();
|
||||
#endif
|
||||
|
||||
}
|
||||
if (info->maxOutputChannels > 0) {
|
||||
bool isDefault = false;
|
||||
numOutputDevices++;
|
||||
qInfo(logAudio()) << (i == Pa_GetDefaultOutputDevice() ? "*" : " ") << "(" << i << ") Output Device : " << QString(info->name);
|
||||
if (i == Pa_GetDefaultOutputDevice()) {
|
||||
defaultOutputDeviceName = info->name;
|
||||
isDefault = true;
|
||||
}
|
||||
outputs.append(audioDevice(QString(info->name), i,isDefault));
|
||||
#ifndef BUILD_WFSERVER
|
||||
if (fm.boundingRect(QString(info->name)).width() > numCharsOut)
|
||||
numCharsOut = fm.boundingRect(QString(info->name)).width();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case rtAudio:
|
||||
{
|
||||
Pa_Terminate();
|
||||
|
||||
#if defined(Q_OS_LINUX)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::LINUX_ALSA);
|
||||
#elif defined(Q_OS_WIN)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::WINDOWS_WASAPI);
|
||||
#elif defined(Q_OS_MACX)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::MACOSX_CORE);
|
||||
#endif
|
||||
|
||||
|
||||
// Enumerate audio devices, need to do before settings are loaded.
|
||||
std::map<int, std::string> apiMap;
|
||||
apiMap[RtAudio::MACOSX_CORE] = "OS-X Core Audio";
|
||||
apiMap[RtAudio::WINDOWS_ASIO] = "Windows ASIO";
|
||||
apiMap[RtAudio::WINDOWS_DS] = "Windows DirectSound";
|
||||
apiMap[RtAudio::WINDOWS_WASAPI] = "Windows WASAPI";
|
||||
apiMap[RtAudio::UNIX_JACK] = "Jack Client";
|
||||
apiMap[RtAudio::LINUX_ALSA] = "Linux ALSA";
|
||||
apiMap[RtAudio::LINUX_PULSE] = "Linux PulseAudio";
|
||||
apiMap[RtAudio::LINUX_OSS] = "Linux OSS";
|
||||
apiMap[RtAudio::RTAUDIO_DUMMY] = "RtAudio Dummy";
|
||||
|
||||
std::vector< RtAudio::Api > apis;
|
||||
RtAudio::getCompiledApi(apis);
|
||||
|
||||
qInfo(logAudio()) << "RtAudio Version " << QString::fromStdString(RtAudio::getVersion());
|
||||
|
||||
qInfo(logAudio()) << "Compiled APIs:";
|
||||
for (unsigned int i = 0; i < apis.size(); i++) {
|
||||
qInfo(logAudio()) << " " << QString::fromStdString(apiMap[apis[i]]);
|
||||
}
|
||||
|
||||
RtAudio::DeviceInfo info;
|
||||
|
||||
qInfo(logAudio()) << "Current API: " << QString::fromStdString(apiMap[audio->getCurrentApi()]);
|
||||
|
||||
unsigned int devicecount = audio->getDeviceCount();
|
||||
|
||||
#if (RTAUDIO_VERSION_MAJOR > 5)
|
||||
std::vector<unsigned int> devices = audio->getDeviceIds();
|
||||
#endif
|
||||
qInfo(logAudio()) << "Found:" << devicecount << " audio device(s) (*=default)";
|
||||
|
||||
for (unsigned int i = 1; i < devicecount; i++) {
|
||||
|
||||
#if (RTAUDIO_VERSION_MAJOR > 5)
|
||||
info = audio->getDeviceInfo(devices[i]);
|
||||
#else
|
||||
info = audio->getDeviceInfo(i);
|
||||
#endif
|
||||
if (info.inputChannels > 0) {
|
||||
bool isDefault = false;
|
||||
qInfo(logAudio()) << (info.isDefaultInput ? "*" : " ") << "(" << i << ") Input Device : " << QString::fromStdString(info.name);
|
||||
numInputDevices++;
|
||||
|
||||
if (info.isDefaultInput) {
|
||||
defaultInputDeviceName = QString::fromStdString(info.name);
|
||||
isDefault = true;
|
||||
}
|
||||
|
||||
#if (RTAUDIO_VERSION_MAJOR > 5)
|
||||
inputs.append(audioDevice(QString::fromStdString(info.name), devices[i], isDefault));
|
||||
#else
|
||||
inputs.append(audioDevice(QString::fromStdString(info.name), i, isDefault));
|
||||
#endif
|
||||
|
||||
#ifndef BUILD_WFSERVER
|
||||
if (fm.boundingRect(QString::fromStdString(info.name)).width() > numCharsIn)
|
||||
numCharsIn = fm.boundingRect(QString::fromStdString(info.name)).width();
|
||||
#endif
|
||||
|
||||
}
|
||||
if (info.outputChannels > 0) {
|
||||
bool isDefault = false;
|
||||
qInfo(logAudio()) << (info.isDefaultOutput ? "*" : " ") << "(" << i << ") Output Device : " << QString::fromStdString(info.name);
|
||||
numOutputDevices++;
|
||||
|
||||
if (info.isDefaultOutput) {
|
||||
defaultOutputDeviceName = QString::fromStdString(info.name);
|
||||
isDefault = true;
|
||||
}
|
||||
|
||||
#if (RTAUDIO_VERSION_MAJOR > 5)
|
||||
outputs.append(audioDevice(QString::fromStdString(info.name), devices[i], isDefault));
|
||||
#else
|
||||
outputs.append(audioDevice(QString::fromStdString(info.name), i, isDefault));
|
||||
#endif
|
||||
|
||||
#ifndef BUILD_WFSERVER
|
||||
if (fm.boundingRect(QString::fromStdString(info.name)).width() > numCharsOut)
|
||||
numCharsOut = fm.boundingRect(QString::fromStdString(info.name)).width();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
delete audio;
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
emit updated();
|
||||
|
||||
}
|
||||
|
||||
audioDevices::~audioDevices()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QStringList audioDevices::getInputs()
|
||||
{
|
||||
QStringList list;
|
||||
foreach(const audioDevice input, inputs) {
|
||||
list.append(input.name);
|
||||
}
|
||||
|
||||
return list;
|
||||
}
|
||||
|
||||
QStringList audioDevices::getOutputs()
|
||||
{
|
||||
QStringList list;
|
||||
foreach(const audioDevice output, outputs) {
|
||||
list.append(output.name);
|
||||
}
|
||||
|
||||
return list;
|
||||
}
|
||||
|
||||
int audioDevices::findInput(QString type, QString name)
|
||||
{
|
||||
int ret = -1;
|
||||
int def = -1;
|
||||
int usb = -1;
|
||||
QString msg;
|
||||
QTextStream s(&msg);
|
||||
for (int f = 0; f < inputs.size(); f++)
|
||||
{
|
||||
//qInfo(logAudio()) << "Found device" << inputs[f].name;
|
||||
if (inputs[f].name.startsWith(name)) {
|
||||
s << type << " Audio input device " << name << " found! ";
|
||||
ret = f;
|
||||
}
|
||||
if (inputs[f].isDefault == true)
|
||||
{
|
||||
def = f;
|
||||
}
|
||||
if (inputs[f].name.toUpper().contains("USB")) {
|
||||
// This is a USB device...
|
||||
usb = f;
|
||||
}
|
||||
}
|
||||
|
||||
if (ret == -1)
|
||||
{
|
||||
s << type << " Audio input device " << name << " Not found: ";
|
||||
|
||||
if (inputs.size() == 1) {
|
||||
s << "Selecting first device " << inputs[0].name;
|
||||
ret = 0;
|
||||
}
|
||||
else if (usb > -1 && type != "Client")
|
||||
{
|
||||
s << " Selecting found USB device " << inputs[usb].name;
|
||||
ret = usb;
|
||||
}
|
||||
else if (def > -1)
|
||||
{
|
||||
s << " Selecting default device " << inputs[def].name;
|
||||
ret = def;
|
||||
}
|
||||
else {
|
||||
s << " and no default device found, aborting!";
|
||||
}
|
||||
}
|
||||
|
||||
qInfo(logAudio()) << msg;
|
||||
return ret;
|
||||
}
|
||||
|
||||
int audioDevices::findOutput(QString type, QString name)
|
||||
{
|
||||
int ret = -1;
|
||||
int def = -1;
|
||||
int usb = -1;
|
||||
QString msg;
|
||||
QTextStream s(&msg);
|
||||
for (int f = 0; f < outputs.size(); f++)
|
||||
{
|
||||
//qInfo(logAudio()) << "Found device" << outputs[f].name;
|
||||
if (outputs[f].name.startsWith(name)) {
|
||||
ret = f;
|
||||
s << type << " Audio output device " << name << " found! ";
|
||||
}
|
||||
if (outputs[f].isDefault == true)
|
||||
{
|
||||
def = f;
|
||||
}
|
||||
if (outputs[f].name.toUpper().contains("USB")) {
|
||||
// This is a USB device...
|
||||
usb = f;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if (ret == -1)
|
||||
{
|
||||
s << type << " Audio output device " << name << " Not found: ";
|
||||
|
||||
if (outputs.size() == 1) {
|
||||
s << " Selecting first device " << outputs[0].name;
|
||||
ret = 0;
|
||||
}
|
||||
else if (usb > -1 && type != "Client")
|
||||
{
|
||||
s << " Selecting found USB device " << outputs[usb].name;
|
||||
ret = usb;
|
||||
}
|
||||
else if (def > -1)
|
||||
{
|
||||
s << " Selecting default device " << outputs[def].name;
|
||||
ret = def;
|
||||
}
|
||||
else {
|
||||
s << " and no default device found, aborting!";
|
||||
}
|
||||
}
|
||||
qInfo(logAudio()) << msg;
|
||||
return ret;
|
||||
}
|
|
@ -0,0 +1,106 @@
|
|||
#ifndef AUDIODEVICES_H
|
||||
#define AUDIODEVICES_H
|
||||
#include <QObject>
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
#include <QAudioDeviceInfo>
|
||||
#else
|
||||
#include <QMediaDevices>
|
||||
#include <QAudioDevice>
|
||||
#include <QString>
|
||||
#endif
|
||||
|
||||
#include <QFontMetrics>
|
||||
|
||||
#include <portaudio.h>
|
||||
#ifndef Q_OS_LINUX
|
||||
#include "RtAudio.h"
|
||||
#else
|
||||
#include "rtaudio/RtAudio.h"
|
||||
#endif
|
||||
|
||||
#include "wfviewtypes.h"
|
||||
|
||||
|
||||
struct audioDevice {
|
||||
audioDevice(QString name, int deviceInt, bool isDefault) : name(name), deviceInt(deviceInt), isDefault(isDefault) {};
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
audioDevice(QString name, const QAudioDeviceInfo deviceInfo, QString realm, bool isDefault) : name(name), deviceInfo(deviceInfo), realm(realm), isDefault(isDefault) {};
|
||||
#else
|
||||
audioDevice(QString name, QAudioDevice deviceInfo, QString realm, bool isDefault) : name(name), deviceInfo(deviceInfo), realm(realm), isDefault(isDefault) {};
|
||||
#endif
|
||||
|
||||
QString name;
|
||||
int deviceInt;
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
const QAudioDeviceInfo deviceInfo;
|
||||
#else
|
||||
QAudioDevice deviceInfo;
|
||||
#endif
|
||||
|
||||
QString realm;
|
||||
bool isDefault;
|
||||
};
|
||||
|
||||
class audioDevices : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit audioDevices(audioType type, QFontMetrics fm, QObject* parent = nullptr);
|
||||
~audioDevices();
|
||||
void setAudioType(audioType type) { system = type; };
|
||||
audioType getAudioType() { return system; };
|
||||
int getNumCharsIn() { return numCharsIn; };
|
||||
int getNumCharsOut() { return numCharsOut; };
|
||||
|
||||
QString getInputName(int num) { return inputs[num].name; };
|
||||
QString getOutputName(int num) { return outputs[num].name; };
|
||||
|
||||
int getInputDeviceInt(int num) { return inputs[num].deviceInt; };
|
||||
int getOutputDeviceInt(int num) { return outputs[num].deviceInt; };
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
const QAudioDeviceInfo getInputDeviceInfo(int num) { return inputs[num].deviceInfo; };
|
||||
const QAudioDeviceInfo getOutputDeviceInfo(int num) { return outputs[num].deviceInfo; };
|
||||
#else
|
||||
const QAudioDevice getInputDeviceInfo(int num) { return inputs[num].deviceInfo; };
|
||||
const QAudioDevice getOutputDeviceInfo(int num) { return outputs[num].deviceInfo; };
|
||||
#endif
|
||||
|
||||
void enumerate();
|
||||
|
||||
QStringList getInputs();
|
||||
QStringList getOutputs();
|
||||
|
||||
int findInput(QString type, QString name);
|
||||
int findOutput(QString type, QString name);
|
||||
|
||||
#if (QT_VERSION >= QT_VERSION_CHECK(6,0,0))
|
||||
QMediaDevices mediaDevices;
|
||||
#endif
|
||||
|
||||
public slots:
|
||||
|
||||
signals:
|
||||
void updated();
|
||||
protected:
|
||||
private:
|
||||
|
||||
audioType system;
|
||||
QFontMetrics fm;
|
||||
QString defaultInputDeviceName;
|
||||
QString defaultOutputDeviceName;
|
||||
int numInputDevices;
|
||||
int numOutputDevices;
|
||||
QList<audioDevice> inputs;
|
||||
QList<audioDevice> outputs;
|
||||
int numCharsIn = 0;
|
||||
int numCharsOut = 0;
|
||||
QString audioApi = "wasapi";
|
||||
|
||||
};
|
||||
|
||||
#endif
|
161
audiohandler.cpp
161
audiohandler.cpp
|
@ -55,84 +55,118 @@ audioHandler::~audioHandler()
|
|||
}
|
||||
|
||||
qDebug(logAudio()) << "Creating" << (setup.isinput ? "Input" : "Output") << "audio device:" << setup.name <<
|
||||
", bits" << inFormat.sampleSize() <<
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
", bits" << radioFormat.sampleSize() <<
|
||||
#else
|
||||
", format" << radioFormat.sampleFormat() <<
|
||||
#endif
|
||||
", codec" << setup.codec <<
|
||||
", latency" << setup.latency <<
|
||||
", localAFGain" << setup.localAFgain <<
|
||||
", radioChan" << inFormat.channelCount() <<
|
||||
", radioChan" << radioFormat.channelCount() <<
|
||||
", resampleQuality" << setup.resampleQuality <<
|
||||
", samplerate" << inFormat.sampleRate() <<
|
||||
", samplerate" << radioFormat.sampleRate() <<
|
||||
", uLaw" << setup.ulaw;
|
||||
|
||||
inFormat = toQAudioFormat(setup.codec, setup.sampleRate);
|
||||
radioFormat = toQAudioFormat(setup.codec, setup.sampleRate);
|
||||
codec = LPCM;
|
||||
if (setup.codec == 0x01 || setup.codec == 0x20)
|
||||
codec = PCMU;
|
||||
else if (setup.codec == 0x40 || setup.codec == 0x40)
|
||||
codec = OPUS;
|
||||
|
||||
|
||||
outFormat = setup.port.preferredFormat();
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Preferred Format: SampleSize" << outFormat.sampleSize() << "Channel Count" << outFormat.channelCount() <<
|
||||
"Sample Rate" << outFormat.sampleRate() << "Codec" << outFormat.codec() << "Sample Type" << outFormat.sampleType();
|
||||
if (outFormat.channelCount() > 2) {
|
||||
outFormat.setChannelCount(2);
|
||||
nativeFormat = setup.port.preferredFormat();
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Preferred Format: SampleSize" << nativeFormat.sampleSize() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate() << "Codec" << codec << "Sample Type" << nativeFormat.sampleType();
|
||||
#else
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Preferred Format: SampleFormat" << nativeFormat.sampleFormat() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate();
|
||||
#endif
|
||||
if (nativeFormat.channelCount() > 2) {
|
||||
nativeFormat.setChannelCount(2);
|
||||
}
|
||||
else if (outFormat.channelCount() < 1)
|
||||
else if (nativeFormat.channelCount() < 1)
|
||||
{
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "No channels found, aborting setup.";
|
||||
return false;
|
||||
}
|
||||
|
||||
if (outFormat.channelCount() == 1 && inFormat.channelCount() == 2) {
|
||||
outFormat.setChannelCount(2);
|
||||
if (!setup.port.isFormatSupported(outFormat)) {
|
||||
if (nativeFormat.channelCount() == 1 && radioFormat.channelCount() == 2) {
|
||||
nativeFormat.setChannelCount(2);
|
||||
if (!setup.port.isFormatSupported(nativeFormat)) {
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << "Cannot request stereo reverting to mono";
|
||||
outFormat.setChannelCount(1);
|
||||
nativeFormat.setChannelCount(1);
|
||||
}
|
||||
}
|
||||
|
||||
if (outFormat.sampleRate() < 48000) {
|
||||
int tempRate=outFormat.sampleRate();
|
||||
outFormat.setSampleRate(48000);
|
||||
if (!setup.port.isFormatSupported(outFormat)) {
|
||||
if (nativeFormat.sampleRate() < 48000) {
|
||||
int tempRate=nativeFormat.sampleRate();
|
||||
nativeFormat.setSampleRate(48000);
|
||||
if (!setup.port.isFormatSupported(nativeFormat)) {
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "Cannot request 48K, reverting to "<< tempRate;
|
||||
outFormat.setSampleRate(tempRate);
|
||||
nativeFormat.setSampleRate(tempRate);
|
||||
}
|
||||
}
|
||||
|
||||
if (outFormat.sampleType() == QAudioFormat::UnSignedInt && outFormat.sampleSize()==8) {
|
||||
outFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
outFormat.setSampleSize(16);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
|
||||
if (!setup.port.isFormatSupported(outFormat)) {
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "Cannot request 16bit Signed samples, reverting to 8bit Unsigned";
|
||||
outFormat.setSampleType(QAudioFormat::UnSignedInt);
|
||||
outFormat.setSampleSize(8);
|
||||
}
|
||||
}
|
||||
if (nativeFormat.sampleType() == QAudioFormat::UnSignedInt && nativeFormat.sampleSize() == 8) {
|
||||
nativeFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
nativeFormat.setSampleSize(16);
|
||||
|
||||
if (!setup.port.isFormatSupported(nativeFormat)) {
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "Cannot request 16bit Signed samples, reverting to 8bit Unsigned";
|
||||
nativeFormat.setSampleType(QAudioFormat::UnSignedInt);
|
||||
nativeFormat.setSampleSize(8);
|
||||
}
|
||||
}
|
||||
#else
|
||||
if (nativeFormat.sampleFormat() == QAudioFormat::UInt8) {
|
||||
nativeFormat.setSampleFormat(QAudioFormat::Int16);
|
||||
|
||||
/*
|
||||
if (!setup.port.isFormatSupported(nativeFormat)) {
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "Cannot request 16bit Signed samples, reverting to 8bit Unsigned";
|
||||
nativeFormat.setSampleFormat(QAudioFormat::UInt8);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (outFormat.sampleType()==QAudioFormat::SignedInt) {
|
||||
outFormat.setSampleType(QAudioFormat::Float);
|
||||
outFormat.setSampleSize(32);
|
||||
if (!setup.port.isFormatSupported(outFormat)) {
|
||||
/*
|
||||
if (nativeFormat.sampleType()==QAudioFormat::SignedInt) {
|
||||
nativeFormat.setSampleType(QAudioFormat::Float);
|
||||
nativeFormat.setSampleSize(32);
|
||||
if (!setup.port.isFormatSupported(nativeFormat)) {
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "Attempt to select 32bit Float failed, reverting to SignedInt";
|
||||
outFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
outFormat.setSampleSize(16);
|
||||
nativeFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
nativeFormat.setSampleSize(16);
|
||||
}
|
||||
|
||||
}
|
||||
*/
|
||||
|
||||
if (outFormat.sampleSize() == 24) {
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
|
||||
if (nativeFormat.sampleSize() == 24) {
|
||||
// We can't convert this easily so use 32 bit instead.
|
||||
outFormat.setSampleSize(32);
|
||||
if (!setup.port.isFormatSupported(outFormat)) {
|
||||
nativeFormat.setSampleSize(32);
|
||||
if (!setup.port.isFormatSupported(nativeFormat)) {
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "24 bit requested and 32 bit audio not supported, try 16 bit instead";
|
||||
outFormat.setSampleSize(16);
|
||||
nativeFormat.setSampleSize(16);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleSize" << outFormat.sampleSize() << "Channel Count" << outFormat.channelCount() <<
|
||||
"Sample Rate" << outFormat.sampleRate() << "Codec" << outFormat.codec() << "Sample Type" << outFormat.sampleType();
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleSize" << nativeFormat.sampleSize() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate() << "Codec" << codec << "Sample Type" << nativeFormat.sampleType();
|
||||
#else
|
||||
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleFormat" << nativeFormat.sampleFormat() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate() << "Codec" << codec;
|
||||
|
||||
#endif
|
||||
|
||||
// We "hopefully" now have a valid format that is supported so try connecting
|
||||
|
||||
|
@ -146,21 +180,32 @@ audioHandler::~audioHandler()
|
|||
}
|
||||
converter->moveToThread(converterThread);
|
||||
|
||||
connect(this, SIGNAL(setupConverter(QAudioFormat,QAudioFormat,quint8,quint8)), converter, SLOT(init(QAudioFormat,QAudioFormat,quint8,quint8)));
|
||||
connect(this, SIGNAL(setupConverter(QAudioFormat,codecType,QAudioFormat,codecType,quint8,quint8)), converter, SLOT(init(QAudioFormat,codecType,QAudioFormat,codecType,quint8,quint8)));
|
||||
connect(converterThread, SIGNAL(finished()), converter, SLOT(deleteLater()));
|
||||
connect(this, SIGNAL(sendToConverter(audioPacket)), converter, SLOT(convert(audioPacket)));
|
||||
converterThread->start(QThread::TimeCriticalPriority);
|
||||
|
||||
if (setup.isinput) {
|
||||
audioInput = new QAudioInput(setup.port, outFormat, this);
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
audioInput = new QAudioInput(setup.port, nativeFormat, this);
|
||||
#else
|
||||
audioInput = new QAudioSource(setup.port, nativeFormat, this);
|
||||
#endif
|
||||
connect(audioInput, SIGNAL(stateChanged(QAudio::State)), SLOT(stateChanged(QAudio::State)));
|
||||
emit setupConverter(outFormat, inFormat, 7, setup.resampleQuality);
|
||||
emit setupConverter(nativeFormat, codecType::LPCM, radioFormat, codec, 7, setup.resampleQuality);
|
||||
connect(converter, SIGNAL(converted(audioPacket)), this, SLOT(convertedInput(audioPacket)));
|
||||
}
|
||||
else {
|
||||
audioOutput = new QAudioOutput(setup.port, outFormat, this);
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
audioOutput = new QAudioOutput(setup.port, nativeFormat, this);
|
||||
#else
|
||||
audioOutput = new QAudioSink(setup.port, nativeFormat, this);
|
||||
#endif
|
||||
|
||||
connect(audioOutput, SIGNAL(stateChanged(QAudio::State)), SLOT(stateChanged(QAudio::State)));
|
||||
emit setupConverter(inFormat, outFormat, 7, setup.resampleQuality);
|
||||
emit setupConverter(radioFormat, codec, nativeFormat, codecType::LPCM, 7, setup.resampleQuality);
|
||||
connect(converter, SIGNAL(converted(audioPacket)), this, SLOT(convertedOutput(audioPacket)));
|
||||
}
|
||||
|
||||
|
@ -186,10 +231,10 @@ void audioHandler::start()
|
|||
if (setup.isinput) {
|
||||
//this->open(QIODevice::WriteOnly);
|
||||
//audioInput->start(this);
|
||||
#ifdef Q_OS_WIN
|
||||
audioInput->setBufferSize(inFormat.bytesForDuration(setup.latency * 100));
|
||||
#if (defined(Q_OS_WIN) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
audioInput->setBufferSize(nativeFormat.bytesForDuration(setup.latency * 100));
|
||||
#else
|
||||
audioInput->setBufferSize(inFormat.bytesForDuration(setup.latency * 1000));
|
||||
audioInput->setBufferSize(nativeFormat.bytesForDuration(setup.latency * 1000));
|
||||
#endif
|
||||
audioDevice = audioInput->start();
|
||||
connect(audioInput, SIGNAL(destroyed()), audioDevice, SLOT(deleteLater()), Qt::UniqueConnection);
|
||||
|
@ -199,10 +244,10 @@ void audioHandler::start()
|
|||
}
|
||||
else {
|
||||
// Buffer size must be set before audio is started.
|
||||
#ifdef Q_OS_WIN
|
||||
audioOutput->setBufferSize(outFormat.bytesForDuration(setup.latency * 100));
|
||||
#if (defined(Q_OS_WIN) && (QT_VERSION < QT_VERSION_CHECK(6,0,0)))
|
||||
audioOutput->setBufferSize(nativeFormat.bytesForDuration(setup.latency * 100));
|
||||
#else
|
||||
audioOutput->setBufferSize(outFormat.bytesForDuration(setup.latency * 1000));
|
||||
audioOutput->setBufferSize(nativeFormat.bytesForDuration(setup.latency * 1000));
|
||||
#endif
|
||||
audioDevice = audioOutput->start();
|
||||
connect(audioOutput, SIGNAL(destroyed()), audioDevice, SLOT(deleteLater()), Qt::UniqueConnection);
|
||||
|
@ -253,7 +298,7 @@ void audioHandler::convertedOutput(audioPacket packet) {
|
|||
|
||||
if (packet.data.size() > 0 ) {
|
||||
|
||||
currentLatency = packet.time.msecsTo(QTime::currentTime()) + (outFormat.durationForBytes(audioOutput->bufferSize() - audioOutput->bytesFree()) / 1000);
|
||||
currentLatency = packet.time.msecsTo(QTime::currentTime()) + (nativeFormat.durationForBytes(audioOutput->bufferSize() - audioOutput->bytesFree()) / 1000);
|
||||
if (audioDevice != Q_NULLPTR) {
|
||||
if (audioDevice->write(packet.data) < packet.data.size()) {
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Buffer full!";
|
||||
|
@ -283,7 +328,7 @@ void audioHandler::getNextAudioChunk()
|
|||
if (audioDevice) {
|
||||
tempBuf.data.append(audioDevice->readAll());
|
||||
}
|
||||
if (tempBuf.data.length() >= outFormat.bytesForDuration(setup.blockSize * 1000)) {
|
||||
if (tempBuf.data.length() >= nativeFormat.bytesForDuration(setup.blockSize * 1000)) {
|
||||
audioPacket packet;
|
||||
packet.time = QTime::currentTime();
|
||||
packet.sent = 0;
|
||||
|
@ -291,14 +336,14 @@ void audioHandler::getNextAudioChunk()
|
|||
memcpy(&packet.guid, setup.guid, GUIDLEN);
|
||||
//QTime startProcessing = QTime::currentTime();
|
||||
packet.data.clear();
|
||||
packet.data = tempBuf.data.mid(0, outFormat.bytesForDuration(setup.blockSize * 1000));
|
||||
tempBuf.data.remove(0, outFormat.bytesForDuration(setup.blockSize * 1000));
|
||||
packet.data = tempBuf.data.mid(0, nativeFormat.bytesForDuration(setup.blockSize * 1000));
|
||||
tempBuf.data.remove(0, nativeFormat.bytesForDuration(setup.blockSize * 1000));
|
||||
|
||||
emit sendToConverter(packet);
|
||||
}
|
||||
|
||||
/* If there is still enough data in the buffer, call myself again in 20ms */
|
||||
if (tempBuf.data.length() >= outFormat.bytesForDuration(setup.blockSize * 1000)) {
|
||||
if (tempBuf.data.length() >= nativeFormat.bytesForDuration(setup.blockSize * 1000)) {
|
||||
QTimer::singleShot(setup.blockSize, this, &audioHandler::getNextAudioChunk);
|
||||
}
|
||||
|
||||
|
@ -328,7 +373,7 @@ void audioHandler::changeLatency(const quint16 newSize)
|
|||
stop();
|
||||
start();
|
||||
}
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Configured latency: " << setup.latency << "Buffer Duration:" << outFormat.durationForBytes(audioOutput->bufferSize())/1000 << "ms";
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Configured latency: " << setup.latency << "Buffer Duration:" << nativeFormat.durationForBytes(audioOutput->bufferSize())/1000 << "ms";
|
||||
|
||||
}
|
||||
int audioHandler::getLatency()
|
||||
|
|
|
@ -16,8 +16,18 @@
|
|||
/* QT Audio Headers */
|
||||
#include <QAudioOutput>
|
||||
#include <QAudioFormat>
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
#include <QAudioDeviceInfo>
|
||||
#include <QAudioInput>
|
||||
#include <QAudioOutput>
|
||||
#else
|
||||
#include <QMediaDevices>
|
||||
#include <QAudioDevice>
|
||||
#include <QAudioSource>
|
||||
#include <QAudioSink>
|
||||
#endif
|
||||
|
||||
#include <QIODevice>
|
||||
|
||||
|
||||
|
@ -70,8 +80,8 @@ signals:
|
|||
void audioMessage(QString message);
|
||||
void sendLatency(quint16 newSize);
|
||||
void haveAudioData(const audioPacket& data);
|
||||
void haveLevels(quint16 amplitudePeak, quint16 amplitudeRMS, quint16 latency,quint16 current,bool under,bool over);
|
||||
void setupConverter(QAudioFormat in, QAudioFormat out, quint8 opus, quint8 resamp);
|
||||
void haveLevels(quint16 amplitudePeak, quint16 amplitudeRMS,quint16 latency,quint16 current,bool under,bool over);
|
||||
void setupConverter(QAudioFormat in, codecType codecIn, QAudioFormat out, codecType codecOut, quint8 opus, quint8 resamp);
|
||||
void sendToConverter(audioPacket audio);
|
||||
|
||||
|
||||
|
@ -87,12 +97,19 @@ private:
|
|||
bool isReady = false;
|
||||
bool audioBuffered = false;
|
||||
|
||||
QAudioOutput* audioOutput=Q_NULLPTR;
|
||||
QAudioInput* audioInput=Q_NULLPTR;
|
||||
QIODevice* audioDevice=Q_NULLPTR;
|
||||
QAudioFormat inFormat;
|
||||
QAudioFormat outFormat;
|
||||
|
||||
QAudioFormat radioFormat;
|
||||
QAudioFormat nativeFormat;
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
QAudioOutput* audioOutput = Q_NULLPTR;
|
||||
QAudioInput* audioInput = Q_NULLPTR;
|
||||
QAudioDeviceInfo deviceInfo;
|
||||
#else
|
||||
QAudioSink* audioOutput = Q_NULLPTR;
|
||||
QAudioSource* audioInput = Q_NULLPTR;
|
||||
QAudioDevice deviceInfo;
|
||||
#endif
|
||||
|
||||
audioConverter* converter=Q_NULLPTR;
|
||||
QThread* converterThread = Q_NULLPTR;
|
||||
|
@ -121,6 +138,7 @@ private:
|
|||
OpusEncoder* encoder = Q_NULLPTR;
|
||||
OpusDecoder* decoder = Q_NULLPTR;
|
||||
QTimer* underTimer;
|
||||
codecType codec;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -59,7 +59,11 @@ void commHandler::init()
|
|||
//qInfo(logSerial()) << "Serial buffer size: " << port->readBufferSize();
|
||||
|
||||
connect(port, SIGNAL(readyRead()), this, SLOT(receiveDataIn()));
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
connect(port, SIGNAL(error(QSerialPort::SerialPortError)), this, SLOT(handleError(QSerialPort::SerialPortError)));
|
||||
#else
|
||||
connect(port, SIGNAL(errorOccurred(QSerialPort::SerialPortError)), this, SLOT(handleError(QSerialPort::SerialPortError)));
|
||||
#endif
|
||||
lastDataReceived = QTime::currentTime();
|
||||
}
|
||||
|
||||
|
@ -316,7 +320,7 @@ void commHandler::openPort()
|
|||
qInfo(logSerial()) << "Could not open serial port " << portName << " , please restart.";
|
||||
isConnected = false;
|
||||
serialError = true;
|
||||
emit haveSerialPortError(portName, "Could not open port. Please restart.");
|
||||
emit havePortError(errorType(true, portName, "Could not open port. Please restart."));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -9,6 +9,8 @@
|
|||
#include <QTime>
|
||||
#include <QTimer>
|
||||
|
||||
#include "wfviewtypes.h"
|
||||
|
||||
// This class abstracts the comm port in a useful way and connects to
|
||||
// the command creator and command parser.
|
||||
|
||||
|
@ -39,7 +41,7 @@ signals:
|
|||
void haveTextMessage(QString message); // status, debug only
|
||||
void sendDataOutToPort(const QByteArray &writeData); // not used
|
||||
void haveDataFromPort(QByteArray data); // emit this when we have data, connect to rigcommander
|
||||
void haveSerialPortError(const QString port, const QString error);
|
||||
void havePortError(errorType err);
|
||||
void haveStatusUpdate(const QString text);
|
||||
|
||||
private:
|
||||
|
|
|
@ -23,4 +23,9 @@ Q_DECLARE_LOGGING_CATEGORY(logCluster)
|
|||
#define __PRETTY_FUNCTION__ __FUNCSIG__
|
||||
#endif
|
||||
|
||||
#if QT_VERSION > 0x060000
|
||||
//#define hex Qt::hex
|
||||
//#define bin Qt::bin
|
||||
#endif
|
||||
|
||||
#endif // LOGCATEGORIES_H
|
||||
|
|
2
main.cpp
2
main.cpp
|
@ -155,7 +155,7 @@ int main(int argc, char *argv[])
|
|||
signal(SIGTERM, cleanup);
|
||||
signal(SIGKILL, cleanup);
|
||||
#endif
|
||||
w = new servermain(settingsFile, logFilename);
|
||||
w = new servermain(settingsFile);
|
||||
#else
|
||||
a.setWheelScrollLines(1); // one line per wheel click
|
||||
wfmain w(settingsFile, logFilename, debugMode);
|
||||
|
|
131
pahandler.cpp
131
pahandler.cpp
|
@ -42,16 +42,20 @@ bool paHandler::init(audioSetup setup)
|
|||
return false;
|
||||
}
|
||||
|
||||
inFormat = toQAudioFormat(setup.codec, setup.sampleRate);
|
||||
radioFormat = toQAudioFormat(setup.codec, setup.sampleRate);
|
||||
|
||||
qDebug(logAudio()) << "Creating" << (setup.isinput ? "Input" : "Output") << "audio device:" << setup.name <<
|
||||
", bits" << inFormat.sampleSize() <<
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
", bits" << radioFormat.sampleSize() <<
|
||||
#else
|
||||
", format" << radioFormat.sampleFormat() <<
|
||||
#endif
|
||||
", codec" << setup.codec <<
|
||||
", latency" << setup.latency <<
|
||||
", localAFGain" << setup.localAFgain <<
|
||||
", radioChan" << inFormat.channelCount() <<
|
||||
", radioChan" << radioFormat.channelCount() <<
|
||||
", resampleQuality" << setup.resampleQuality <<
|
||||
", samplerate" << inFormat.sampleRate() <<
|
||||
", samplerate" << radioFormat.sampleRate() <<
|
||||
", uLaw" << setup.ulaw;
|
||||
|
||||
PaError err;
|
||||
|
@ -65,6 +69,13 @@ bool paHandler::init(audioSetup setup)
|
|||
// qDebug(logAudio()) << "Portaudio initialized";
|
||||
//}
|
||||
|
||||
|
||||
codecType codec = LPCM;
|
||||
if (setup.codec == 0x01 || setup.codec == 0x20)
|
||||
codec = PCMU;
|
||||
else if (setup.codec == 0x40 || setup.codec == 0x40)
|
||||
codec = OPUS;
|
||||
|
||||
memset(&aParams, 0, sizeof(PaStreamParameters));
|
||||
|
||||
aParams.device = setup.portInt;
|
||||
|
@ -74,43 +85,52 @@ bool paHandler::init(audioSetup setup)
|
|||
|
||||
|
||||
if (setup.isinput) {
|
||||
outFormat.setChannelCount(info->maxInputChannels);
|
||||
nativeFormat.setChannelCount(info->maxInputChannels);
|
||||
}
|
||||
else {
|
||||
outFormat.setChannelCount(info->maxOutputChannels);
|
||||
nativeFormat.setChannelCount(info->maxOutputChannels);
|
||||
}
|
||||
|
||||
aParams.suggestedLatency = (float)setup.latency / 1000.0f;
|
||||
outFormat.setSampleRate(info->defaultSampleRate);
|
||||
nativeFormat.setSampleRate(info->defaultSampleRate);
|
||||
aParams.sampleFormat = paFloat32;
|
||||
outFormat.setSampleSize(32);
|
||||
outFormat.setSampleType(QAudioFormat::Float);
|
||||
outFormat.setByteOrder(QAudioFormat::LittleEndian);
|
||||
outFormat.setCodec("audio/pcm");
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
nativeFormat.setSampleSize(32);
|
||||
nativeFormat.setSampleType(QAudioFormat::Float);
|
||||
nativeFormat.setByteOrder(QAudioFormat::LittleEndian);
|
||||
nativeFormat.setCodec("audio/pcm");
|
||||
#else
|
||||
nativeFormat.setSampleFormat(QAudioFormat::Float);
|
||||
#endif
|
||||
|
||||
if (outFormat.channelCount() > 2) {
|
||||
outFormat.setChannelCount(2);
|
||||
if (nativeFormat.channelCount() > 2) {
|
||||
nativeFormat.setChannelCount(2);
|
||||
}
|
||||
else if (outFormat.channelCount() < 1)
|
||||
else if (nativeFormat.channelCount() < 1)
|
||||
{
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "No channels found, aborting setup.";
|
||||
return false;
|
||||
}
|
||||
|
||||
if (inFormat.channelCount() < outFormat.channelCount()) {
|
||||
outFormat.setChannelCount(inFormat.channelCount());
|
||||
if (nativeFormat.channelCount() == 1 && radioFormat.channelCount() == 2) {
|
||||
nativeFormat.setChannelCount(2);
|
||||
}
|
||||
|
||||
aParams.channelCount = outFormat.channelCount();
|
||||
aParams.channelCount = nativeFormat.channelCount();
|
||||
|
||||
if (outFormat.sampleRate() < 44100) {
|
||||
outFormat.setSampleRate(48000);
|
||||
if (nativeFormat.sampleRate() < 44100) {
|
||||
nativeFormat.setSampleRate(48000);
|
||||
}
|
||||
|
||||
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleSize" << outFormat.sampleSize() << "Channel Count" << outFormat.channelCount() <<
|
||||
"Sample Rate" << outFormat.sampleRate() << "Codec" << outFormat.codec() << "Sample Type" << outFormat.sampleType();
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleSize" << nativeFormat.sampleSize() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate() << "Codec" << codec << "Sample Type" << nativeFormat.sampleType();
|
||||
#else
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleFormat" << nativeFormat.sampleFormat() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate() << "Codec" << codec;
|
||||
#endif
|
||||
|
||||
// We "hopefully" now have a valid format that is supported so try connecting
|
||||
|
||||
|
@ -124,7 +144,7 @@ bool paHandler::init(audioSetup setup)
|
|||
}
|
||||
converter->moveToThread(converterThread);
|
||||
|
||||
connect(this, SIGNAL(setupConverter(QAudioFormat, QAudioFormat, quint8, quint8)), converter, SLOT(init(QAudioFormat, QAudioFormat, quint8, quint8)));
|
||||
connect(this, SIGNAL(setupConverter(QAudioFormat, codecType, QAudioFormat, codecType, quint8, quint8)), converter, SLOT(init(QAudioFormat, codecType, QAudioFormat, codecType, quint8, quint8)));
|
||||
connect(converterThread, SIGNAL(finished()), converter, SLOT(deleteLater()));
|
||||
connect(this, SIGNAL(sendToConverter(audioPacket)), converter, SLOT(convert(audioPacket)));
|
||||
converterThread->start(QThread::TimeCriticalPriority);
|
||||
|
@ -132,52 +152,55 @@ bool paHandler::init(audioSetup setup)
|
|||
aParams.hostApiSpecificStreamInfo = NULL;
|
||||
|
||||
// Per channel chunk size.
|
||||
this->chunkSize = (outFormat.bytesForDuration(setup.blockSize * 1000) / sizeof(float)) * outFormat.channelCount();
|
||||
this->chunkSize = nativeFormat.framesForDuration(setup.blockSize * 1000);
|
||||
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << "Chunk size" << this->chunkSize;
|
||||
// Check the format is supported
|
||||
|
||||
|
||||
if (setup.isinput) {
|
||||
err = Pa_IsFormatSupported(&aParams, NULL, outFormat.sampleRate());
|
||||
}
|
||||
else
|
||||
{
|
||||
err = Pa_IsFormatSupported(NULL,&aParams, outFormat.sampleRate());
|
||||
}
|
||||
|
||||
if (err != paNoError) {
|
||||
err = -1;
|
||||
int errCount = 0;
|
||||
while (err != paNoError) {
|
||||
if (setup.isinput) {
|
||||
err = Pa_IsFormatSupported(&aParams, NULL, nativeFormat.sampleRate());
|
||||
}
|
||||
else
|
||||
{
|
||||
err = Pa_IsFormatSupported(NULL, &aParams, nativeFormat.sampleRate());
|
||||
}
|
||||
if (err == paInvalidChannelCount)
|
||||
{
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << "Unsupported channel count" << aParams.channelCount;
|
||||
if (aParams.channelCount == 2) {
|
||||
aParams.channelCount = 1;
|
||||
outFormat.setChannelCount(1);
|
||||
nativeFormat.setChannelCount(1);
|
||||
}
|
||||
else {
|
||||
aParams.channelCount = 2;
|
||||
outFormat.setChannelCount(2);
|
||||
nativeFormat.setChannelCount(2);
|
||||
}
|
||||
}
|
||||
else if (err == paInvalidSampleRate)
|
||||
if (err == paInvalidSampleRate)
|
||||
{
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << "Unsupported sample rate" << outFormat.sampleRate();
|
||||
outFormat.setSampleRate(44100);
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << "Unsupported sample rate" << nativeFormat.sampleRate();
|
||||
nativeFormat.setSampleRate(44100);
|
||||
}
|
||||
else if (err == paSampleFormatNotSupported)
|
||||
if (err == paSampleFormatNotSupported)
|
||||
{
|
||||
aParams.sampleFormat = paInt16;
|
||||
outFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
outFormat.setSampleSize(16);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << "Unsupported sample Format" << nativeFormat.sampleType();
|
||||
nativeFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
nativeFormat.setSampleSize(16);
|
||||
#else
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << "Unsupported sample Format" << nativeFormat.sampleFormat();
|
||||
nativeFormat.setSampleFormat(QAudioFormat::Int16);
|
||||
#endif
|
||||
}
|
||||
|
||||
if (setup.isinput) {
|
||||
err = Pa_IsFormatSupported(&aParams, NULL, outFormat.sampleRate());
|
||||
}
|
||||
else
|
||||
{
|
||||
err = Pa_IsFormatSupported(NULL, &aParams, outFormat.sampleRate());
|
||||
}
|
||||
if (err != paNoError) {
|
||||
errCount++;
|
||||
if (errCount > 5) {
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "Cannot find suitable format, aborting:" << Pa_GetErrorText(err);
|
||||
return false;
|
||||
}
|
||||
|
@ -185,13 +208,13 @@ bool paHandler::init(audioSetup setup)
|
|||
|
||||
if (setup.isinput) {
|
||||
|
||||
err = Pa_OpenStream(&audio, &aParams, 0, outFormat.sampleRate(), this->chunkSize, paNoFlag, &paHandler::staticWrite, (void*)this);
|
||||
emit setupConverter(outFormat, inFormat, 7, setup.resampleQuality);
|
||||
err = Pa_OpenStream(&audio, &aParams, 0, nativeFormat.sampleRate(), this->chunkSize, paNoFlag, &paHandler::staticWrite, (void*)this);
|
||||
emit setupConverter(nativeFormat, codecType::LPCM, radioFormat, codec, 7, setup.resampleQuality);
|
||||
connect(converter, SIGNAL(converted(audioPacket)), this, SLOT(convertedInput(audioPacket)));
|
||||
}
|
||||
else {
|
||||
err = Pa_OpenStream(&audio, 0, &aParams, outFormat.sampleRate(), this->chunkSize, paNoFlag, NULL, NULL);
|
||||
emit setupConverter(inFormat, outFormat, 7, setup.resampleQuality);
|
||||
err = Pa_OpenStream(&audio, 0, &aParams, nativeFormat.sampleRate(), this->chunkSize, paNoFlag, NULL, NULL);
|
||||
emit setupConverter(radioFormat, codec, nativeFormat, codecType::LPCM, 7, setup.resampleQuality);
|
||||
connect(converter, SIGNAL(converted(audioPacket)), this, SLOT(convertedOutput(audioPacket)));
|
||||
}
|
||||
|
||||
|
@ -248,7 +271,7 @@ int paHandler::writeData(const void* inputBuffer, void* outputBuffer,
|
|||
packet.sent = 0;
|
||||
packet.volume = volume;
|
||||
memcpy(&packet.guid, setup.guid, GUIDLEN);
|
||||
packet.data.append((char*)inputBuffer, nFrames*inFormat.channelCount()*sizeof(float));
|
||||
packet.data.append((char*)inputBuffer, nFrames*nativeFormat.bytesPerFrame());
|
||||
emit sendToConverter(packet);
|
||||
|
||||
if (status == paInputUnderflow) {
|
||||
|
@ -273,14 +296,14 @@ void paHandler::convertedOutput(audioPacket packet) {
|
|||
|
||||
if (Pa_IsStreamActive(audio) == 1) {
|
||||
if (currentLatency < (setup.latency+latencyAllowance)) {
|
||||
PaError err = Pa_WriteStream(audio, (char*)packet.data.data(), packet.data.size() / sizeof(float) / outFormat.channelCount());
|
||||
PaError err = Pa_WriteStream(audio, (char*)packet.data.data(), packet.data.size() / nativeFormat.bytesPerFrame());
|
||||
|
||||
if (err != paNoError) {
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Error writing audio!";
|
||||
}
|
||||
}
|
||||
else {
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Disgarding audio data as current latency" << currentLatency << "exceeds setup latency" << setup.latency;
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Discarding audio data as current latency" << currentLatency << "exceeds setup latency" << setup.latency;
|
||||
Pa_StopStream(audio);
|
||||
latencyAllowance++;
|
||||
}
|
||||
|
|
|
@ -56,7 +56,7 @@ signals:
|
|||
void sendLatency(quint16 newSize);
|
||||
void haveAudioData(const audioPacket& data);
|
||||
void haveLevels(quint16 amplitudePeak, quint16 amplitudeRMS, quint16 latency, quint16 current, bool under, bool over);
|
||||
void setupConverter(QAudioFormat in, QAudioFormat out, quint8 opus, quint8 resamp);
|
||||
void setupConverter(QAudioFormat in, codecType codecIn, QAudioFormat out, codecType codecOut, quint8 opus, quint8 resamp);
|
||||
void sendToConverter(audioPacket audio);
|
||||
|
||||
private:
|
||||
|
@ -85,8 +85,8 @@ private:
|
|||
qreal volume = 1.0;
|
||||
|
||||
audioSetup setup;
|
||||
QAudioFormat inFormat;
|
||||
QAudioFormat outFormat;
|
||||
QAudioFormat radioFormat;
|
||||
QAudioFormat nativeFormat;
|
||||
audioConverter* converter = Q_NULLPTR;
|
||||
QThread* converterThread = Q_NULLPTR;
|
||||
bool isUnderrun = false;
|
||||
|
|
|
@ -90,7 +90,7 @@ void pttyHandler::openPort()
|
|||
qInfo(logSerial()) << "Could not open pseudo terminal port, please restart.";
|
||||
isConnected = false;
|
||||
serialError = true;
|
||||
emit haveSerialPortError(portName, "Could not open pseudo terminal port. Please restart.");
|
||||
emit havePortError(errorType(portName, "Could not open pseudo terminal port. Please restart."));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
#include <QtSerialPort/QSerialPort>
|
||||
|
||||
#include "rigidentities.h"
|
||||
#include "wfviewtypes.h"
|
||||
|
||||
// This class abstracts the comm port in a useful way and connects to
|
||||
// the command creator and command parser.
|
||||
|
@ -34,7 +35,7 @@ private slots:
|
|||
signals:
|
||||
void haveTextMessage(QString message); // status, debug only
|
||||
void haveDataFromPort(QByteArray data); // emit this when we have data, connect to rigcommander
|
||||
void haveSerialPortError(const QString port, const QString error);
|
||||
void havePortError(errorType err);
|
||||
void haveStatusUpdate(const QString text);
|
||||
|
||||
private:
|
||||
|
|
Plik diff jest za duży
Load Diff
|
@ -294,7 +294,7 @@ static spx_word16_t sinc(float cutoff, float x, int N, const struct FuncDef* win
|
|||
else if (fabs(x) > .5 * N)
|
||||
return 0;
|
||||
/*FIXME: Can it really be any slower than this? */
|
||||
return cutoff * sin(M_PI * xx) / (M_PI * xx) * compute_func(fabs(2. * x / N), window_func);
|
||||
return (spx_word16_t)(cutoff * (float)(sin(M_PI * xx) / (M_PI * xx) * compute_func((float)fabs(2. * x / N), window_func)));
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -324,7 +324,7 @@ static void cubic_coef(spx_word16_t frac, spx_word16_t interp[4])
|
|||
/*interp[2] = 1.f - 0.5f*frac - frac*frac + 0.5f*frac*frac*frac;*/
|
||||
interp[3] = -0.33333f * frac + 0.5f * frac * frac - 0.16667f * frac * frac * frac;
|
||||
/* Just to make sure we don't have rounding problems */
|
||||
interp[2] = 1. - interp[0] - interp[1] - interp[3];
|
||||
interp[2] = (spx_word16_t) (1. - interp[0] - interp[1] - interp[3]);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -419,7 +419,7 @@ static int resampler_basic_direct_double(SpeexResamplerState* st, spx_uint32_t c
|
|||
sum = inner_product_double(sinct, iptr, N);
|
||||
#endif
|
||||
|
||||
out[out_stride * out_sample++] = PSHR32(sum, 15);
|
||||
out[out_stride * out_sample++] = (spx_word16_t)PSHR32(sum, 15);
|
||||
last_sample += int_advance;
|
||||
samp_frac_num += frac_advance;
|
||||
if (samp_frac_num >= den_rate)
|
||||
|
@ -539,7 +539,7 @@ static int resampler_basic_interpolate_double(SpeexResamplerState* st, spx_uint3
|
|||
sum = MULT16_32_Q15(interp[0], accum[0]) + MULT16_32_Q15(interp[1], accum[1]) + MULT16_32_Q15(interp[2], accum[2]) + MULT16_32_Q15(interp[3], accum[3]);
|
||||
#else
|
||||
cubic_coef(frac, interp);
|
||||
sum = interpolate_product_double(iptr, st->sinc_table + st->oversample + 4 - offset - 2, N, st->oversample, interp);
|
||||
sum = (spx_word16_t)interpolate_product_double(iptr, st->sinc_table + st->oversample + 4 - offset - 2, N, st->oversample, interp);
|
||||
#endif
|
||||
|
||||
out[out_stride * out_sample++] = PSHR32(sum, 15);
|
||||
|
@ -673,7 +673,7 @@ static int update_filter(SpeexResamplerState* st)
|
|||
for (i = 0; i < st->den_rate; i++)
|
||||
{
|
||||
spx_int32_t j;
|
||||
for (j = 0; j < st->filt_len; j++)
|
||||
for (j = 0; j < (spx_int32_t)st->filt_len; j++)
|
||||
{
|
||||
st->sinc_table[i * st->filt_len + j] = sinc(st->cutoff, ((j - (spx_int32_t)st->filt_len / 2 + 1) - ((float)i) / st->den_rate), st->filt_len, quality_map[st->quality].window_func);
|
||||
}
|
||||
|
@ -934,7 +934,7 @@ EXPORT int speex_resampler_process_int(SpeexResamplerState* st, spx_uint32_t cha
|
|||
EXPORT int speex_resampler_process_float(SpeexResamplerState* st, spx_uint32_t channel_index, const float* in, spx_uint32_t* in_len, float* out, spx_uint32_t* out_len)
|
||||
#endif
|
||||
{
|
||||
int j;
|
||||
spx_uint32_t j;
|
||||
spx_uint32_t ilen = *in_len;
|
||||
spx_uint32_t olen = *out_len;
|
||||
spx_word16_t* x = st->mem + channel_index * st->mem_alloc_size;
|
||||
|
@ -976,7 +976,7 @@ EXPORT int speex_resampler_process_float(SpeexResamplerState* st, spx_uint32_t c
|
|||
EXPORT int speex_resampler_process_int(SpeexResamplerState* st, spx_uint32_t channel_index, const spx_int16_t* in, spx_uint32_t* in_len, spx_int16_t* out, spx_uint32_t* out_len)
|
||||
#endif
|
||||
{
|
||||
int j;
|
||||
spx_uint32_t j;
|
||||
const int istride_save = st->in_stride;
|
||||
const int ostride_save = st->out_stride;
|
||||
spx_uint32_t ilen = *in_len;
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
#define OVERRIDE_INNER_PRODUCT_SINGLE
|
||||
static inline float inner_product_single(const float* a, const float* b, unsigned int len)
|
||||
{
|
||||
int i;
|
||||
unsigned int i;
|
||||
float ret;
|
||||
__m128 sum = _mm_setzero_ps();
|
||||
for (i = 0; i < len; i += 8)
|
||||
|
@ -55,7 +55,7 @@ static inline float inner_product_single(const float* a, const float* b, unsigne
|
|||
|
||||
#define OVERRIDE_INTERPOLATE_PRODUCT_SINGLE
|
||||
static inline float interpolate_product_single(const float* a, const float* b, unsigned int len, const spx_uint32_t oversample, float* frac) {
|
||||
int i;
|
||||
unsigned int i;
|
||||
float ret;
|
||||
__m128 sum = _mm_setzero_ps();
|
||||
__m128 f = _mm_loadu_ps(frac);
|
||||
|
@ -77,7 +77,7 @@ static inline float interpolate_product_single(const float* a, const float* b, u
|
|||
|
||||
static inline double inner_product_double(const float* a, const float* b, unsigned int len)
|
||||
{
|
||||
int i;
|
||||
unsigned int i;
|
||||
double ret;
|
||||
__m128d sum = _mm_setzero_pd();
|
||||
__m128 t;
|
||||
|
@ -98,7 +98,7 @@ static inline double inner_product_double(const float* a, const float* b, unsign
|
|||
|
||||
#define OVERRIDE_INTERPOLATE_PRODUCT_DOUBLE
|
||||
static inline double interpolate_product_double(const float* a, const float* b, unsigned int len, const spx_uint32_t oversample, float* frac) {
|
||||
int i;
|
||||
unsigned int i;
|
||||
double ret;
|
||||
__m128d sum;
|
||||
__m128d sum1 = _mm_setzero_pd();
|
||||
|
|
|
@ -86,8 +86,8 @@ void rigCommander::commSetup(unsigned char rigCivAddr, QString rigSerialPort, qu
|
|||
// data from the rig to the ptty:
|
||||
connect(comm, SIGNAL(haveDataFromPort(QByteArray)), ptty, SLOT(receiveDataFromRigToPtty(QByteArray)));
|
||||
|
||||
connect(comm, SIGNAL(haveSerialPortError(QString, QString)), this, SLOT(handleSerialPortError(QString, QString)));
|
||||
connect(ptty, SIGNAL(haveSerialPortError(QString, QString)), this, SLOT(handleSerialPortError(QString, QString)));
|
||||
connect(comm, SIGNAL(havePortError(errorType)), this, SLOT(handlePortError(errorType)));
|
||||
connect(ptty, SIGNAL(havePortError(errorType)), this, SLOT(handlePortError(errorType)));
|
||||
|
||||
connect(this, SIGNAL(getMoreDebug()), comm, SLOT(debugThis()));
|
||||
connect(this, SIGNAL(getMoreDebug()), ptty, SLOT(debugThis()));
|
||||
|
@ -164,12 +164,12 @@ void rigCommander::commSetup(unsigned char rigCivAddr, udpPreferences prefs, aud
|
|||
connect(udp, SIGNAL(haveBaudRate(quint32)), this, SLOT(receiveBaudRate(quint32)));
|
||||
|
||||
// Connect for errors/alerts
|
||||
connect(udp, SIGNAL(haveNetworkError(QString, QString)), this, SLOT(handleSerialPortError(QString, QString)));
|
||||
connect(udp, SIGNAL(haveNetworkError(errorType)), this, SLOT(handlePortError(errorType)));
|
||||
connect(udp, SIGNAL(haveNetworkStatus(networkStatus)), this, SLOT(handleStatusUpdate(networkStatus)));
|
||||
connect(udp, SIGNAL(haveNetworkAudioLevels(networkAudioLevels)), this, SLOT(handleNetworkAudioLevels(networkAudioLevels)));
|
||||
|
||||
|
||||
connect(ptty, SIGNAL(haveSerialPortError(QString, QString)), this, SLOT(handleSerialPortError(QString, QString)));
|
||||
connect(ptty, SIGNAL(havePortError(errorType)), this, SLOT(handlePortError(errorType)));
|
||||
connect(this, SIGNAL(getMoreDebug()), ptty, SLOT(debugThis()));
|
||||
|
||||
connect(this, SIGNAL(discoveredRigID(rigCapabilities)), ptty, SLOT(receiveFoundRigID(rigCapabilities)));
|
||||
|
@ -232,14 +232,14 @@ void rigCommander::process()
|
|||
// new thread enters here. Do nothing but do check for errors.
|
||||
if(comm!=Q_NULLPTR && comm->serialError)
|
||||
{
|
||||
emit haveSerialPortError(rigSerialPort, QString("Error from commhandler. Check serial port."));
|
||||
emit havePortError(errorType(rigSerialPort, QString("Error from commhandler. Check serial port.")));
|
||||
}
|
||||
}
|
||||
|
||||
void rigCommander::handleSerialPortError(const QString port, const QString errorText)
|
||||
void rigCommander::handlePortError(errorType err)
|
||||
{
|
||||
qInfo(logRig()) << "Error using port " << port << " message: " << errorText;
|
||||
emit haveSerialPortError(port, errorText);
|
||||
qInfo(logRig()) << "Error using port " << err.device << " message: " << err.message;
|
||||
emit havePortError(err);
|
||||
}
|
||||
|
||||
void rigCommander::handleStatusUpdate(const networkStatus status)
|
||||
|
@ -3118,7 +3118,7 @@ void rigCommander::determineRigCaps()
|
|||
|
||||
|
||||
standardHF = { bandDef6m, bandDef10m, bandDef12m, bandDef15m, bandDef17m,
|
||||
bandDef20m, bandDef30m, bandDef40m, bandDef60m, bandDef80m, bandDef80m};
|
||||
bandDef20m, bandDef30m, bandDef40m, bandDef60m, bandDef80m, bandDef160m};
|
||||
|
||||
standardVU = { bandDef2m, bandDef70cm };
|
||||
|
||||
|
|
|
@ -227,7 +227,7 @@ public slots:
|
|||
// UDP:
|
||||
void handleNewData(const QByteArray& data);
|
||||
void receiveAudioData(const audioPacket& data);
|
||||
void handleSerialPortError(const QString port, const QString errorText);
|
||||
void handlePortError(errorType err);
|
||||
void changeLatency(const quint16 value);
|
||||
void dataFromServer(QByteArray data);
|
||||
void receiveBaudRate(quint32 baudrate);
|
||||
|
@ -249,7 +249,7 @@ public slots:
|
|||
signals:
|
||||
// Communication:
|
||||
void commReady();
|
||||
void haveSerialPortError(const QString port, const QString errorText);
|
||||
void havePortError(errorType err);
|
||||
void haveStatusUpdate(const networkStatus status);
|
||||
void haveNetworkAudioLevels(const networkAudioLevels l);
|
||||
void dataForComm(const QByteArray &outData);
|
||||
|
|
16
rigctld.cpp
16
rigctld.cpp
|
@ -154,28 +154,28 @@ void rigCtlClient::socketReadyRead()
|
|||
return;
|
||||
}
|
||||
|
||||
if (commands[num] == ";" || commands[num] == "|" || commands[num] == ",")
|
||||
if (commands[num] == ';' || commands[num] == '|' || commands[num] == ',')
|
||||
{
|
||||
sep = commands[num].toLatin1();
|
||||
num++;
|
||||
}
|
||||
else if (commands[num] == "+")
|
||||
else if (commands[num] == '+')
|
||||
{
|
||||
longReply = true;
|
||||
sep = "\n";
|
||||
num++;
|
||||
}
|
||||
else if (commands[num] == "#")
|
||||
else if (commands[num] == '#')
|
||||
{
|
||||
continue;
|
||||
}
|
||||
else if (commands[num].toLower() == "q")
|
||||
else if (commands[num].toLower() == 'q')
|
||||
{
|
||||
closeSocket();
|
||||
return;
|
||||
}
|
||||
|
||||
if (commands[num] == "\\")
|
||||
if (commands[num] == '\\')
|
||||
{
|
||||
num++;
|
||||
}
|
||||
|
@ -183,7 +183,7 @@ void rigCtlClient::socketReadyRead()
|
|||
QStringList command = commands.mid(num).split(" ");
|
||||
|
||||
|
||||
if (command[0] == 0xf0 || command[0] == "chk_vfo")
|
||||
if (command[0] == '\xf0' || command[0] == "chk_vfo")
|
||||
{
|
||||
chkVfoEecuted = true;
|
||||
QString resp;
|
||||
|
@ -1176,7 +1176,7 @@ void rigCtlClient::socketReadyRead()
|
|||
|
||||
qInfo(logRigCtlD()) << "Setting:" << command[1] << command[2];
|
||||
}
|
||||
else if (command.length() > 0 && (command[0] == 0x88 || command[0] == "get_powerstat"))
|
||||
else if (command.length() > 0 && (command[0] == '\x88' || command[0] == "get_powerstat"))
|
||||
{
|
||||
|
||||
QString resp;
|
||||
|
@ -1187,7 +1187,7 @@ void rigCtlClient::socketReadyRead()
|
|||
response.append(resp);
|
||||
|
||||
}
|
||||
else if (command.length() > 1 && (command[0] == 0x87 || command[0] == "set_powerstat"))
|
||||
else if (command.length() > 1 && (command[0] == '\x87' || command[0] == "set_powerstat"))
|
||||
{
|
||||
setCommand = true;
|
||||
if (command[1] == "0")
|
||||
|
|
121
rthandler.cpp
121
rthandler.cpp
|
@ -6,7 +6,7 @@
|
|||
#include <objbase.h>
|
||||
#endif
|
||||
|
||||
#define RT_EXCEPTION
|
||||
#undef RT_EXCEPTION
|
||||
|
||||
rtHandler::rtHandler(QObject* parent)
|
||||
{
|
||||
|
@ -55,16 +55,20 @@ bool rtHandler::init(audioSetup setup)
|
|||
return false;
|
||||
}
|
||||
|
||||
inFormat = toQAudioFormat(setup.codec, setup.sampleRate);
|
||||
radioFormat = toQAudioFormat(setup.codec, setup.sampleRate);
|
||||
|
||||
qDebug(logAudio()) << "Creating" << (setup.isinput ? "Input" : "Output") << "audio device:" << setup.name <<
|
||||
", bits" << inFormat.sampleSize() <<
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
", bits" << radioFormat.sampleSize() <<
|
||||
#else
|
||||
", format" << radioFormat.sampleFormat() <<
|
||||
#endif
|
||||
", codec" << setup.codec <<
|
||||
", latency" << setup.latency <<
|
||||
", localAFGain" << setup.localAFgain <<
|
||||
", radioChan" << inFormat.channelCount() <<
|
||||
", radioChan" << radioFormat.channelCount() <<
|
||||
", resampleQuality" << setup.resampleQuality <<
|
||||
", samplerate" << inFormat.sampleRate() <<
|
||||
", samplerate" << radioFormat.sampleRate() <<
|
||||
", uLaw" << setup.ulaw;
|
||||
|
||||
#if !defined(Q_OS_MACX)
|
||||
|
@ -80,6 +84,12 @@ bool rtHandler::init(audioSetup setup)
|
|||
audio = new RtAudio(RtAudio::Api::MACOSX_CORE);
|
||||
#endif
|
||||
|
||||
codecType codec = LPCM;
|
||||
if (setup.codec == 0x01 || setup.codec == 0x20)
|
||||
codec = PCMU;
|
||||
else if (setup.codec == 0x40 || setup.codec == 0x40)
|
||||
codec = OPUS;
|
||||
|
||||
options.numberOfBuffers = int(setup.latency/setup.blockSize);
|
||||
|
||||
if (setup.portInt > 0) {
|
||||
|
@ -104,13 +114,18 @@ bool rtHandler::init(audioSetup setup)
|
|||
goto errorHandler;
|
||||
}
|
||||
#endif
|
||||
#ifdef RT_EXCEPTION
|
||||
if (info.probed)
|
||||
{
|
||||
#endif
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << QString::fromStdString(info.name) << "(" << aParams.deviceId << ") successfully probed";
|
||||
|
||||
RtAudioFormat sampleFormat;
|
||||
outFormat.setByteOrder(QAudioFormat::LittleEndian);
|
||||
outFormat.setCodec("audio/pcm");
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
nativeFormat.setByteOrder(QAudioFormat::LittleEndian);
|
||||
nativeFormat.setCodec("audio/pcm");
|
||||
#endif
|
||||
|
||||
if (info.nativeFormats == 0)
|
||||
{
|
||||
|
@ -128,45 +143,61 @@ bool rtHandler::init(audioSetup setup)
|
|||
|
||||
qInfo(logAudio()) << " Preferred sample rate:" << info.preferredSampleRate;
|
||||
if (setup.isinput) {
|
||||
outFormat.setChannelCount(info.inputChannels);
|
||||
nativeFormat.setChannelCount(info.inputChannels);
|
||||
}
|
||||
else {
|
||||
outFormat.setChannelCount(info.outputChannels);
|
||||
nativeFormat.setChannelCount(info.outputChannels);
|
||||
}
|
||||
|
||||
qInfo(logAudio()) << " Channels:" << outFormat.channelCount();
|
||||
qInfo(logAudio()) << " Channels:" << nativeFormat.channelCount();
|
||||
|
||||
if (outFormat.channelCount() > 2) {
|
||||
outFormat.setChannelCount(2);
|
||||
if (nativeFormat.channelCount() > 2) {
|
||||
nativeFormat.setChannelCount(2);
|
||||
}
|
||||
else if (outFormat.channelCount() < 1)
|
||||
else if (nativeFormat.channelCount() < 1)
|
||||
{
|
||||
qCritical(logAudio()) << (setup.isinput ? "Input" : "Output") << "No channels found, aborting setup.";
|
||||
goto errorHandler;
|
||||
}
|
||||
|
||||
aParams.nChannels = outFormat.channelCount();
|
||||
if (nativeFormat.channelCount() == 1 && radioFormat.channelCount() == 2) {
|
||||
nativeFormat.setChannelCount(2);
|
||||
}
|
||||
|
||||
aParams.nChannels = nativeFormat.channelCount();
|
||||
|
||||
|
||||
outFormat.setSampleRate(info.preferredSampleRate);
|
||||
nativeFormat.setSampleRate(info.preferredSampleRate);
|
||||
|
||||
if (outFormat.sampleRate() < 44100) {
|
||||
outFormat.setSampleRate(48000);
|
||||
if (nativeFormat.sampleRate() < 44100) {
|
||||
nativeFormat.setSampleRate(48000);
|
||||
}
|
||||
|
||||
if (info.nativeFormats & RTAUDIO_FLOAT32) {
|
||||
outFormat.setSampleType(QAudioFormat::Float);
|
||||
outFormat.setSampleSize(32);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
nativeFormat.setSampleType(QAudioFormat::Float);
|
||||
nativeFormat.setSampleSize(32);
|
||||
#else
|
||||
nativeFormat.setSampleFormat(QAudioFormat::Float);
|
||||
#endif
|
||||
sampleFormat = RTAUDIO_FLOAT32;
|
||||
}
|
||||
else if (info.nativeFormats & RTAUDIO_SINT32) {
|
||||
outFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
outFormat.setSampleSize(32);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
nativeFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
nativeFormat.setSampleSize(32);
|
||||
#else
|
||||
nativeFormat.setSampleFormat(QAudioFormat::Int32);
|
||||
#endif
|
||||
sampleFormat = RTAUDIO_SINT32;
|
||||
}
|
||||
else if (info.nativeFormats & RTAUDIO_SINT16) {
|
||||
outFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
outFormat.setSampleSize(16);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
nativeFormat.setSampleType(QAudioFormat::SignedInt);
|
||||
nativeFormat.setSampleSize(16);
|
||||
#else
|
||||
nativeFormat.setSampleFormat(QAudioFormat::Int16);
|
||||
#endif
|
||||
sampleFormat = RTAUDIO_SINT16;
|
||||
}
|
||||
else {
|
||||
|
@ -175,9 +206,13 @@ bool rtHandler::init(audioSetup setup)
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleSize" << outFormat.sampleSize() << "Channel Count" << outFormat.channelCount() <<
|
||||
"Sample Rate" << outFormat.sampleRate() << "Codec" << outFormat.codec() << "Sample Type" << outFormat.sampleType();
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleSize" << nativeFormat.sampleSize() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate() << "Codec" << nativeFormat.codec() << "Sample Type" << nativeFormat.sampleType();
|
||||
#else
|
||||
qDebug(logAudio()) << (setup.isinput ? "Input" : "Output") << "Selected format: SampleFormat" << nativeFormat.sampleFormat() << "Channel Count" << nativeFormat.channelCount() <<
|
||||
"Sample Rate" << nativeFormat.sampleRate() << "Codec" << codec;
|
||||
#endif
|
||||
|
||||
// We "hopefully" now have a valid format that is supported so try connecting
|
||||
converter = new audioConverter();
|
||||
|
@ -190,26 +225,26 @@ bool rtHandler::init(audioSetup setup)
|
|||
}
|
||||
converter->moveToThread(converterThread);
|
||||
|
||||
connect(this, SIGNAL(setupConverter(QAudioFormat, QAudioFormat, quint8, quint8)), converter, SLOT(init(QAudioFormat, QAudioFormat, quint8, quint8)));
|
||||
connect(this, SIGNAL(setupConverter(QAudioFormat, codecType, QAudioFormat, codecType, quint8, quint8)), converter, SLOT(init(QAudioFormat, codecType, QAudioFormat, codecType, quint8, quint8)));
|
||||
connect(converterThread, SIGNAL(finished()), converter, SLOT(deleteLater()));
|
||||
connect(this, SIGNAL(sendToConverter(audioPacket)), converter, SLOT(convert(audioPacket)));
|
||||
converterThread->start(QThread::TimeCriticalPriority);
|
||||
|
||||
|
||||
// Per channel chunk size.
|
||||
this->chunkSize = (outFormat.bytesForDuration(setup.blockSize * 1000) / (outFormat.sampleSize()/8) / outFormat.channelCount());
|
||||
this->chunkSize = nativeFormat.framesForDuration(setup.blockSize * 1000);
|
||||
|
||||
#ifdef RT_EXCEPTION
|
||||
try {
|
||||
#endif
|
||||
if (setup.isinput) {
|
||||
audio->openStream(NULL, &aParams, sampleFormat, outFormat.sampleRate(), &this->chunkSize, &staticWrite, this, &options);
|
||||
emit setupConverter(outFormat, inFormat, 7, setup.resampleQuality);
|
||||
audio->openStream(NULL, &aParams, sampleFormat, nativeFormat.sampleRate(), &this->chunkSize, &staticWrite, this, &options);
|
||||
emit setupConverter(nativeFormat, codecType::LPCM, radioFormat, codec, 7, setup.resampleQuality);
|
||||
connect(converter, SIGNAL(converted(audioPacket)), this, SLOT(convertedInput(audioPacket)));
|
||||
}
|
||||
else {
|
||||
audio->openStream(&aParams, NULL, sampleFormat, outFormat.sampleRate(), &this->chunkSize, &staticRead, this , &options);
|
||||
emit setupConverter(inFormat, outFormat, 7, setup.resampleQuality);
|
||||
audio->openStream(&aParams, NULL, sampleFormat, nativeFormat.sampleRate(), &this->chunkSize, &staticRead, this , &options);
|
||||
emit setupConverter(radioFormat, codec, nativeFormat, codecType::LPCM, 7, setup.resampleQuality);
|
||||
connect(converter, SIGNAL(converted(audioPacket)), this, SLOT(convertedOutput(audioPacket)));
|
||||
}
|
||||
audio->startStream();
|
||||
|
@ -224,13 +259,15 @@ bool rtHandler::init(audioSetup setup)
|
|||
goto errorHandler;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef RT_EXCEPTION
|
||||
}
|
||||
else
|
||||
{
|
||||
qInfo(logAudio()) << (setup.isinput ? "Input" : "Output") << QString::fromStdString(info.name) << "(" << aParams.deviceId << ") could not be probed, check audio configuration!";
|
||||
goto errorHandler;
|
||||
}
|
||||
|
||||
#endif
|
||||
this->setVolume(setup.localAFgain);
|
||||
|
||||
|
||||
|
@ -268,8 +305,7 @@ int rtHandler::readData(void* outputBuffer, void* inputBuffer,
|
|||
{
|
||||
Q_UNUSED(inputBuffer);
|
||||
Q_UNUSED(streamTime);
|
||||
int nBytes = nFrames * outFormat.channelCount() * (outFormat.sampleSize()/8);
|
||||
|
||||
int nBytes = nFrames * nativeFormat.bytesPerFrame();
|
||||
//lastSentSeq = packet.seq;
|
||||
if (arrayBuffer.length() >= nBytes) {
|
||||
if (audioMutex.tryLock(0)) {
|
||||
|
@ -305,8 +341,9 @@ int rtHandler::writeData(void* outputBuffer, void* inputBuffer,
|
|||
packet.sent = 0;
|
||||
packet.volume = volume;
|
||||
memcpy(&packet.guid, setup.guid, GUIDLEN);
|
||||
packet.data.append((char*)inputBuffer, nFrames *outFormat.channelCount() * (outFormat.sampleSize()/8));
|
||||
packet.data.append((char*)inputBuffer, nFrames * nativeFormat.bytesPerFrame());
|
||||
emit sendToConverter(packet);
|
||||
|
||||
if (status == RTAUDIO_INPUT_OVERFLOW) {
|
||||
isUnderrun = true;
|
||||
}
|
||||
|
@ -328,9 +365,9 @@ void rtHandler::convertedOutput(audioPacket packet)
|
|||
audioMutex.lock();
|
||||
arrayBuffer.append(packet.data);
|
||||
audioMutex.unlock();
|
||||
amplitude = packet.amplitudePeak;
|
||||
currentLatency = packet.time.msecsTo(QTime::currentTime()) + (outFormat.durationForBytes(audio->getStreamLatency() * (outFormat.sampleSize() / 8) * outFormat.channelCount())/1000);
|
||||
emit haveLevels(getAmplitude(), packet.amplitudeRMS, setup.latency, currentLatency, isUnderrun, isOverrun);
|
||||
amplitude = packet.amplitudePeak;
|
||||
currentLatency = packet.time.msecsTo(QTime::currentTime()) + (nativeFormat.durationForBytes(audio->getStreamLatency() * nativeFormat.bytesPerFrame()) / 1000);
|
||||
emit haveLevels(getAmplitude(), packet.amplitudeRMS, setup.latency, currentLatency, isUnderrun, isOverrun);
|
||||
}
|
||||
|
||||
|
||||
|
@ -339,9 +376,9 @@ void rtHandler::convertedInput(audioPacket packet)
|
|||
{
|
||||
if (packet.data.size() > 0) {
|
||||
emit haveAudioData(packet);
|
||||
amplitude = packet.amplitudePeak;
|
||||
currentLatency = packet.time.msecsTo(QTime::currentTime()) + (outFormat.durationForBytes(audio->getStreamLatency() * (outFormat.sampleSize() / 8) * outFormat.channelCount())/1000);
|
||||
emit haveLevels(getAmplitude(), static_cast<quint16>(packet.amplitudeRMS * 255.0), setup.latency, currentLatency, isUnderrun, isOverrun);
|
||||
amplitude = packet.amplitudePeak;
|
||||
currentLatency = packet.time.msecsTo(QTime::currentTime()) + (nativeFormat.durationForBytes(audio->getStreamLatency() * nativeFormat.bytesPerFrame()) / 1000);
|
||||
emit haveLevels(getAmplitude(), static_cast<quint16>(packet.amplitudeRMS * 255.0), setup.latency, currentLatency, isUnderrun, isOverrun);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -62,7 +62,7 @@ signals:
|
|||
void sendLatency(quint16 newSize);
|
||||
void haveAudioData(const audioPacket& data);
|
||||
void haveLevels(quint16 amplitudePeak, quint16 amplitudeRMS, quint16 latency, quint16 current, bool under, bool over);
|
||||
void setupConverter(QAudioFormat in, QAudioFormat out, quint8 opus, quint8 resamp);
|
||||
void setupConverter(QAudioFormat in, codecType codecIn, QAudioFormat out, codecType codecOut, quint8 opus, quint8 resamp);
|
||||
void sendToConverter(audioPacket audio);
|
||||
|
||||
private:
|
||||
|
@ -101,8 +101,8 @@ private:
|
|||
qreal volume = 1.0;
|
||||
|
||||
audioSetup setup;
|
||||
QAudioFormat inFormat;
|
||||
QAudioFormat outFormat;
|
||||
QAudioFormat radioFormat;
|
||||
QAudioFormat nativeFormat;
|
||||
audioConverter* converter = Q_NULLPTR;
|
||||
QThread* converterThread = Q_NULLPTR;
|
||||
QByteArray arrayBuffer;
|
||||
|
|
|
@ -60,7 +60,11 @@ void selectRadio::setInUse(quint8 radio, quint8 busy, QString user, QString ip)
|
|||
|
||||
void selectRadio::on_table_cellClicked(int row, int col) {
|
||||
qInfo() << "Clicked on " << row << "," << col;
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(5,11,0))
|
||||
if (ui->table->item(row, col)->backgroundColor() != Qt::darkGreen) {
|
||||
#else
|
||||
if (ui->table->item(row, col)->background() != Qt::darkGreen) {
|
||||
#endif
|
||||
ui->table->selectRow(row);
|
||||
emit selectedRadio(row);
|
||||
this->setVisible(false);
|
||||
|
|
206
servermain.cpp
206
servermain.cpp
|
@ -8,7 +8,7 @@
|
|||
// This code is copyright 2017-2020 Elliott H. Liggett
|
||||
// All rights reserved
|
||||
|
||||
servermain::servermain(const QString settingsFile, const QString logFile)
|
||||
servermain::servermain(const QString settingsFile)
|
||||
{
|
||||
|
||||
qRegisterMetaType <udpPreferences>(); // Needs to be registered early.
|
||||
|
@ -28,6 +28,8 @@ servermain::servermain(const QString settingsFile, const QString logFile)
|
|||
qRegisterMetaType<rigstate*>();
|
||||
qRegisterMetaType<QList<radio_cap_packet>>();
|
||||
qRegisterMetaType<networkStatus>();
|
||||
qRegisterMetaType<codecType>();
|
||||
qRegisterMetaType<errorType>();
|
||||
|
||||
setDefPrefs();
|
||||
|
||||
|
@ -35,6 +37,10 @@ servermain::servermain(const QString settingsFile, const QString logFile)
|
|||
|
||||
loadSettings(); // Look for saved preferences
|
||||
|
||||
audioDev = new audioDevices(prefs.audioSystem, QFontMetrics(QFont()));
|
||||
connect(audioDev, SIGNAL(updated()), this, SLOT(updateAudioDevices()));
|
||||
audioDev->enumerate();
|
||||
|
||||
setInitialTiming();
|
||||
|
||||
openRig();
|
||||
|
@ -62,6 +68,10 @@ servermain::~servermain()
|
|||
serverThread->wait();
|
||||
}
|
||||
|
||||
if (audioDev != Q_NULLPTR) {
|
||||
delete audioDev;
|
||||
}
|
||||
|
||||
delete settings;
|
||||
|
||||
#if defined(PORTAUDIO)
|
||||
|
@ -110,7 +120,7 @@ void servermain::makeRig()
|
|||
connect(radio->rigThread, SIGNAL(finished()), radio->rig, SLOT(deleteLater()));
|
||||
radio->rigThread->start();
|
||||
// Rig status and Errors:
|
||||
connect(radio->rig, SIGNAL(haveSerialPortError(QString, QString)), this, SLOT(receiveSerialPortError(QString, QString)));
|
||||
connect(radio->rig, SIGNAL(havePortError(errorType)), this, SLOT(receivePortError(errorType)));
|
||||
connect(radio->rig, SIGNAL(haveStatusUpdate(networkStatus)), this, SLOT(receiveStatusUpdate(networkStatus)));
|
||||
|
||||
// Rig comm setup:
|
||||
|
@ -319,11 +329,9 @@ void servermain::receiveFoundRigID(rigCapabilities rigCaps)
|
|||
return;
|
||||
}
|
||||
|
||||
void servermain::receiveSerialPortError(QString port, QString errorText)
|
||||
void servermain::receivePortError(errorType err)
|
||||
{
|
||||
qInfo(logSystem()) << "servermain: received serial port error for port: " << port << " with message: " << errorText;
|
||||
|
||||
// TODO: Dialog box, exit, etc
|
||||
qInfo(logSystem()) << "servermain: received error for device: " << err.device << " with message: " << err.message;
|
||||
}
|
||||
|
||||
|
||||
|
@ -527,6 +535,7 @@ void servermain::loadSettings()
|
|||
|
||||
tempPrefs->rig = Q_NULLPTR;
|
||||
tempPrefs->rigThread = Q_NULLPTR;
|
||||
|
||||
serverConfig.rigs.append(tempPrefs);
|
||||
if (tempNum == 0) {
|
||||
settings->endGroup();
|
||||
|
@ -537,167 +546,6 @@ void servermain::loadSettings()
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
Now we have an array of rig objects, we need to match the configured audio devices with physical devices
|
||||
*/
|
||||
switch (prefs.audioSystem)
|
||||
{
|
||||
case rtAudio:
|
||||
{
|
||||
#if defined(Q_OS_LINUX)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::LINUX_ALSA);
|
||||
// RtAudio* audio = new RtAudio(RtAudio::Api::LINUX_PULSE);
|
||||
#elif defined(Q_OS_WIN)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::WINDOWS_WASAPI);
|
||||
#elif defined(Q_OS_MACX)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::MACOSX_CORE);
|
||||
#endif
|
||||
|
||||
// Enumerate audio devices, need to do before settings are loaded.
|
||||
std::map<int, std::string> apiMap;
|
||||
apiMap[RtAudio::MACOSX_CORE] = "OS-X Core Audio";
|
||||
apiMap[RtAudio::WINDOWS_ASIO] = "Windows ASIO";
|
||||
apiMap[RtAudio::WINDOWS_DS] = "Windows DirectSound";
|
||||
apiMap[RtAudio::WINDOWS_WASAPI] = "Windows WASAPI";
|
||||
apiMap[RtAudio::UNIX_JACK] = "Jack Client";
|
||||
apiMap[RtAudio::LINUX_ALSA] = "Linux ALSA";
|
||||
apiMap[RtAudio::LINUX_PULSE] = "Linux PulseAudio";
|
||||
apiMap[RtAudio::LINUX_OSS] = "Linux OSS";
|
||||
apiMap[RtAudio::RTAUDIO_DUMMY] = "RtAudio Dummy";
|
||||
|
||||
std::vector< RtAudio::Api > apis;
|
||||
RtAudio::getCompiledApi(apis);
|
||||
|
||||
qInfo(logAudio()) << "RtAudio Version " << QString::fromStdString(RtAudio::getVersion());
|
||||
|
||||
qInfo(logAudio()) << "Compiled APIs:";
|
||||
for (unsigned int i = 0; i < apis.size(); i++) {
|
||||
qInfo(logAudio()) << " " << QString::fromStdString(apiMap[apis[i]]);
|
||||
}
|
||||
|
||||
RtAudio::DeviceInfo info;
|
||||
|
||||
qInfo(logAudio()) << "Current API: " << QString::fromStdString(apiMap[audio->getCurrentApi()]);
|
||||
|
||||
unsigned int devices = audio->getDeviceCount();
|
||||
qInfo(logAudio()) << "Found " << devices << " audio device(s) *=default";
|
||||
|
||||
for (unsigned int i = 1; i < devices; i++) {
|
||||
info = audio->getDeviceInfo(i);
|
||||
for (RIGCONFIG* rig : serverConfig.rigs)
|
||||
{
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "rxAudio device:" << rig->rxAudioSetup.name;
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "txAudio device:" << rig->txAudioSetup.name;
|
||||
if (info.outputChannels > 0)
|
||||
{
|
||||
qInfo(logAudio()) << (info.isDefaultOutput ? "*" : " ") << "(" << i << ") Output Device : " << QString::fromStdString(info.name);
|
||||
if (rig->txAudioSetup.name.toStdString() == info.name) {
|
||||
rig->txAudioSetup.portInt = i;
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "Selected txAudio device:" << QString(info.name.c_str());
|
||||
}
|
||||
}
|
||||
if (info.inputChannels > 0)
|
||||
{
|
||||
qInfo(logAudio()) << (info.isDefaultInput ? "*" : " ") << "(" << i << ") Input Device : " << QString::fromStdString(info.name);
|
||||
if (rig->rxAudioSetup.name.toStdString() == info.name) {
|
||||
rig->rxAudioSetup.portInt = i;
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "Selected rxAudio device:" << QString(info.name.c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case portAudio:
|
||||
{
|
||||
// Use PortAudio device enumeration
|
||||
|
||||
PaError err;
|
||||
|
||||
err = Pa_Initialize();
|
||||
|
||||
if (err != paNoError)
|
||||
{
|
||||
qInfo(logAudio()) << "ERROR: Cannot initialize Portaudio";
|
||||
}
|
||||
|
||||
qInfo(logAudio()) << "PortAudio version: " << Pa_GetVersionInfo()->versionText;
|
||||
|
||||
int numDevices;
|
||||
numDevices = Pa_GetDeviceCount();
|
||||
qInfo(logAudio()) << "Pa_CountDevices returned" << numDevices;
|
||||
|
||||
const PaDeviceInfo* info;
|
||||
for (int i = 0; i < numDevices; i++)
|
||||
{
|
||||
info = Pa_GetDeviceInfo(i);
|
||||
for (RIGCONFIG* rig : serverConfig.rigs)
|
||||
{
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "rxAudio device:" << rig->rxAudioSetup.name;
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "txAudio device:" << rig->txAudioSetup.name;
|
||||
if (info->maxInputChannels > 0) {
|
||||
qDebug(logAudio()) << (i == Pa_GetDefaultInputDevice() ? "*" : " ") << "(" << i << ") Input Device : " << info->name;
|
||||
|
||||
if (rig->rxAudioSetup.name == info->name) {
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "Selected rxAudio device:" << QString(info->name);
|
||||
rig->rxAudioSetup.portInt = i;
|
||||
}
|
||||
}
|
||||
if (info->maxOutputChannels > 0) {
|
||||
if (rig->txAudioSetup.name == info->name) {
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "Selected txAudio device:" << QString(info->name);
|
||||
rig->txAudioSetup.portInt = i;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case qtAudio:
|
||||
{
|
||||
const auto audioOutputs = QAudioDeviceInfo::availableDevices(QAudio::AudioOutput);
|
||||
const auto audioInputs = QAudioDeviceInfo::availableDevices(QAudio::AudioInput);
|
||||
//qInfo(logAudio()) << "Looking for audio input devices";
|
||||
for (const QAudioDeviceInfo& deviceInfo : audioInputs) {
|
||||
qDebug(logSystem()) << "Found Audio input: " << deviceInfo.deviceName();
|
||||
for (RIGCONFIG* rig : serverConfig.rigs)
|
||||
{
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "rxAudio device:" << rig->rxAudioSetup.name;
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "txAudio device:" << rig->txAudioSetup.name;
|
||||
if (deviceInfo.deviceName() == rig->rxAudioSetup.name
|
||||
#ifdef Q_OS_WIN
|
||||
&& deviceInfo.realm() == "wasapi"
|
||||
#endif
|
||||
)
|
||||
{
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "Selected rxAudio device:" << deviceInfo.deviceName();
|
||||
rig->rxAudioSetup.port = deviceInfo;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//qInfo(logAudio()) << "Looking for audio output devices";
|
||||
for (const QAudioDeviceInfo& deviceInfo : audioOutputs) {
|
||||
qDebug(logSystem()) << "Found Audio output: " << deviceInfo.deviceName();
|
||||
for (RIGCONFIG* rig : serverConfig.rigs)
|
||||
{
|
||||
if (deviceInfo.deviceName() == rig->txAudioSetup.name
|
||||
#ifdef Q_OS_WIN
|
||||
&& deviceInfo.realm() == "wasapi"
|
||||
#endif
|
||||
)
|
||||
{
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "Selected txAudio device:" << deviceInfo.deviceName();
|
||||
rig->txAudioSetup.port = deviceInfo;
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
settings->beginGroup("Server");
|
||||
serverConfig.enabled = settings->value("ServerEnabled", false).toBool();
|
||||
serverConfig.controlPort = settings->value("ServerControlPort", 50001).toInt();
|
||||
|
@ -731,6 +579,30 @@ void servermain::loadSettings()
|
|||
|
||||
}
|
||||
|
||||
void servermain::updateAudioDevices()
|
||||
{
|
||||
|
||||
for (RIGCONFIG* rig : serverConfig.rigs)
|
||||
{
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "configured rxAudio device:" << rig->rxAudioSetup.name;
|
||||
qDebug(logAudio()) << "Rig" << rig->rigName << "configured txAudio device:" << rig->txAudioSetup.name;
|
||||
|
||||
int inputNum = audioDev->findInput(rig->rigName, rig->rxAudioSetup.name);
|
||||
int outputNum = audioDev->findOutput(rig->rigName, rig->txAudioSetup.name);
|
||||
|
||||
if (prefs.audioSystem == qtAudio) {
|
||||
rig->rxAudioSetup.port = audioDev->getInputDeviceInfo(inputNum);
|
||||
rig->txAudioSetup.port = audioDev->getOutputDeviceInfo(outputNum);
|
||||
}
|
||||
else {
|
||||
rig->rxAudioSetup.portInt = audioDev->getInputDeviceInt(inputNum);
|
||||
rig->txAudioSetup.portInt = audioDev->getOutputDeviceInt(outputNum);
|
||||
}
|
||||
rig->rxAudioSetup.name = audioDev->getInputName(inputNum);
|
||||
rig->txAudioSetup.name = audioDev->getOutputName(outputNum);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void servermain::receivePTTstatus(bool pttOn)
|
||||
{
|
||||
|
|
10
servermain.h
10
servermain.h
|
@ -20,6 +20,7 @@
|
|||
#include "freqmemory.h"
|
||||
#include "rigidentities.h"
|
||||
#include "repeaterattributes.h"
|
||||
#include "audiodevices.h"
|
||||
|
||||
#include "udpserver.h"
|
||||
#include "rigctld.h"
|
||||
|
@ -46,7 +47,7 @@ class servermain : public QObject
|
|||
Q_OBJECT
|
||||
|
||||
public:
|
||||
servermain(const QString logFile, const QString settingsFile);
|
||||
servermain(const QString logFile);
|
||||
~servermain();
|
||||
|
||||
signals:
|
||||
|
@ -174,13 +175,14 @@ private slots:
|
|||
void receivePTTstatus(bool pttOn);
|
||||
|
||||
void receiveFoundRigID(rigCapabilities rigCaps);
|
||||
void receiveSerialPortError(QString port, QString errorText);
|
||||
void receivePortError(errorType err);
|
||||
void receiveBaudRate(quint32 baudrate);
|
||||
|
||||
void handlePttLimit();
|
||||
void receiveStatusUpdate(networkStatus status);
|
||||
void receiveStateInfo(rigstate* state);
|
||||
void connectToRig(RIGCONFIG* rig);
|
||||
void updateAudioDevices();
|
||||
|
||||
private:
|
||||
QSettings *settings=Q_NULLPTR;
|
||||
|
@ -282,6 +284,8 @@ private:
|
|||
|
||||
rigstate* rigState = Q_NULLPTR;
|
||||
|
||||
audioDevices* audioDev = Q_NULLPTR;
|
||||
|
||||
SERVERCONFIG serverConfig;
|
||||
};
|
||||
|
||||
|
@ -300,6 +304,8 @@ Q_DECLARE_METATYPE(QList<radio_cap_packet>)
|
|||
Q_DECLARE_METATYPE(enum meterKind)
|
||||
Q_DECLARE_METATYPE(enum spectrumMode)
|
||||
Q_DECLARE_METATYPE(rigstate*)
|
||||
Q_DECLARE_METATYPE(codecType)
|
||||
Q_DECLARE_METATYPE(errorType)
|
||||
|
||||
|
||||
#endif // WFMAIN_H
|
||||
|
|
|
@ -127,7 +127,7 @@ void udpAudio::receiveAudioData(audioPacket audio) {
|
|||
QByteArray partial = audio.data.mid(len, 1364);
|
||||
audio_packet p;
|
||||
memset(p.packet, 0x0, sizeof(p)); // We can't be sure it is initialized with 0x00!
|
||||
p.len = sizeof(p) + partial.length();
|
||||
p.len = (quint32)sizeof(p) + partial.length();
|
||||
p.sentid = myId;
|
||||
p.rcvdid = remoteId;
|
||||
if (partial.length() == 0xa0) {
|
||||
|
|
|
@ -337,7 +337,7 @@ void udpBase::sendRetransmitRequest()
|
|||
{
|
||||
qInfo(logUdp()) << this->metaObject()->className() << ": sending request for multiple missing packets : " << missingSeqs.toHex(':');
|
||||
missingMutex.lock();
|
||||
p.len = sizeof(p) + missingSeqs.size();
|
||||
p.len = (quint32)sizeof(p) + missingSeqs.size();
|
||||
missingSeqs.insert(0, p.packet, sizeof(p));
|
||||
missingMutex.unlock();
|
||||
|
||||
|
|
|
@ -93,7 +93,7 @@ void udpCivData::send(QByteArray d)
|
|||
//qInfo(logUdp()) << "Sending: (" << d.length() << ") " << d;
|
||||
data_packet p;
|
||||
memset(p.packet, 0x0, sizeof(p)); // We can't be sure it is initialized with 0x00!
|
||||
p.len = sizeof(p) + d.length();
|
||||
p.len = (quint32)sizeof(p) + d.length();
|
||||
p.sentid = myId;
|
||||
p.rcvdid = remoteId;
|
||||
p.reply = (char)0xc1;
|
||||
|
|
|
@ -325,12 +325,12 @@ void udpHandler::dataReceived()
|
|||
if (in->type != 0x01) {
|
||||
if (in->error == 0xffffffff && !streamOpened)
|
||||
{
|
||||
emit haveNetworkError(radioIP.toString(), "Connection failed, wait a few minutes or reboot the radio.");
|
||||
emit haveNetworkError(errorType(true, radioIP.toString(), "Connection failed\ntry rebooting the radio."));
|
||||
qInfo(logUdp()) << this->metaObject()->className() << ": Connection failed, wait a few minutes or reboot the radio.";
|
||||
}
|
||||
else if (in->error == 0x00000000 && in->disc == 0x01)
|
||||
{
|
||||
emit haveNetworkError(radioIP.toString(), "Got radio disconnected.");
|
||||
emit haveNetworkError(errorType(radioIP.toString(), "Got radio disconnected."));
|
||||
qInfo(logUdp()) << this->metaObject()->className() << ": Got radio disconnected.";
|
||||
if (streamOpened) {
|
||||
// Close stream connections but keep connection open to the radio.
|
||||
|
@ -395,7 +395,7 @@ void udpHandler::dataReceived()
|
|||
{
|
||||
if (rxSetup.codec >= 0x40 || txSetup.codec >= 0x40)
|
||||
{
|
||||
emit haveNetworkError(QString("UDP"), QString("Opus codec not supported, forcing LPCM16"));
|
||||
emit haveNetworkError(errorType(QString("UDP"), QString("Opus codec not supported, forcing LPCM16")));
|
||||
if (rxSetup.codec >= 0x40)
|
||||
rxSetup.codec = 0x04;
|
||||
if (txSetup.codec >= 0x40)
|
||||
|
@ -406,7 +406,7 @@ void udpHandler::dataReceived()
|
|||
|
||||
if (in->error == 0xfeffffff)
|
||||
{
|
||||
status.message = "Invalid Username/Password";
|
||||
emit haveNetworkError(errorType(true, radioIP.toString(), "Invalid Username/Password"));
|
||||
qInfo(logUdp()) << this->metaObject()->className() << ": Invalid Username/Password";
|
||||
}
|
||||
else if (!isAuthenticated)
|
||||
|
|
|
@ -62,7 +62,7 @@ public slots:
|
|||
signals:
|
||||
void haveDataFromPort(QByteArray data); // emit this when we have data, connect to rigcommander
|
||||
void haveAudioData(audioPacket data); // emit this when we have data, connect to rigcommander
|
||||
void haveNetworkError(QString, QString);
|
||||
void haveNetworkError(errorType);
|
||||
void haveChangeLatency(quint16 value);
|
||||
void haveSetVolume(unsigned char value);
|
||||
void haveNetworkStatus(networkStatus);
|
||||
|
|
|
@ -806,7 +806,7 @@ void udpServer::commonReceived(QList<CLIENT*>* l, CLIENT* current, QByteArray r)
|
|||
{
|
||||
control_packet_t in = (control_packet_t)r.constData();
|
||||
if (in->type == 0x03) {
|
||||
qInfo(logUdpServer()) << current->ipAddress.toString() << "(" << current->type << "): Received 'are you there'";
|
||||
qInfo(logUdpServer()) << current->ipAddress.toString() << "(" << current->type << "): Received 'Are you there'";
|
||||
current->remoteId = in->sentid;
|
||||
sendControl(current, 0x04, in->seq);
|
||||
} // This is This is "Are you ready" in response to "I am here".
|
||||
|
@ -1283,7 +1283,7 @@ void udpServer::sendCapabilities(CLIENT* c)
|
|||
s.data.append(QByteArray::fromRawData((const char*)r.packet, sizeof(r)));
|
||||
}
|
||||
|
||||
p.len = sizeof(p)+s.data.length();
|
||||
p.len = (quint32)sizeof(p)+s.data.length();
|
||||
p.payloadsize = qToBigEndian((quint16)(sizeof(p) + s.data.length() - 0x10));
|
||||
|
||||
s.data.insert(0,QByteArray::fromRawData((const char*)p.packet, sizeof(p)));
|
||||
|
@ -1688,7 +1688,7 @@ void udpServer::receiveAudioData(const audioPacket& d)
|
|||
if (client != Q_NULLPTR && client->connected && (!memcmp(client->guid, guid, GUIDLEN) || config->rigs.size()== 1)) {
|
||||
audio_packet p;
|
||||
memset(p.packet, 0x0, sizeof(p)); // We can't be sure it is initialized with 0x00!
|
||||
p.len = sizeof(p) + partial.length();
|
||||
p.len = (quint32)sizeof(p) + partial.length();
|
||||
p.sentid = client->myId;
|
||||
p.rcvdid = client->remoteId;
|
||||
p.ident = 0x0080; // audio is always this?
|
||||
|
@ -1823,7 +1823,7 @@ void udpServer::sendRetransmitRequest(CLIENT* c)
|
|||
{
|
||||
qInfo(logUdp()) << this->metaObject()->className() << ": sending request for multiple missing packets : " << missingSeqs.toHex();
|
||||
|
||||
p.len = sizeof(p) + missingSeqs.size();
|
||||
p.len = (quint32)sizeof(p) + missingSeqs.size();
|
||||
missingSeqs.insert(0, p.packet, sizeof(p));
|
||||
|
||||
if (udpMutex.try_lock_for(std::chrono::milliseconds(LOCK_PERIOD)))
|
||||
|
|
424
wfmain.cpp
424
wfmain.cpp
|
@ -76,6 +76,8 @@ wfmain::wfmain(const QString settingsFile, const QString logFile, bool debugMode
|
|||
qRegisterMetaType<QList<spotData>>();
|
||||
qRegisterMetaType<networkStatus>();
|
||||
qRegisterMetaType<networkAudioLevels>();
|
||||
qRegisterMetaType<codecType>();
|
||||
qRegisterMetaType<errorType>();
|
||||
|
||||
haveRigCaps = false;
|
||||
|
||||
|
@ -96,7 +98,10 @@ wfmain::wfmain(const QString settingsFile, const QString logFile, bool debugMode
|
|||
|
||||
loadSettings(); // Look for saved preferences
|
||||
|
||||
setAudioDevicesUI();
|
||||
audioDev = new audioDevices(prefs.audioSystem, QFontMetrics(ui->audioInputCombo->font()));
|
||||
connect(audioDev, SIGNAL(updated()), this, SLOT(setAudioDevicesUI()));
|
||||
audioDev->enumerate();
|
||||
//setAudioDevicesUI(); // no need to call this as it will be called by the updated() signal
|
||||
|
||||
setTuningSteps(); // TODO: Combine into preferences
|
||||
|
||||
|
@ -167,6 +172,7 @@ wfmain::wfmain(const QString settingsFile, const QString logFile, bool debugMode
|
|||
[&](int value) {
|
||||
QToolTip::showText(QCursor::pos(), QString("%1").arg(value*100/255), nullptr);
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
wfmain::~wfmain()
|
||||
|
@ -185,6 +191,10 @@ wfmain::~wfmain()
|
|||
delete rigCtl;
|
||||
}
|
||||
|
||||
if (audioDev != Q_NULLPTR) {
|
||||
delete audioDev;
|
||||
}
|
||||
|
||||
if (prefs.audioSystem == portAudio) {
|
||||
Pa_Terminate();
|
||||
}
|
||||
|
@ -245,7 +255,7 @@ void wfmain::openRig()
|
|||
//TODO: if(hasRunPreviously)
|
||||
|
||||
//TODO: if(useNetwork){...
|
||||
|
||||
|
||||
// } else {
|
||||
|
||||
// if (prefs.fileWasNotFound) {
|
||||
|
@ -496,7 +506,7 @@ void wfmain::makeRig()
|
|||
rigThread->start();
|
||||
|
||||
// Rig status and Errors:
|
||||
connect(rig, SIGNAL(haveSerialPortError(QString, QString)), this, SLOT(receiveSerialPortError(QString, QString)));
|
||||
connect(rig, SIGNAL(havePortError(errorType)), this, SLOT(receivePortError(errorType)));
|
||||
connect(rig, SIGNAL(haveStatusUpdate(networkStatus)), this, SLOT(receiveStatusUpdate(networkStatus)));
|
||||
connect(rig, SIGNAL(haveNetworkAudioLevels(networkAudioLevels)), this, SLOT(receiveNetworkAudioLevels(networkAudioLevels)));
|
||||
connect(rig, SIGNAL(requestRadioSelection(QList<radio_cap_packet>)), this, SLOT(radioSelection(QList<radio_cap_packet>)));
|
||||
|
@ -676,11 +686,17 @@ void wfmain::receiveFoundRigID(rigCapabilities rigCaps)
|
|||
return;
|
||||
}
|
||||
|
||||
void wfmain::receiveSerialPortError(QString port, QString errorText)
|
||||
void wfmain::receivePortError(errorType err)
|
||||
{
|
||||
qInfo(logSystem()) << "wfmain: received serial port error for port: " << port << " with message: " << errorText;
|
||||
ui->statusBar->showMessage(QString("ERROR: using port ").append(port).append(": ").append(errorText), 10000);
|
||||
|
||||
if (err.alert) {
|
||||
connectionHandler(false); // Force disconnect
|
||||
QMessageBox::critical(this, err.device, err.message, QMessageBox::Ok);
|
||||
}
|
||||
else
|
||||
{
|
||||
qInfo(logSystem()) << "wfmain: received error for device: " << err.device << " with message: " << err.message;
|
||||
ui->statusBar->showMessage(QString("ERROR: using device ").append(err.device).append(": ").append(err.message), 10000);
|
||||
}
|
||||
// TODO: Dialog box, exit, etc
|
||||
}
|
||||
|
||||
|
@ -1414,7 +1430,11 @@ void wfmain::setupKeyShortcuts()
|
|||
connect(keyM, SIGNAL(activated()), this, SLOT(shortcutM()));
|
||||
|
||||
keyDebug = new QShortcut(this);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6,0,0))
|
||||
keyDebug->setKey(Qt::CTRL + Qt::SHIFT + Qt::Key_D);
|
||||
#else
|
||||
keyDebug->setKey(Qt::CTRL + Qt::Key_D);
|
||||
#endif
|
||||
connect(keyDebug, SIGNAL(activated()), this, SLOT(on_debugBtn_clicked()));
|
||||
}
|
||||
|
||||
|
@ -1910,7 +1930,7 @@ void wfmain::loadSettings()
|
|||
|
||||
rigTemp->baudRate = prefs.serialPortBaud;
|
||||
rigTemp->civAddr = prefs.radioCIVAddr;
|
||||
rigTemp->serialPort = prefs.serialPortBaud;
|
||||
rigTemp->serialPort = prefs.serialPortRadio;
|
||||
|
||||
QString guid = settings->value("GUID", "").toString();
|
||||
if (guid.isEmpty()) {
|
||||
|
@ -2375,17 +2395,15 @@ void wfmain::on_serverRXAudioInputCombo_currentIndexChanged(int value)
|
|||
if (!serverConfig.rigs.isEmpty())
|
||||
{
|
||||
if (prefs.audioSystem == qtAudio) {
|
||||
QVariant v = ui->serverRXAudioInputCombo->itemData(value);
|
||||
serverConfig.rigs.first()->rxAudioSetup.port = v.value<QAudioDeviceInfo>();
|
||||
serverConfig.rigs.first()->rxAudioSetup.port = audioDev->getInputDeviceInfo(value);
|
||||
}
|
||||
else {
|
||||
serverConfig.rigs.first()->rxAudioSetup.portInt = ui->serverRXAudioInputCombo->itemData(value).toInt();
|
||||
serverConfig.rigs.first()->rxAudioSetup.portInt = audioDev->getInputDeviceInt(value);
|
||||
}
|
||||
|
||||
serverConfig.rigs.first()->rxAudioSetup.name = ui->serverRXAudioInputCombo->itemText(value);
|
||||
serverConfig.rigs.first()->rxAudioSetup.name = audioDev->getInputName(value);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
void wfmain::on_serverTXAudioOutputCombo_currentIndexChanged(int value)
|
||||
|
@ -2394,14 +2412,13 @@ void wfmain::on_serverTXAudioOutputCombo_currentIndexChanged(int value)
|
|||
if (!serverConfig.rigs.isEmpty())
|
||||
{
|
||||
if (prefs.audioSystem == qtAudio) {
|
||||
QVariant v = ui->serverTXAudioOutputCombo->itemData(value);
|
||||
serverConfig.rigs.first()->txAudioSetup.port = v.value<QAudioDeviceInfo>();
|
||||
serverConfig.rigs.first()->txAudioSetup.port = audioDev->getOutputDeviceInfo(value);
|
||||
}
|
||||
else {
|
||||
serverConfig.rigs.first()->txAudioSetup.portInt = ui->serverTXAudioOutputCombo->itemData(value).toInt();
|
||||
serverConfig.rigs.first()->txAudioSetup.portInt = audioDev->getOutputDeviceInt(value);
|
||||
}
|
||||
|
||||
serverConfig.rigs.first()->txAudioSetup.name = ui->serverTXAudioOutputCombo->itemText(value);
|
||||
serverConfig.rigs.first()->txAudioSetup.name = audioDev->getOutputName(value);
|
||||
}
|
||||
|
||||
|
||||
|
@ -3716,7 +3733,7 @@ void wfmain::sendRadioCommandLoop()
|
|||
if(haveRigCaps && !slowPollCmdQueue.empty())
|
||||
{
|
||||
|
||||
int nCmds = slowPollCmdQueue.size();
|
||||
int nCmds = (int)slowPollCmdQueue.size();
|
||||
cmds sCmd = slowPollCmdQueue[(slowCmdNum++)%nCmds];
|
||||
doCmd(sCmd);
|
||||
}
|
||||
|
@ -3726,7 +3743,7 @@ void wfmain::sendRadioCommandLoop()
|
|||
// s-meter or other metering
|
||||
if(haveRigCaps && !periodicCmdQueue.empty())
|
||||
{
|
||||
int nCmds = periodicCmdQueue.size();
|
||||
int nCmds = (int)periodicCmdQueue.size();
|
||||
cmds pcmd = periodicCmdQueue[ (pCmdNum++)%nCmds ];
|
||||
doCmd(pcmd);
|
||||
}
|
||||
|
@ -5542,14 +5559,13 @@ void wfmain::on_audioOutputCombo_currentIndexChanged(int value)
|
|||
{
|
||||
|
||||
if (prefs.audioSystem == qtAudio) {
|
||||
QVariant v = ui->audioOutputCombo->itemData(value);
|
||||
rxSetup.port = v.value<QAudioDeviceInfo>();
|
||||
rxSetup.port = audioDev->getOutputDeviceInfo(value);
|
||||
}
|
||||
else {
|
||||
rxSetup.portInt = ui->audioOutputCombo->itemData(value).toInt();
|
||||
rxSetup.portInt = audioDev->getOutputDeviceInt(value);
|
||||
}
|
||||
|
||||
rxSetup.name = ui->audioOutputCombo->itemText(value);
|
||||
rxSetup.name = audioDev->getOutputName(value);
|
||||
qDebug(logGui()) << "Changed audio output to:" << rxSetup.name;
|
||||
}
|
||||
|
||||
|
@ -5557,24 +5573,21 @@ void wfmain::on_audioInputCombo_currentIndexChanged(int value)
|
|||
{
|
||||
|
||||
if (prefs.audioSystem == qtAudio) {
|
||||
QVariant v = ui->audioInputCombo->itemData(value);
|
||||
txSetup.port = v.value<QAudioDeviceInfo>();
|
||||
txSetup.port = audioDev->getInputDeviceInfo(value);
|
||||
}
|
||||
else {
|
||||
txSetup.portInt = ui->audioInputCombo->itemData(value).toInt();
|
||||
txSetup.portInt = audioDev->getInputDeviceInt(value);
|
||||
}
|
||||
|
||||
txSetup.name = ui->audioInputCombo->itemText(value);
|
||||
txSetup.name = audioDev->getInputName(value);
|
||||
|
||||
qDebug(logGui()) << "Changed audio input to:" << txSetup.name;
|
||||
}
|
||||
|
||||
void wfmain::on_audioSampleRateCombo_currentIndexChanged(QString text)
|
||||
void wfmain::on_audioSampleRateCombo_currentIndexChanged(int value)
|
||||
{
|
||||
//udpPrefs.audioRXSampleRate = text.toInt();
|
||||
//udpPrefs.audioTXSampleRate = text.toInt();
|
||||
rxSetup.sampleRate=text.toInt();
|
||||
txSetup.sampleRate=text.toInt();
|
||||
rxSetup.sampleRate= ui->audioSampleRateCombo->itemText(value).toInt();
|
||||
txSetup.sampleRate= ui->audioSampleRateCombo->itemText(value).toInt();
|
||||
}
|
||||
|
||||
void wfmain::on_audioRXCodecCombo_currentIndexChanged(int value)
|
||||
|
@ -5637,26 +5650,14 @@ void wfmain::on_connectBtn_clicked()
|
|||
{
|
||||
this->rigStatus->setText(""); // Clear status
|
||||
|
||||
if (haveRigCaps) {
|
||||
emit sendCloseComm();
|
||||
ui->connectBtn->setText("Connect to Radio");
|
||||
ui->audioSystemCombo->setEnabled(true);
|
||||
ui->audioSystemServerCombo->setEnabled(true);
|
||||
haveRigCaps = false;
|
||||
rigName->setText("NONE");
|
||||
if (ui->connectBtn->text() == "Connect to Radio") {
|
||||
connectionHandler(true);
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
emit sendCloseComm(); // Just in case there is a failed connection open.
|
||||
if (ui->connectBtn->text() != "Cancel connection") {
|
||||
openRig();
|
||||
}
|
||||
else {
|
||||
ui->connectBtn->setText("Connect to Radio");
|
||||
ui->audioSystemCombo->setEnabled(true);
|
||||
ui->audioSystemServerCombo->setEnabled(true);
|
||||
}
|
||||
connectionHandler(false);
|
||||
}
|
||||
|
||||
ui->connectBtn->clearFocus();
|
||||
}
|
||||
|
||||
|
@ -6125,7 +6126,7 @@ void wfmain::on_tuneLockChk_clicked(bool checked)
|
|||
freqLock = checked;
|
||||
}
|
||||
|
||||
void wfmain::on_serialDeviceListCombo_activated(const QString &arg1)
|
||||
void wfmain::on_serialDeviceListCombo_textActivated(const QString &arg1)
|
||||
{
|
||||
QString manualPort;
|
||||
bool ok;
|
||||
|
@ -6750,294 +6751,57 @@ void wfmain::on_radioStatusBtn_clicked()
|
|||
|
||||
void wfmain::setAudioDevicesUI()
|
||||
{
|
||||
|
||||
// Enumerate audio devices, need to do before settings are loaded,
|
||||
// First clear all existing entries
|
||||
ui->audioInputCombo->blockSignals(true);
|
||||
ui->audioOutputCombo->blockSignals(true);
|
||||
ui->serverTXAudioOutputCombo->blockSignals(true);
|
||||
ui->serverRXAudioInputCombo->blockSignals(true);
|
||||
|
||||
ui->audioInputCombo->clear();
|
||||
ui->audioOutputCombo->clear();
|
||||
ui->serverTXAudioOutputCombo->clear();
|
||||
ui->serverRXAudioInputCombo->clear();
|
||||
|
||||
qDebug(logSystem()) << "Finding audio devices, output=" << rxSetup.name << "input=" << txSetup.name;
|
||||
|
||||
int defaultAudioInputIndex = 0;
|
||||
int defaultAudioOutputIndex = 0;
|
||||
int numCharsIn = 0;
|
||||
int numCharsOut = 0;
|
||||
QFontMetrics fm(ui->audioInputCombo->font());
|
||||
|
||||
ui->audioInputCombo->addItems(audioDev->getInputs());
|
||||
ui->audioInputCombo->setCurrentIndex(-1);
|
||||
ui->audioOutputCombo->setCurrentIndex(-1);
|
||||
ui->serverRXAudioInputCombo->setCurrentIndex(-1);
|
||||
ui->serverTXAudioOutputCombo->setCurrentIndex(-1);
|
||||
QString defaultAudioInputName;
|
||||
QString defaultAudioOutputName;
|
||||
|
||||
switch (prefs.audioSystem)
|
||||
{
|
||||
case qtAudio:
|
||||
{
|
||||
Pa_Terminate();
|
||||
|
||||
int inCount = 0;
|
||||
foreach(const QAudioDeviceInfo & deviceInfo, QAudioDeviceInfo::availableDevices(QAudio::AudioInput))
|
||||
{
|
||||
if (inCount == 0)
|
||||
defaultAudioInputName = QString(deviceInfo.deviceName().toLocal8Bit());
|
||||
#ifdef Q_OS_WIN
|
||||
if (deviceInfo.realm() == "wasapi") {
|
||||
#endif
|
||||
ui->audioInputCombo->addItem(deviceInfo.deviceName().toLocal8Bit(), QVariant::fromValue(deviceInfo));
|
||||
ui->serverRXAudioInputCombo->addItem(deviceInfo.deviceName().toLocal8Bit(), QVariant::fromValue(deviceInfo));
|
||||
if (fm.boundingRect(deviceInfo.deviceName()).width() > numCharsIn)
|
||||
numCharsIn = fm.boundingRect(deviceInfo.deviceName()).width();
|
||||
#ifdef Q_OS_WIN
|
||||
}
|
||||
#endif
|
||||
inCount++;
|
||||
}
|
||||
|
||||
int outCount = 0;
|
||||
foreach(const QAudioDeviceInfo & deviceInfo, QAudioDeviceInfo::availableDevices(QAudio::AudioOutput))
|
||||
{
|
||||
if (outCount == 0)
|
||||
defaultAudioOutputName = QString(deviceInfo.deviceName().toLocal8Bit());
|
||||
#ifdef Q_OS_WIN
|
||||
if (deviceInfo.realm() == "wasapi") {
|
||||
#endif
|
||||
ui->audioOutputCombo->addItem(deviceInfo.deviceName().toLocal8Bit(), QVariant::fromValue(deviceInfo));
|
||||
ui->serverTXAudioOutputCombo->addItem(deviceInfo.deviceName().toLocal8Bit(), QVariant::fromValue(deviceInfo));
|
||||
if (fm.boundingRect(deviceInfo.deviceName()).width() > numCharsOut)
|
||||
numCharsOut = fm.boundingRect(deviceInfo.deviceName()).width();
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
}
|
||||
#endif
|
||||
outCount++;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case portAudio:
|
||||
{
|
||||
PaError err;
|
||||
|
||||
err = Pa_Initialize();
|
||||
|
||||
if (err != paNoError)
|
||||
{
|
||||
qInfo(logAudio()) << "ERROR: Cannot initialize Portaudio";
|
||||
return;
|
||||
}
|
||||
|
||||
qInfo(logAudio()) << "PortAudio version: " << Pa_GetVersionInfo()->versionText;
|
||||
|
||||
int numDevices = Pa_GetDeviceCount();
|
||||
qInfo(logAudio()) << "Pa_CountDevices returned" << numDevices;
|
||||
|
||||
const PaDeviceInfo* info;
|
||||
for (int i = 0; i < numDevices; i++)
|
||||
{
|
||||
info = Pa_GetDeviceInfo(i);
|
||||
if (info->maxInputChannels > 0) {
|
||||
qDebug(logAudio()) << (i == Pa_GetDefaultInputDevice() ? "*" : " ") << "(" << i << ") Input Device : " << QString(info->name).toLocal8Bit();
|
||||
|
||||
ui->audioInputCombo->addItem(QString(info->name).toLocal8Bit(), i);
|
||||
ui->serverRXAudioInputCombo->addItem(QString(info->name).toLocal8Bit(), i);
|
||||
|
||||
if (fm.boundingRect(QString(info->name)).width() > numCharsIn)
|
||||
numCharsIn = fm.boundingRect(QString(info->name)).width();
|
||||
|
||||
if (i == Pa_GetDefaultInputDevice()) {
|
||||
defaultAudioInputName = info->name;
|
||||
}
|
||||
}
|
||||
if (info->maxOutputChannels > 0) {
|
||||
qDebug(logAudio()) << (i == Pa_GetDefaultOutputDevice() ? "*" : " ") << "(" << i << ") Output Device : " << QString(info->name).toLocal8Bit();
|
||||
ui->audioOutputCombo->addItem(QString(info->name).toLocal8Bit(), i);
|
||||
ui->serverTXAudioOutputCombo->addItem(QString(info->name).toLocal8Bit(), i);
|
||||
|
||||
if (fm.boundingRect(QString(info->name)).width() > numCharsOut)
|
||||
numCharsOut = fm.boundingRect(QString(info->name)).width();
|
||||
|
||||
if (i == Pa_GetDefaultOutputDevice()) {
|
||||
defaultAudioOutputName = info->name;
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case rtAudio:
|
||||
{
|
||||
Pa_Terminate();
|
||||
|
||||
#if defined(Q_OS_LINUX)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::LINUX_ALSA);
|
||||
#elif defined(Q_OS_WIN)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::WINDOWS_WASAPI);
|
||||
#elif defined(Q_OS_MACX)
|
||||
RtAudio* audio = new RtAudio(RtAudio::Api::MACOSX_CORE);
|
||||
#endif
|
||||
|
||||
|
||||
// Enumerate audio devices, need to do before settings are loaded.
|
||||
std::map<int, std::string> apiMap;
|
||||
apiMap[RtAudio::MACOSX_CORE] = "OS-X Core Audio";
|
||||
apiMap[RtAudio::WINDOWS_ASIO] = "Windows ASIO";
|
||||
apiMap[RtAudio::WINDOWS_DS] = "Windows DirectSound";
|
||||
apiMap[RtAudio::WINDOWS_WASAPI] = "Windows WASAPI";
|
||||
apiMap[RtAudio::UNIX_JACK] = "Jack Client";
|
||||
apiMap[RtAudio::LINUX_ALSA] = "Linux ALSA";
|
||||
apiMap[RtAudio::LINUX_PULSE] = "Linux PulseAudio";
|
||||
apiMap[RtAudio::LINUX_OSS] = "Linux OSS";
|
||||
apiMap[RtAudio::RTAUDIO_DUMMY] = "RtAudio Dummy";
|
||||
|
||||
std::vector< RtAudio::Api > apis;
|
||||
RtAudio::getCompiledApi(apis);
|
||||
|
||||
qInfo(logAudio()) << "RtAudio Version " << QString::fromStdString(RtAudio::getVersion());
|
||||
|
||||
qInfo(logAudio()) << "Compiled APIs:";
|
||||
for (unsigned int i = 0; i < apis.size(); i++) {
|
||||
qInfo(logAudio()) << " " << QString::fromStdString(apiMap[apis[i]]);
|
||||
}
|
||||
|
||||
RtAudio::DeviceInfo info;
|
||||
|
||||
qInfo(logAudio()) << "Current API: " << QString::fromStdString(apiMap[audio->getCurrentApi()]);
|
||||
|
||||
unsigned int devices = audio->getDeviceCount();
|
||||
qInfo(logAudio()) << "Found " << devices << " audio device(s) *=default";
|
||||
|
||||
for (unsigned int i = 1; i < devices; i++) {
|
||||
info = audio->getDeviceInfo(i);
|
||||
if (info.inputChannels > 0) {
|
||||
qInfo(logAudio()) << (info.isDefaultInput ? "*" : " ") << "(" << i << ") Input Device : " << QString::fromStdString(info.name).toLocal8Bit();
|
||||
ui->audioInputCombo->addItem(QString::fromStdString(info.name).toLocal8Bit(), i);
|
||||
ui->serverRXAudioInputCombo->addItem(QString::fromStdString(info.name).toLocal8Bit(), i);
|
||||
|
||||
if (fm.boundingRect(QString::fromStdString(info.name)).width() > numCharsIn)
|
||||
numCharsIn = fm.boundingRect(QString::fromStdString(info.name)).width();
|
||||
|
||||
if (info.isDefaultInput) {
|
||||
defaultAudioInputName = QString::fromStdString(info.name).toLocal8Bit();
|
||||
}
|
||||
}
|
||||
if (info.outputChannels > 0) {
|
||||
qInfo(logAudio()) << (info.isDefaultOutput ? "*" : " ") << "(" << i << ") Output Device : " << QString::fromStdString(info.name).toLocal8Bit();
|
||||
ui->audioOutputCombo->addItem(QString::fromStdString(info.name).toLocal8Bit(), i);
|
||||
ui->serverTXAudioOutputCombo->addItem(QString::fromStdString(info.name).toLocal8Bit(), i);
|
||||
|
||||
if (fm.boundingRect(QString::fromStdString(info.name)).width() > numCharsOut)
|
||||
numCharsOut = fm.boundingRect(QString::fromStdString(info.name)).width();
|
||||
|
||||
if (info.isDefaultOutput) {
|
||||
defaultAudioOutputName = QString::fromStdString(info.name).toLocal8Bit();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
delete audio;
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Make the audio comboboxes expand when clicked (only needed for Windows)
|
||||
ui->audioInputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(numCharsIn+30));
|
||||
ui->audioOutputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(numCharsOut+30));
|
||||
ui->serverTXAudioOutputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(numCharsOut+30));
|
||||
ui->serverRXAudioInputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(numCharsIn+30));
|
||||
|
||||
|
||||
// Stop blocking signals so we can set the current values
|
||||
ui->audioInputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(audioDev->getNumCharsIn() + 30));
|
||||
ui->audioInputCombo->blockSignals(false);
|
||||
ui->audioOutputCombo->blockSignals(false);
|
||||
ui->serverTXAudioOutputCombo->blockSignals(false);
|
||||
ui->serverRXAudioInputCombo->blockSignals(false);
|
||||
ui->audioInputCombo->setCurrentIndex(audioDev->findInput("Client", txSetup.name));
|
||||
|
||||
ui->audioOutputCombo->blockSignals(true);
|
||||
ui->audioOutputCombo->clear();
|
||||
ui->audioOutputCombo->addItems(audioDev->getOutputs());
|
||||
ui->audioOutputCombo->setCurrentIndex(-1);
|
||||
ui->audioOutputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(audioDev->getNumCharsOut() + 30));
|
||||
ui->audioOutputCombo->blockSignals(false);
|
||||
ui->audioOutputCombo->setCurrentIndex(audioDev->findOutput("Client", rxSetup.name));
|
||||
|
||||
ui->serverTXAudioOutputCombo->blockSignals(true);
|
||||
ui->serverTXAudioOutputCombo->clear();
|
||||
ui->serverTXAudioOutputCombo->addItems(audioDev->getOutputs());
|
||||
ui->serverTXAudioOutputCombo->setCurrentIndex(-1);
|
||||
ui->serverTXAudioOutputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(audioDev->getNumCharsOut() + 30));
|
||||
ui->serverTXAudioOutputCombo->blockSignals(false);
|
||||
|
||||
ui->serverRXAudioInputCombo->blockSignals(true);
|
||||
ui->serverRXAudioInputCombo->clear();
|
||||
ui->serverRXAudioInputCombo->addItems(audioDev->getInputs());
|
||||
ui->serverRXAudioInputCombo->setCurrentIndex(-1);
|
||||
ui->serverRXAudioInputCombo->setStyleSheet(QString("QComboBox QAbstractItemView {min-width: %1px;}").arg(audioDev->getNumCharsIn()+30));
|
||||
ui->serverRXAudioInputCombo->blockSignals(false);
|
||||
|
||||
rxSetup.type = prefs.audioSystem;
|
||||
txSetup.type = prefs.audioSystem;
|
||||
|
||||
int audioInputIndex = ui->audioInputCombo->findText(txSetup.name);
|
||||
if (audioInputIndex != -1) {
|
||||
qInfo(logGui()) << "Found Audio Input Device: " << txSetup.name;
|
||||
ui->audioInputCombo->setCurrentIndex(audioInputIndex);
|
||||
}
|
||||
else {
|
||||
qWarning(logGui()) << "Audio Input Device: " << txSetup.name << "Not Found, trying to select default";
|
||||
audioInputIndex = ui->audioInputCombo->findText(defaultAudioInputName);
|
||||
if (audioInputIndex != -1) {
|
||||
ui->audioInputCombo->setCurrentIndex(audioInputIndex);
|
||||
}
|
||||
else {
|
||||
qWarning(logGui()) << "Unable to select default input device,"<< defaultAudioInputName << " help.....";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
int audioOutputIndex = ui->audioOutputCombo->findText(rxSetup.name.toLocal8Bit());
|
||||
if (audioOutputIndex != -1) {
|
||||
qInfo(logGui()) << "Found Audio Output Device: " << rxSetup.name.toLocal8Bit();
|
||||
ui->audioOutputCombo->setCurrentIndex(audioOutputIndex);
|
||||
}
|
||||
else {
|
||||
qWarning(logGui()) << "Audio output Device: " << rxSetup.name << "Not Found, trying to select default";
|
||||
audioOutputIndex = ui->audioOutputCombo->findText(defaultAudioOutputName.toLocal8Bit());
|
||||
if (audioOutputIndex != -1) {
|
||||
ui->audioOutputCombo->setCurrentIndex(audioOutputIndex);
|
||||
}
|
||||
else {
|
||||
qWarning(logGui()) << "Unable to select default output device," << defaultAudioOutputName.toLocal8Bit() << " help.....";
|
||||
}
|
||||
}
|
||||
|
||||
if (!serverConfig.rigs.isEmpty())
|
||||
|
||||
{
|
||||
if (serverConfig.enabled)
|
||||
qInfo(logGui()) << "Got Server Audio Input: " << serverConfig.rigs.first()->rxAudioSetup.name.toLocal8Bit();
|
||||
|
||||
serverConfig.rigs.first()->rxAudioSetup.type = prefs.audioSystem;
|
||||
serverConfig.rigs.first()->txAudioSetup.type = prefs.audioSystem;
|
||||
|
||||
ui->serverRXAudioInputCombo->setCurrentIndex(defaultAudioInputIndex);
|
||||
int serverAudioInputIndex = ui->serverRXAudioInputCombo->findText(serverConfig.rigs.first()->rxAudioSetup.name.toLocal8Bit());
|
||||
if (serverAudioInputIndex != -1) {
|
||||
ui->serverRXAudioInputCombo->setCurrentIndex(serverAudioInputIndex);
|
||||
}
|
||||
else {
|
||||
if (serverConfig.enabled)
|
||||
qWarning(logGui()) << "Server audio input NOT FOUND " << serverConfig.rigs.first()->rxAudioSetup.name.toLocal8Bit() << "not selecting default";
|
||||
}
|
||||
|
||||
if (serverConfig.enabled)
|
||||
qInfo(logGui()) << "Got Server Audio Output: " << serverConfig.rigs.first()->txAudioSetup.name.toLocal8Bit();
|
||||
|
||||
ui->serverTXAudioOutputCombo->setCurrentIndex(defaultAudioOutputIndex);
|
||||
int serverAudioOutputIndex = ui->serverTXAudioOutputCombo->findText(serverConfig.rigs.first()->txAudioSetup.name.toLocal8Bit());
|
||||
if (serverAudioOutputIndex != -1) {
|
||||
ui->serverTXAudioOutputCombo->setCurrentIndex(serverAudioOutputIndex);
|
||||
}
|
||||
else {
|
||||
if (serverConfig.enabled)
|
||||
qWarning(logGui()) << "Server audio output NOT FOUND " << serverConfig.rigs.first()->txAudioSetup.name.toLocal8Bit() << "not selecting default";
|
||||
}
|
||||
|
||||
ui->serverRXAudioInputCombo->setCurrentIndex(audioDev->findInput("Server", serverConfig.rigs.first()->rxAudioSetup.name));
|
||||
ui->serverTXAudioOutputCombo->setCurrentIndex(audioDev->findOutput("Server", serverConfig.rigs.first()->txAudioSetup.name));
|
||||
}
|
||||
|
||||
|
||||
qDebug(logSystem()) << "Audio devices done.";
|
||||
}
|
||||
|
||||
void wfmain::on_audioSystemCombo_currentIndexChanged(int value)
|
||||
{
|
||||
prefs.audioSystem = static_cast<audioType>(value);
|
||||
setAudioDevicesUI(); // Force all audio devices to update
|
||||
audioDev->setAudioType(prefs.audioSystem);
|
||||
audioDev->enumerate();
|
||||
ui->audioSystemServerCombo->blockSignals(true);
|
||||
ui->audioSystemServerCombo->setCurrentIndex(value);
|
||||
ui->audioSystemServerCombo->blockSignals(false);
|
||||
|
@ -7046,7 +6810,8 @@ void wfmain::on_audioSystemCombo_currentIndexChanged(int value)
|
|||
void wfmain::on_audioSystemServerCombo_currentIndexChanged(int value)
|
||||
{
|
||||
prefs.audioSystem = static_cast<audioType>(value);
|
||||
setAudioDevicesUI(); // Force all audio devices to update
|
||||
audioDev->setAudioType(prefs.audioSystem);
|
||||
audioDev->enumerate();
|
||||
ui->audioSystemCombo->blockSignals(true);
|
||||
ui->audioSystemCombo->setCurrentIndex(value);
|
||||
ui->audioSystemCombo->blockSignals(false);
|
||||
|
@ -8292,3 +8057,28 @@ void wfmain::changePollTiming(int timing_ms, bool setUI)
|
|||
ui->pollTimeMsSpin->blockSignals(false);
|
||||
}
|
||||
}
|
||||
|
||||
void wfmain::connectionHandler(bool connect)
|
||||
{
|
||||
|
||||
if (!connect) {
|
||||
emit sendCloseComm();
|
||||
ui->connectBtn->setText("Connect to Radio");
|
||||
ui->audioSystemCombo->setEnabled(true);
|
||||
ui->audioSystemServerCombo->setEnabled(true);
|
||||
haveRigCaps = false;
|
||||
rigName->setText("NONE");
|
||||
}
|
||||
else
|
||||
{
|
||||
emit sendCloseComm(); // Just in case there is a failed connection open.
|
||||
if (ui->connectBtn->text() != "Cancel connection") {
|
||||
openRig();
|
||||
}
|
||||
else {
|
||||
ui->connectBtn->setText("Connect to Radio");
|
||||
ui->audioSystemCombo->setEnabled(true);
|
||||
ui->audioSystemServerCombo->setEnabled(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
18
wfmain.h
18
wfmain.h
|
@ -43,6 +43,7 @@
|
|||
#include "colorprefs.h"
|
||||
#include "loggingwindow.h"
|
||||
#include "cluster.h"
|
||||
#include "audiodevices.h"
|
||||
|
||||
#include <qcustomplot.h>
|
||||
#include <qserialportinfo.h>
|
||||
|
@ -208,8 +209,9 @@ signals:
|
|||
void setClusterTimeout(int timeout);
|
||||
void setClusterSkimmerSpots(bool enable);
|
||||
void setFrequencyRange(double low, double high);
|
||||
|
||||
|
||||
private slots:
|
||||
void setAudioDevicesUI();
|
||||
void updateSizes(int tabIndex);
|
||||
void shortcutF1();
|
||||
void shortcutF2();
|
||||
|
@ -303,7 +305,7 @@ private slots:
|
|||
void receiveAntennaSel(unsigned char ant, bool rx);
|
||||
void receiveRigID(rigCapabilities rigCaps);
|
||||
void receiveFoundRigID(rigCapabilities rigCaps);
|
||||
void receiveSerialPortError(QString port, QString errorText);
|
||||
void receivePortError(errorType err);
|
||||
void receiveStatusUpdate(networkStatus status);
|
||||
void receiveNetworkAudioLevels(networkAudioLevels l);
|
||||
void handlePlotClick(QMouseEvent *);
|
||||
|
@ -450,7 +452,7 @@ private slots:
|
|||
|
||||
void on_audioTXCodecCombo_currentIndexChanged(int value);
|
||||
|
||||
void on_audioSampleRateCombo_currentIndexChanged(QString text);
|
||||
void on_audioSampleRateCombo_currentIndexChanged(int value);
|
||||
|
||||
void on_vspCombo_currentIndexChanged(int value);
|
||||
|
||||
|
@ -488,7 +490,7 @@ private slots:
|
|||
|
||||
void on_tuningStepCombo_currentIndexChanged(int index);
|
||||
|
||||
void on_serialDeviceListCombo_activated(const QString &arg1);
|
||||
void on_serialDeviceListCombo_textActivated(const QString &arg1);
|
||||
|
||||
void on_rptSetupBtn_clicked();
|
||||
|
||||
|
@ -809,7 +811,6 @@ private:
|
|||
void setupMainUI();
|
||||
void setUIToPrefs();
|
||||
void setSerialDevicesUI();
|
||||
void setAudioDevicesUI();
|
||||
void setServerToPrefs();
|
||||
void setupUsbControllerDevice();
|
||||
void setInitialTiming();
|
||||
|
@ -1006,6 +1007,8 @@ private:
|
|||
void changeMode(mode_kind mode);
|
||||
void changeMode(mode_kind mode, bool dataOn);
|
||||
|
||||
void connectionHandler(bool connect);
|
||||
|
||||
cmds meterKindToMeterCommand(meterKind m);
|
||||
|
||||
void updateUsbButtons();
|
||||
|
@ -1084,6 +1087,7 @@ private:
|
|||
QList<clusterSettings> clusters;
|
||||
QMutex clusterMutex;
|
||||
QColor clusterColor;
|
||||
audioDevices* audioDev = Q_NULLPTR;
|
||||
};
|
||||
|
||||
Q_DECLARE_METATYPE(struct rigCapabilities)
|
||||
|
@ -1109,6 +1113,10 @@ Q_DECLARE_METATYPE(QVector <BUTTON>*)
|
|||
Q_DECLARE_METATYPE(struct BUTTON*)
|
||||
Q_DECLARE_METATYPE(QVector <COMMAND>*)
|
||||
Q_DECLARE_METATYPE(const COMMAND*)
|
||||
Q_DECLARE_METATYPE(codecType)
|
||||
Q_DECLARE_METATYPE(errorType)
|
||||
|
||||
//void (*wfmain::logthistext)(QString text) = NULL;
|
||||
|
||||
#endif // WFMAIN_H
|
||||
#endif
|
||||
|
|
|
@ -13,7 +13,7 @@ TEMPLATE = app
|
|||
|
||||
CONFIG += console
|
||||
|
||||
DEFINES += WFVIEW_VERSION=\\\"1.54\\\"
|
||||
DEFINES += WFVIEW_VERSION=\\\"1.56\\\"
|
||||
|
||||
DEFINES += BUILD_WFSERVER
|
||||
|
||||
|
@ -142,7 +142,8 @@ SOURCES += main.cpp\
|
|||
resampler/resample.c \
|
||||
rigctld.cpp \
|
||||
tcpserver.cpp \
|
||||
keyboard.cpp
|
||||
keyboard.cpp \
|
||||
audiodevices.cpp
|
||||
|
||||
HEADERS += servermain.h \
|
||||
commhandler.h \
|
||||
|
@ -170,4 +171,5 @@ HEADERS += servermain.h \
|
|||
tcpserver.h \
|
||||
audiotaper.h \
|
||||
keyboard.h \
|
||||
wfviewtypes.h
|
||||
wfviewtypes.h \
|
||||
audiodevices.h
|
||||
|
|
450
wfserver.vcxproj
450
wfserver.vcxproj
|
@ -1,6 +1,10 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
|
@ -9,6 +13,10 @@
|
|||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}</ProjectGuid>
|
||||
|
@ -16,7 +24,8 @@
|
|||
<Keyword>QtVS_v304</Keyword>
|
||||
<WindowsTargetPlatformVersion>10.0.19041.0</WindowsTargetPlatformVersion>
|
||||
<WindowsTargetPlatformMinVersion>10.0.19041.0</WindowsTargetPlatformMinVersion>
|
||||
<QtMsBuild Condition="'$(QtMsBuild)'=='' or !Exists('$(QtMsBuild)\qt.targets')">$(MSBuildProjectDirectory)\QtMsBuild</QtMsBuild></PropertyGroup>
|
||||
<QtMsBuild Condition="'$(QtMsBuild)'=='' or !Exists('$(QtMsBuild)\qt.targets')">$(MSBuildProjectDirectory)\QtMsBuild</QtMsBuild>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
|
@ -27,6 +36,15 @@
|
|||
<IntermediateDirectory>release\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfserver</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<OutputDirectory>wfview-release\</OutputDirectory>
|
||||
<ATLMinimizesCRunTimeLibraryUsage>false</ATLMinimizesCRunTimeLibraryUsage>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<IntermediateDirectory>release\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfserver</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<OutputDirectory>wfview-debug\</OutputDirectory>
|
||||
|
@ -36,16 +54,78 @@
|
|||
<IntermediateDirectory>debug\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfserver</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /><Target Name="QtMsBuildNotFound" BeforeTargets="CustomBuild;ClCompile" Condition="!Exists('$(QtMsBuild)\qt.targets') or !Exists('$(QtMsBuild)\qt.props')"><Message Importance="High" Text="QtMsBuild: could not locate qt.targets, qt.props; project may not build correctly." /></Target>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<OutputDirectory>wfview-debug\</OutputDirectory>
|
||||
<ATLMinimizesCRunTimeLibraryUsage>false</ATLMinimizesCRunTimeLibraryUsage>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<IntermediateDirectory>debug\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfserver</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<Target Name="QtMsBuildNotFound" BeforeTargets="CustomBuild;ClCompile" Condition="!Exists('$(QtMsBuild)\qt.targets') or !Exists('$(QtMsBuild)\qt.props')">
|
||||
<Message Importance="High" Text="QtMsBuild: could not locate qt.targets, qt.props; project may not build correctly." />
|
||||
</Target>
|
||||
<ImportGroup Label="ExtensionSettings" />
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" /><ImportGroup Condition="Exists('$(QtMsBuild)\qt_defaults.props')"><Import Project="$(QtMsBuild)\qt_defaults.props" /></ImportGroup><PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"><OutDir>wfview-debug\</OutDir><IntDir>debug\</IntDir><TargetName>wfserver</TargetName><IgnoreImportLibrary>true</IgnoreImportLibrary></PropertyGroup><PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"><OutDir>wfview-release\</OutDir><IntDir>release\</IntDir><TargetName>wfserver</TargetName><IgnoreImportLibrary>true</IgnoreImportLibrary><LinkIncremental>false</LinkIncremental></PropertyGroup><PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"><QtInstall>msvc2019</QtInstall><QtModules>core;network;gui;multimedia;widgets;serialport;printsupport</QtModules></PropertyGroup><PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"><QtInstall>msvc2019</QtInstall><QtModules>core;network;gui;multimedia;widgets;serialport;printsupport</QtModules></PropertyGroup><ImportGroup Condition="Exists('$(QtMsBuild)\qt.props')"><Import Project="$(QtMsBuild)\qt.props" /></ImportGroup>
|
||||
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<ImportGroup Condition="Exists('$(QtMsBuild)\qt_defaults.props')">
|
||||
<Import Project="$(QtMsBuild)\qt_defaults.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>wfview-debug\</OutDir>
|
||||
<IntDir>debug\</IntDir>
|
||||
<TargetName>wfserver</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<TargetName>wfserver</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>wfview-release\</OutDir>
|
||||
<IntDir>release\</IntDir>
|
||||
<TargetName>wfserver</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<TargetName>wfserver</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OutDir>wfview-release\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<QtInstall>msvc2019</QtInstall>
|
||||
<QtModules>core;network;gui;multimedia;widgets;serialport;printsupport</QtModules>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="QtSettings">
|
||||
<QtInstall>msvc2019_64_v62</QtInstall>
|
||||
<QtModules>core;network;gui;multimedia;widgets;serialport;printsupport</QtModules>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<QtInstall>msvc2019</QtInstall>
|
||||
<QtModules>core;network;gui;multimedia;widgets;serialport;printsupport</QtModules>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="QtSettings">
|
||||
<QtInstall>msvc2019_64_v62</QtInstall>
|
||||
<QtModules>core;network;gui;multimedia;widgets;serialport;printsupport</QtModules>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Condition="Exists('$(QtMsBuild)\qt.props')">
|
||||
<Import Project="$(QtMsBuild)\qt.props" />
|
||||
</ImportGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\opus\include;..\eigen;..\r8brain-free-src;resampler;release;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
|
@ -57,14 +137,16 @@
|
|||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<ObjectFileName>release\</ObjectFileName>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.2e";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="44f6ec2";HOST="wfview.org";UNAME="build";NDEBUG;QT_NO_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.55";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="44f6ec2";HOST="wfview.org";UNAME="build";NDEBUG;QT_NO_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<ProgramDataBaseFileName></ProgramDataBaseFileName>
|
||||
<ProgramDataBaseFileName>
|
||||
</ProgramDataBaseFileName>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation></ClCompile>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\Win32\Release\portaudio_x86.lib;..\opus\win32\VS2015\Win32\Release\opus.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\portaudio\msvc\Win32\Release;..\opus\win32\VS2015\Win32\Release;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
|
@ -85,9 +167,81 @@
|
|||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.2e\";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"44f6ec2\";HOST=\"wfview.org\";UNAME=\"build\";NDEBUG;QT_NO_DEBUG;QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.55\";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"44f6ec2\";HOST=\"wfview.org\";UNAME=\"build\";NDEBUG;QT_NO_DEBUG;QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<QtMoc><CompilerFlavor>msvc</CompilerFlavor><Include>./$(Configuration)/moc_predefs.h</Include><ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription><DynamicSource>output</DynamicSource><QtMocDir>$(Configuration)</QtMocDir><QtMocFileName>moc_%(Filename).cpp</QtMocFileName></QtMoc><QtRcc><Compression>default</Compression><ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription><QtRccDir>$(Configuration)</QtRccDir><QtRccFileName>qrc_%(Filename).cpp</QtRccFileName></QtRcc></ItemDefinitionGroup>
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\opus\include;..\eigen;..\r8brain-free-src;resampler;release;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AssemblerListingLocation>release\</AssemblerListingLocation>
|
||||
<BrowseInformation>false</BrowseInformation>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
<DisableSpecificWarnings>4577;4467;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<ObjectFileName>release\</ObjectFileName>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.55";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="44f6ec2";HOST="wfview.org";UNAME="build";NDEBUG;QT_NO_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<ProgramDataBaseFileName>
|
||||
</ProgramDataBaseFileName>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\x64\Release\portaudio_x64.lib;..\opus\win32\VS2015\x64\Release\opus.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\portaudio\msvc\x64\Release;..\opus\win32\VS2015\x64\Release;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalOptions>"/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" %(AdditionalOptions)</AdditionalOptions>
|
||||
<DataExecutionPrevention>true</DataExecutionPrevention>
|
||||
<GenerateDebugInformation>false</GenerateDebugInformation>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<OutputFile>$(OutDir)\wfserver.exe</OutputFile>
|
||||
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Link>
|
||||
<Midl>
|
||||
<DefaultCharType>Unsigned</DefaultCharType>
|
||||
<EnableErrorChecks>None</EnableErrorChecks>
|
||||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.55\";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"44f6ec2\";HOST=\"wfview.org\";UNAME=\"build\";NDEBUG;QT_NO_DEBUG;QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\opus\include;..\eigen;..\r8brain-free-src;resampler;debug;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
|
@ -99,13 +253,14 @@
|
|||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<ObjectFileName>debug\</ObjectFileName>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.2e";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="44f6ec2";HOST="wfview.org";UNAME="build";%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.55";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="44f6ec2";HOST="wfview.org";UNAME="build";%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation></ClCompile>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\Win32\Debug\portaudio_x86.lib;..\opus\win32\VS2015\Win32\Debug\opus.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\portaudio\msvc\Win32\Debug;..\opus\win32\VS2015\Win32\Debug;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
|
@ -124,12 +279,81 @@
|
|||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.2e\";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"44f6ec2\";HOST=\"wfview.org\";UNAME=\"build\";QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.55\";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"44f6ec2\";HOST=\"wfview.org\";UNAME=\"build\";QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<QtMoc><CompilerFlavor>msvc</CompilerFlavor><Include>./$(Configuration)/moc_predefs.h</Include><ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription><DynamicSource>output</DynamicSource><QtMocDir>$(Configuration)</QtMocDir><QtMocFileName>moc_%(Filename).cpp</QtMocFileName></QtMoc><QtRcc><Compression>default</Compression><ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription><QtRccDir>$(Configuration)</QtRccDir><QtRccFileName>qrc_%(Filename).cpp</QtRccFileName></QtRcc></ItemDefinitionGroup>
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\opus\include;..\eigen;..\r8brain-free-src;resampler;debug;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AssemblerListingLocation>debug\</AssemblerListingLocation>
|
||||
<BrowseInformation>false</BrowseInformation>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<DisableSpecificWarnings>4577;4467;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<ObjectFileName>debug\</ObjectFileName>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.55";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="44f6ec2";HOST="wfview.org";UNAME="build";%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\Win32\Debug\portaudio_x86.lib;..\opus\win32\VS2015\Win32\Debug\opus.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\portaudio\msvc\Win32\Debug;..\opus\win32\VS2015\Win32\Debug;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalOptions>"/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" %(AdditionalOptions)</AdditionalOptions>
|
||||
<DataExecutionPrevention>true</DataExecutionPrevention>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<OutputFile>$(OutDir)\wfserver.exe</OutputFile>
|
||||
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Link>
|
||||
<Midl>
|
||||
<DefaultCharType>Unsigned</DefaultCharType>
|
||||
<EnableErrorChecks>None</EnableErrorChecks>
|
||||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CONSOLE;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.55\";BUILD_WFSERVER;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"44f6ec2\";HOST=\"wfview.org\";UNAME=\"build\";QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\rtaudio\RTAudio.cpp" />
|
||||
<ClCompile Include="audioconverter.cpp" />
|
||||
<ClCompile Include="audiodevices.cpp" />
|
||||
<ClCompile Include="audiohandler.cpp" />
|
||||
<ClCompile Include="commhandler.cpp" />
|
||||
<ClCompile Include="freqmemory.cpp" />
|
||||
|
@ -153,219 +377,76 @@
|
|||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\rtaudio\RTAUdio.h" />
|
||||
<QtMoc Include="audiodevices.h" />
|
||||
<ClInclude Include="resampler\arch.h" />
|
||||
<QtMoc Include="audioconverter.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="audiohandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="audiotaper.h" />
|
||||
<QtMoc Include="commhandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="freqmemory.h" />
|
||||
<QtMoc Include="keyboard.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="logcategories.h" />
|
||||
<ClInclude Include="packettypes.h" />
|
||||
<QtMoc Include="pahandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="pttyhandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="repeaterattributes.h" />
|
||||
<ClInclude Include="resampler\resample_sse.h" />
|
||||
<QtMoc Include="rigcommander.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="rigctld.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="rigidentities.h" />
|
||||
<QtMoc Include="rthandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="servermain.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="resampler\speex_resampler.h" />
|
||||
<QtMoc Include="tcpserver.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="udpaudio.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="udpbase.h" />
|
||||
<QtMoc Include="udpcivdata.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="udphandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="udpserver.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="ulaw.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<CustomBuild Include="debug\moc_predefs.h.cbt">
|
||||
<FileType>Document</FileType>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -faligned-new -Zi -MDd -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >debug\moc_predefs.h</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -faligned-new -Zi -MDd -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >debug\moc_predefs.h</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Generate moc_predefs.h</Message>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Generate moc_predefs.h</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">debug\moc_predefs.h;%(Outputs)</Outputs>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">debug\moc_predefs.h;%(Outputs)</Outputs>
|
||||
</CustomBuild>
|
||||
<CustomBuild Include="release\moc_predefs.h.cbt">
|
||||
<FileType>Document</FileType>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -fvisibility=hidden -fvisibility-inlines-hidden -faligned-new -O2 -MD -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >release\moc_predefs.h</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -fvisibility=hidden -fvisibility-inlines-hidden -faligned-new -O2 -MD -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >release\moc_predefs.h</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Generate moc_predefs.h</Message>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Generate moc_predefs.h</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">release\moc_predefs.h;%(Outputs)</Outputs>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">release\moc_predefs.h;%(Outputs)</Outputs>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
</CustomBuild>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="qdarkstyle\rc\Hmovetoolbar.png" />
|
||||
|
@ -398,30 +479,20 @@
|
|||
<None Include="qdarkstyle\rc\radio_unchecked_disabled.png" />
|
||||
<None Include="qdarkstyle\rc\radio_unchecked_focus.png" />
|
||||
<QtRcc Include="resources\resources.qrc">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">resources</InitFuncName><InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">resources</InitFuncName></QtRcc>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">resources</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|x64'">resources</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">resources</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">resources</InitFuncName>
|
||||
</QtRcc>
|
||||
<None Include="qdarkstyle\rc\right_arrow.png" />
|
||||
<None Include="qdarkstyle\rc\right_arrow_disabled.png" />
|
||||
<None Include="qdarkstyle\rc\sizegrip.png" />
|
||||
<QtRcc Include="qdarkstyle\style.qrc">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">style</InitFuncName><InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">style</InitFuncName></QtRcc>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">style</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|x64'">style</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">style</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">style</InitFuncName>
|
||||
</QtRcc>
|
||||
<None Include="qdarkstyle\style.qss" />
|
||||
<None Include="qdarkstyle\rc\stylesheet-branch-end.png" />
|
||||
<None Include="qdarkstyle\rc\stylesheet-branch-more.png" />
|
||||
|
@ -435,6 +506,9 @@
|
|||
<ItemGroup>
|
||||
<ResourceCompile Include=".\wfserver_resource.rc" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /><ImportGroup Condition="Exists('$(QtMsBuild)\qt.targets')"><Import Project="$(QtMsBuild)\qt.targets" /></ImportGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Condition="Exists('$(QtMsBuild)\qt.targets')">
|
||||
<Import Project="$(QtMsBuild)\qt.targets" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="ExtensionTargets" />
|
||||
</Project>
|
|
@ -103,6 +103,9 @@
|
|||
<ClCompile Include="udpserver.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="audiodevices.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\rtaudio\RTAUdio.h">
|
||||
|
@ -188,46 +191,12 @@
|
|||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<CustomBuild Include="debug\moc_predefs.h.cbt">
|
||||
<Filter>Generated Files</Filter>
|
||||
</CustomBuild>
|
||||
<CustomBuild Include="release\moc_predefs.h.cbt">
|
||||
<Filter>Generated Files</Filter>
|
||||
</CustomBuild>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="qdarkstyle\rc\Hmovetoolbar.png">
|
||||
|
@ -361,6 +330,11 @@
|
|||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="C:\Users\Phil\source\repos\wfview\wfserver_resource.rc" />
|
||||
<ResourceCompile Include=".\wfserver_resource.rc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<QtMoc Include="audiodevices.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
</ItemGroup>
|
||||
</Project>
|
|
@ -1,10 +1,16 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup />
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<QtLastBackgroundBuild>2022-04-13T11:33:50.3607712Z</QtLastBackgroundBuild>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2022-08-21T18:45:22.2052009Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2022-08-21T18:45:22.2052009Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2023-01-02T19:56:38.8798452Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2022-04-13T11:33:53.0745117Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
</Project>
|
|
@ -0,0 +1,29 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<<<<<<< HEAD
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
=======
|
||||
>>>>>>> settings
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<<<<<<< HEAD
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<QtLastBackgroundBuild>2021-11-18T12:40:24.8966742Z</QtLastBackgroundBuild>
|
||||
=======
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<QtLastBackgroundBuild>2021-11-22T18:24:33.3752914Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<QtLastBackgroundBuild>2021-11-22T18:24:41.6960953Z</QtLastBackgroundBuild>
|
||||
>>>>>>> settings
|
||||
</PropertyGroup>
|
||||
</Project>
|
69
wfview.pro
69
wfview.pro
|
@ -14,15 +14,22 @@ greaterThan(QT_MAJOR_VERSION, 4): QT += widgets printsupport
|
|||
TARGET = wfview
|
||||
TEMPLATE = app
|
||||
|
||||
DEFINES += WFVIEW_VERSION=\\\"1.54\\\"
|
||||
DEFINES += WFVIEW_VERSION=\\\"1.56\\\"
|
||||
|
||||
DEFINES += BUILD_WFVIEW
|
||||
|
||||
#Uncomment The following 5 lines enable USB controllers (Shuttle/RC-28 etc.)
|
||||
#DEFINES += USB_CONTROLLERS
|
||||
#linux:LIBS += -L./ -l$$QCPLIB -lhidapi-libusb
|
||||
#macx:LIBS += -framework CoreAudio -framework CoreFoundation -lhidapi
|
||||
#win32:INCLUDEPATH += ../hidapi/hidapi
|
||||
#win32:SOURCES += ../hidapi/windows/hid.c
|
||||
|
||||
|
||||
CONFIG(debug, release|debug) {
|
||||
# For Debug builds only:
|
||||
QMAKE_CXXFLAGS += -faligned-new
|
||||
win32:DESTDIR = wfview-release
|
||||
win32:LIBS += -L../portaudio/msvc/Win32/Debug/ -lportaudio_x86 -lole32
|
||||
} else {
|
||||
# For Release builds only:
|
||||
linux:QMAKE_CXXFLAGS += -s
|
||||
|
@ -31,9 +38,9 @@ CONFIG(debug, release|debug) {
|
|||
QMAKE_CXXFLAGS += -faligned-new
|
||||
linux:QMAKE_LFLAGS += -O2 -s
|
||||
win32:DESTDIR = wfview-debug
|
||||
win32:LIBS += -L../portaudio/msvc/Win32/Release/ -lportaudio_x86 -lole32
|
||||
}
|
||||
|
||||
|
||||
# RTAudio defines
|
||||
win32:DEFINES += __WINDOWS_WASAPI__
|
||||
#win32:DEFINES += __WINDOWS_DS__ # Requires DirectSound libraries
|
||||
|
@ -55,7 +62,7 @@ win32:INCLUDEPATH += ../portaudio/include
|
|||
# depend on your compiler). Please consult the documentation of the
|
||||
# deprecated API in order to know how to port your code away from it.
|
||||
DEFINES += QT_DEPRECATED_WARNINGS
|
||||
DEFINES += QCUSTOMPLOT_COMPILE_LIBRARY
|
||||
DEFINES += QCUSTOMPLOT_USE_LIBRARY
|
||||
|
||||
|
||||
# These defines are used for the resampler
|
||||
|
@ -129,25 +136,47 @@ INSTALLS += stylesheets
|
|||
|
||||
CONFIG(debug, release|debug) {
|
||||
linux: QCPLIB = qcustomplotd
|
||||
win32:LIBS += -L../opus/win32/VS2015/Win32/Debug/ -lopus
|
||||
!linux: QCPLIB = qcustomplotd2
|
||||
win32 {
|
||||
contains(QMAKE_TARGET.arch, x86_64) {
|
||||
LIBS += -L../opus/win32/VS2015/x64/Debug/
|
||||
LIBS += -L../qcustomplot/x64
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y ..\qcustomplot\x64\qcustomplotd2.dll debug\$$escape_expand(\n\t))
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y ..\portaudio\msvc\x64\Debug\portaudio_x64.dll debug\$$escape_expand(\n\t))
|
||||
win32:LIBS += -L../portaudio/msvc/X64/Debug/ -lportaudio_x64
|
||||
} else {
|
||||
LIBS += -L../opus/win32/VS2015/win32/Debug/
|
||||
LIBS += -L../qcustomplot/win32
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y .\qcustomplot\win32\qcustomplotd2.dll debug\$$escape_expand(\n\t))
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y ..\portaudio\msvc\win32\Debug\portaudio_x86.dll debug\$$escape_expand(\n\t))
|
||||
win32:LIBS += -L../portaudio/msvc/Win32/Debug/ -lportaudio_x86 -lole32
|
||||
}
|
||||
}
|
||||
} else {
|
||||
linux: QCPLIB = qcustomplot
|
||||
win32:LIBS += -L../opus/win32/VS2015/Win32/Release/ -lopus
|
||||
!linux: QCPLIB = qcustomplot2
|
||||
win32 {
|
||||
contains(QMAKE_TARGET.arch, x86_64) {
|
||||
LIBS += -L../opus/win32/VS2015/x64/Release/
|
||||
LIBS += -L../qcustomplot/x64
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y ..\qcustomplot\x64\qcustomplot2.dll release\$$escape_expand(\n\t))
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y ..\portaudio\msvc\x64\Release\portaudio_x64.dll release\$$escape_expand(\n\t))
|
||||
win32:LIBS += -L../portaudio/msvc/X64/Release/ -lportaudio_x64
|
||||
} else {
|
||||
LIBS += -L../opus/win32/VS2015/win32/Release/
|
||||
LIBS += -L../qcustomplot/win32
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y ..\qcustomplot\win32\qcustomplot2.dll release\$$escape_expand(\n\t))
|
||||
QMAKE_POST_LINK +=$$quote(cmd /c copy /y ..\portaudio\msvc\win32\Release\portaudio_x86.dll release\$$escape_expand(\n\t))
|
||||
win32:LIBS += -L../portaudio/msvc/Win32/Release/ -lportaudio_x86 -lole32
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
linux:LIBS += -L./ -l$$QCPLIB -lhidapi-libusb -lopus
|
||||
macx:LIBS += -framework CoreAudio -framework CoreFoundation -lhidapi -lpthread -lopus
|
||||
linux:LIBS += -L./ -l$$QCPLIB -lopus
|
||||
!linux:LIBS += -l$$QCPLIB -lopus
|
||||
macx:LIBS += -framework CoreAudio -framework CoreFoundation -lpthread -lopus
|
||||
|
||||
win32:INCLUDEPATH += ../hidapi/hidapi
|
||||
win32:SOURCES += ../hidapi/windows/hid.c
|
||||
|
||||
#win32:SOURCES += rtaudio/RTAudio.cpp
|
||||
#win32:HEADERS += rtaudio/RTAUdio.h
|
||||
|
||||
!linux:SOURCES += ../qcustomplot/qcustomplot.cpp
|
||||
!linux:HEADERS += ../qcustomplot/qcustomplot.h
|
||||
!linux:INCLUDEPATH += ../qcustomplot
|
||||
|
||||
!linux:INCLUDEPATH += ../opus/include
|
||||
|
||||
win32:INCLUDEPATH += ../eigen
|
||||
|
@ -187,7 +216,8 @@ SOURCES += main.cpp\
|
|||
tcpserver.cpp \
|
||||
cluster.cpp \
|
||||
database.cpp \
|
||||
aboutbox.cpp
|
||||
aboutbox.cpp \
|
||||
audiodevices.cpp
|
||||
|
||||
HEADERS += wfmain.h \
|
||||
colorprefs.h \
|
||||
|
@ -230,7 +260,8 @@ HEADERS += wfmain.h \
|
|||
cluster.h \
|
||||
database.h \
|
||||
aboutbox.h \
|
||||
wfviewtypes.h
|
||||
wfviewtypes.h \
|
||||
audiodevices.h
|
||||
|
||||
FORMS += wfmain.ui \
|
||||
calibrationwindow.ui \
|
||||
|
|
26
wfview.sln
26
wfview.sln
|
@ -9,18 +9,24 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wfserver", "wfserver.vcxpro
|
|||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|x86 = Debug|x86
|
||||
Release|x86 = Release|x86
|
||||
Debug|Win32 = Debug|Win32
|
||||
Debug|x64 = Debug|x64
|
||||
Release|Win32 = Release|Win32
|
||||
Release|x64 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Debug|x86.Build.0 = Debug|Win32
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Release|x86.ActiveCfg = Release|Win32
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Release|x86.Build.0 = Release|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Debug|x86.Build.0 = Debug|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Release|x86.ActiveCfg = Release|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Release|x86.Build.0 = Release|Win32
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Debug|x64.Build.0 = Debug|x64
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Release|x64.ActiveCfg = Release|x64
|
||||
{326108AD-FA9D-3AAF-8D3E-062C4DDC34E2}.Release|x64.Build.0 = Release|x64
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Release|Win32.Build.0 = Release|Win32
|
||||
{00E054F8-A1D4-3ECA-A8D6-DFC8A68AFD56}.Release|x64.ActiveCfg = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
|
774
wfview.vcxproj
774
wfview.vcxproj
|
@ -1,13 +1,21 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
|
@ -16,8 +24,18 @@
|
|||
<Keyword>QtVS_v304</Keyword>
|
||||
<WindowsTargetPlatformVersion>10.0.19041.0</WindowsTargetPlatformVersion>
|
||||
<WindowsTargetPlatformMinVersion>10.0.19041.0</WindowsTargetPlatformMinVersion>
|
||||
<QtMsBuild Condition="'$(QtMsBuild)'=='' or !Exists('$(QtMsBuild)\qt.targets')">$(MSBuildProjectDirectory)\QtMsBuild</QtMsBuild></PropertyGroup>
|
||||
<QtMsBuild Condition="'$(QtMsBuild)'=='' or !Exists('$(QtMsBuild)\qt.targets')">$(MSBuildProjectDirectory)\QtMsBuild</QtMsBuild>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<OutputDirectory>wfview-release\</OutputDirectory>
|
||||
<ATLMinimizesCRunTimeLibraryUsage>false</ATLMinimizesCRunTimeLibraryUsage>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<IntermediateDirectory>release\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfview</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<OutputDirectory>wfview-release\</OutputDirectory>
|
||||
|
@ -27,6 +45,15 @@
|
|||
<IntermediateDirectory>release\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfview</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<OutputDirectory>wfview-debug\</OutputDirectory>
|
||||
<ATLMinimizesCRunTimeLibraryUsage>false</ATLMinimizesCRunTimeLibraryUsage>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<IntermediateDirectory>debug\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfview</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<OutputDirectory>wfview-debug\</OutputDirectory>
|
||||
|
@ -36,40 +63,100 @@
|
|||
<IntermediateDirectory>debug\</IntermediateDirectory>
|
||||
<PrimaryOutput>wfview</PrimaryOutput>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /><Target Name="QtMsBuildNotFound" BeforeTargets="CustomBuild;ClCompile" Condition="!Exists('$(QtMsBuild)\qt.targets') or !Exists('$(QtMsBuild)\qt.props')"><Message Importance="High" Text="QtMsBuild: could not locate qt.targets, qt.props; project may not build correctly." /></Target>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<Target Name="QtMsBuildNotFound" BeforeTargets="CustomBuild;ClCompile" Condition="!Exists('$(QtMsBuild)\qt.targets') or !Exists('$(QtMsBuild)\qt.props')">
|
||||
<Message Importance="High" Text="QtMsBuild: could not locate qt.targets, qt.props; project may not build correctly." />
|
||||
</Target>
|
||||
<ImportGroup Label="ExtensionSettings" />
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" /><ImportGroup Condition="Exists('$(QtMsBuild)\qt_defaults.props')"><Import Project="$(QtMsBuild)\qt_defaults.props" /></ImportGroup><PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"><OutDir>wfview-debug\</OutDir><IntDir>debug\</IntDir><TargetName>wfview</TargetName><IgnoreImportLibrary>true</IgnoreImportLibrary></PropertyGroup><PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"><OutDir>wfview-release\</OutDir><IntDir>release\</IntDir><TargetName>wfview</TargetName><IgnoreImportLibrary>true</IgnoreImportLibrary><LinkIncremental>false</LinkIncremental></PropertyGroup><PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"><QtInstall>msvc2019</QtInstall><QtModules>core;xml;network;gui;multimedia;widgets;serialport;printsupport;gamepad</QtModules></PropertyGroup><PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"><QtInstall>msvc2019</QtInstall><QtModules>core;xml;network;gui;multimedia;widgets;serialport;printsupport;gamepad</QtModules></PropertyGroup><ImportGroup Condition="Exists('$(QtMsBuild)\qt.props')"><Import Project="$(QtMsBuild)\qt.props" /></ImportGroup>
|
||||
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<ImportGroup Condition="Exists('$(QtMsBuild)\qt_defaults.props')">
|
||||
<Import Project="$(QtMsBuild)\qt_defaults.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>wfview-debug\</OutDir>
|
||||
<IntDir>debug\</IntDir>
|
||||
<TargetName>wfview</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<PostBuildEventUseInBuild>true</PostBuildEventUseInBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<TargetName>wfview</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<PostBuildEventUseInBuild>true</PostBuildEventUseInBuild>
|
||||
<OutDir>$(SolutionDir)wfview-debug\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>wfview-release\</OutDir>
|
||||
<IntDir>release\</IntDir>
|
||||
<TargetName>wfview</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<TargetName>wfview</TargetName>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)wfview-release\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<QtInstall>msvc2019</QtInstall>
|
||||
<QtModules>core;gui;network;widgets;multimedia;printsupport;serialport;xml</QtModules>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="QtSettings">
|
||||
<QtInstall>msvc2019</QtInstall>
|
||||
<QtModules>core;gui;network;widgets;multimedia;printsupport;serialport;xml</QtModules>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<QtInstall>msvc2019_64_v62</QtInstall>
|
||||
<QtModules>core;gui;network;widgets;multimedia;printsupport;serialport;xml</QtModules>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="QtSettings">
|
||||
<QtInstall>msvc2019</QtInstall>
|
||||
<QtModules>core;gui;network;widgets;multimedia;printsupport;serialport;xml</QtModules>
|
||||
</PropertyGroup>
|
||||
<ImportGroup Condition="Exists('$(QtMsBuild)\qt.props')">
|
||||
<Import Project="$(QtMsBuild)\qt.props" />
|
||||
</ImportGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\hidapi\hidapi;..\qcustomplot;..\opus\include;..\eigen;..\r8brain-free-src;resampler;release;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\qcustomplot;..\opus\include;..\eigen;..\r8brain-free-src;resampler;release;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -utf-8 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AssemblerListingLocation>release\</AssemblerListingLocation>
|
||||
<BrowseInformation>false</BrowseInformation>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
<DisableSpecificWarnings>4577;4467;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<ObjectFileName>release\</ObjectFileName>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.54";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="978a444";HOST="wfview.org";UNAME="build";NDEBUG;QT_NO_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;WFVIEW_VERSION="1.55";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="4574e2b";HOST="wfview.org";UNAME="build";NDEBUG;QT_NO_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<ProgramDataBaseFileName></ProgramDataBaseFileName>
|
||||
<ProgramDataBaseFileName>
|
||||
</ProgramDataBaseFileName>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation></ClCompile>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\Win32\Release\portaudio_x86.lib;ole32.lib;..\opus\win32\VS2015\Win32\Release\opus.lib;shell32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\portaudio\msvc\Win32\Release;..\opus\win32\VS2015\Win32\Release;C:\opensslx86\lib;C:\Utils\my_sql\mysql-5.7.25-win32\lib;C:\Utils\postgresqlx86\pgsql\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>..\portaudio\msvc\X64\Release\portaudio_x64.lib;..\qcustomplot\x64\qcustomplot2.lib;..\opus\win32\VS2015\x64\Release\opus.lib;$(QTDIR)\lib\Qt6Multimedia.lib;$(QTDIR)\lib\Qt6PrintSupport.lib;$(QTDIR)\lib\Qt6Widgets.lib;$(QTDIR)\lib\Qt6Gui.lib;$(QTDIR)\lib\Qt6SerialPort.lib;$(QTDIR)\lib\Qt6Network.lib;$(QTDIR)\lib\Qt6Core.lib;$(QTDIR)\lib\Qt6EntryPoint.lib;shell32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\opus\win32\VS2015\x64\Release;..\qcustomplot\x64;..\portaudio\msvc\X64\Release;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalOptions>"/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" %(AdditionalOptions)</AdditionalOptions>
|
||||
<DataExecutionPrevention>true</DataExecutionPrevention>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<GenerateDebugInformation>false</GenerateDebugInformation>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
|
@ -85,30 +172,131 @@
|
|||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.54\";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"978a444\";HOST=\"wfview.org\";UNAME=\"build\";NDEBUG;QT_NO_DEBUG;QT_MULTIMEDIA_LIB;QT_GAMEPAD_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_XML_LIB;QT_CORE_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;WFVIEW_VERSION=\"1.55\";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"4574e2b\";HOST=\"wfview.org\";UNAME=\"build\";NDEBUG;QT_NO_DEBUG;QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<QtMoc><CompilerFlavor>msvc</CompilerFlavor><Include>./$(Configuration)/moc_predefs.h</Include><ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription><DynamicSource>output</DynamicSource><QtMocDir>$(Configuration)</QtMocDir><QtMocFileName>moc_%(Filename).cpp</QtMocFileName></QtMoc><QtRcc><Compression>default</Compression><ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription><QtRccDir>$(Configuration)</QtRccDir><QtRccFileName>qrc_%(Filename).cpp</QtRccFileName></QtRcc><QtUic><ExecutionDescription>Uic'ing %(Identity)...</ExecutionDescription><QtUicDir>$(ProjectDir)</QtUicDir><QtUicFileName>ui_%(Filename).h</QtUicFileName></QtUic></ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
<QtUic>
|
||||
<ExecutionDescription>Uic'ing %(Identity)...</ExecutionDescription>
|
||||
<QtUicDir>$(ProjectDir)</QtUicDir>
|
||||
<QtUicFileName>ui_%(Filename).h</QtUicFileName>
|
||||
</QtUic>
|
||||
<PostBuildEvent>
|
||||
<Command>cmd /c copy /y ..\qcustomplot\x64\qcustomplot2.dll wfview-release\
|
||||
cmd /c copy /y ..\portaudio\msvc\x64\Release\portaudio_x64.dll wfview-release\</Command>
|
||||
</PostBuildEvent>
|
||||
<PostBuildEvent>
|
||||
<Message>Copy DLL Files</Message>
|
||||
</PostBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\hidapi\hidapi;..\qcustomplot;..\opus\include;..\eigen;..\r8brain-free-src;resampler;debug;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\qcustomplot;..\opus\include;..\eigen;..\r8brain-free-src;resampler;release;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -utf-8 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AssemblerListingLocation>release\</AssemblerListingLocation>
|
||||
<BrowseInformation>false</BrowseInformation>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
<DisableSpecificWarnings>4577;4467;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<ObjectFileName>release\</ObjectFileName>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.55";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="4574e2b";HOST="wfview.org";UNAME="build";NDEBUG;QT_NO_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<ProgramDataBaseFileName>
|
||||
</ProgramDataBaseFileName>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\Win32\Release\portaudio_x86.lib;..\qcustomplot\Win32\qcustomplot2.lib;..\opus\win32\VS2015\Win32\Release\opus.lib;shell32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\opus\win32\VS2015\Win32\Release;..\qcustomplot\Win32;..\portaudio\msvc\Win32\Release;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalOptions>"/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" %(AdditionalOptions)</AdditionalOptions>
|
||||
<DataExecutionPrevention>true</DataExecutionPrevention>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<GenerateDebugInformation>false</GenerateDebugInformation>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<OutputFile>$(OutDir)\wfview.exe</OutputFile>
|
||||
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Link>
|
||||
<Midl>
|
||||
<DefaultCharType>Unsigned</DefaultCharType>
|
||||
<EnableErrorChecks>None</EnableErrorChecks>
|
||||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;WFVIEW_VERSION=\"1.55\";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"4574e2b\";HOST=\"wfview.org\";UNAME=\"build\";NDEBUG;QT_NO_DEBUG;QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
<QtUic>
|
||||
<ExecutionDescription>Uic'ing %(Identity)...</ExecutionDescription>
|
||||
<QtUicDir>$(ProjectDir)</QtUicDir>
|
||||
<QtUicFileName>ui_%(Filename).h</QtUicFileName>
|
||||
</QtUic>
|
||||
<PostBuildEvent>
|
||||
<Command>cmd /c copy /y ..\qcustomplot\Win32\qcustomplot2.dll wfview-release\
|
||||
cmd /c copy /y ..\portaudio\msvc\Win32\Release\portaudio_x86.dll wfview-release\</Command>
|
||||
</PostBuildEvent>
|
||||
<PostBuildEvent>
|
||||
<Message>Copy DLL Files</Message>
|
||||
</PostBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\qcustomplot;..\opus\include;..\eigen;..\r8brain-free-src;resampler;debug;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -utf-8 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AssemblerListingLocation>debug\</AssemblerListingLocation>
|
||||
<BrowseInformation>false</BrowseInformation>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<DisableSpecificWarnings>4577;4467;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<ObjectFileName>debug\</ObjectFileName>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION="1.54";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="978a444";HOST="wfview.org";UNAME="build";%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;WFVIEW_VERSION="1.55";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="4574e2b";HOST="wfview.org";UNAME="build";%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation></ClCompile>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
<LanguageStandard_C>stdc17</LanguageStandard_C>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\Win32\Debug\portaudio_x86.lib;ole32.lib;..\opus\win32\VS2015\Win32\Debug\opus.lib;shell32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\portaudio\msvc\Win32\Debug;..\opus\win32\VS2015\Win32\Debug;C:\opensslx86\lib;C:\Utils\my_sql\mysql-5.7.25-win32\lib;C:\Utils\postgresqlx86\pgsql\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>..\portaudio\msvc\X64\Debug\portaudio_x64.lib;..\qcustomplot\x64\qcustomplotd2.lib;..\opus\win32\VS2015\x64\Debug\opus.lib;$(QTDIR)\lib\Qt6Multimediad.lib;$(QTDIR)\lib\Qt6PrintSupportd.lib;$(QTDIR)\lib\Qt6Widgetsd.lib;$(QTDIR)\lib\Qt6Guid.lib;$(QTDIR)\lib\Qt6SerialPortd.lib;$(QTDIR)\lib\Qt6Networkd.lib;$(QTDIR)\lib\Qt6Cored.lib;$(QTDIR)\lib\Qt6EntryPointd.lib;shell32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\opus\win32\VS2015\x64\Debug;..\qcustomplot\x64;..\portaudio\msvc\X64\Debug;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalOptions>"/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" %(AdditionalOptions)</AdditionalOptions>
|
||||
<DataExecutionPrevention>true</DataExecutionPrevention>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
|
@ -124,28 +312,115 @@
|
|||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WFVIEW_VERSION=\"1.54\";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_COMPILE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"978a444\";HOST=\"wfview.org\";UNAME=\"build\";QT_MULTIMEDIA_LIB;QT_GAMEPAD_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_XML_LIB;QT_CORE_LIB;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;WFVIEW_VERSION=\"1.55\";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"4574e2b\";HOST=\"wfview.org\";UNAME=\"build\";QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<QtMoc><CompilerFlavor>msvc</CompilerFlavor><Include>./$(Configuration)/moc_predefs.h</Include><ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription><DynamicSource>output</DynamicSource><QtMocDir>$(Configuration)</QtMocDir><QtMocFileName>moc_%(Filename).cpp</QtMocFileName></QtMoc><QtRcc><Compression>default</Compression><ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription><QtRccDir>$(Configuration)</QtRccDir><QtRccFileName>qrc_%(Filename).cpp</QtRccFileName></QtRcc><QtUic><ExecutionDescription>Uic'ing %(Identity)...</ExecutionDescription><QtUicDir>$(ProjectDir)</QtUicDir><QtUicFileName>ui_%(Filename).h</QtUicFileName></QtUic></ItemDefinitionGroup>
|
||||
<PostBuildEvent>
|
||||
<Command>cmd /c copy /y ..\qcustomplot\x64\qcustomplotd2.dll wfview-debug
|
||||
cmd /c copy /y ..\portaudio\msvc\x64\Debug\portaudio_x64.dll wfview-debug</Command>
|
||||
<Message>Copy DLL files</Message>
|
||||
</PostBuildEvent>
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
<QtUic>
|
||||
<ExecutionDescription>Uic'ing %(Identity)...</ExecutionDescription>
|
||||
<QtUicDir>$(ProjectDir)</QtUicDir>
|
||||
<QtUicFileName>ui_%(Filename).h</QtUicFileName>
|
||||
</QtUic>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>.;..\rtaudio;..\portaudio\include;..\qcustomplot;..\opus\include;..\eigen;..\r8brain-free-src;resampler;debug;/include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalOptions>-Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -utf-8 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 %(AdditionalOptions)</AdditionalOptions>
|
||||
<AssemblerListingLocation>debug\</AssemblerListingLocation>
|
||||
<BrowseInformation>false</BrowseInformation>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<DisableSpecificWarnings>4577;4467;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
<ObjectFileName>debug\</ObjectFileName>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;WFVIEW_VERSION="1.55";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX="/usr/local";GITSHORT="4574e2b";HOST="wfview.org";UNAME="build";%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessToFile>false</PreprocessToFile>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
<LanguageStandard_C>stdc17</LanguageStandard_C>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>..\portaudio\msvc\Win32\Debug\portaudio_x86.lib;..\qcustomplot\Win32\qcustomplotd2.lib;..\opus\win32\VS2015\Win32\Debug\opus.lib;shell32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\opus\win32\VS2015\Win32\Debug;..\qcustomplot\Win32;..\portaudio\msvc\Win32\Debug;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalOptions>"/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" %(AdditionalOptions)</AdditionalOptions>
|
||||
<DataExecutionPrevention>true</DataExecutionPrevention>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||
<OutputFile>$(OutDir)\wfview.exe</OutputFile>
|
||||
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Link>
|
||||
<Midl>
|
||||
<DefaultCharType>Unsigned</DefaultCharType>
|
||||
<EnableErrorChecks>None</EnableErrorChecks>
|
||||
<WarningLevel>0</WarningLevel>
|
||||
</Midl>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;WFVIEW_VERSION=\"1.55\";BUILD_WFVIEW;__WINDOWS_WASAPI__;QT_DEPRECATED_WARNINGS;QCUSTOMPLOT_USE_LIBRARY;USE_SSE;USE_SSE2;OUTSIDE_SPEEX;RANDOM_PREFIX=wf;EIGEN_MPL2_ONLY;EIGEN_DONT_VECTORIZE;EIGEN_VECTORIZE_SSE3;PREFIX=\"/usr/local\";GITSHORT=\"4574e2b\";HOST=\"wfview.org\";UNAME=\"build\";QT_MULTIMEDIA_LIB;QT_PRINTSUPPORT_LIB;QT_WIDGETS_LIB;QT_GUI_LIB;QT_SERIALPORT_LIB;QT_NETWORK_LIB;QT_CORE_LIB;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ResourceCompile>
|
||||
<PostBuildEvent>
|
||||
<Command>cmd /c copy /y ..\qcustomplot\Win32\qcustomplotd2.dll wfview-debug
|
||||
cmd /c copy /y ..\portaudio\msvc\Win32\Debug\portaudio_x86.dll wfview-debug</Command>
|
||||
<Message>Copy DLL files</Message>
|
||||
</PostBuildEvent>
|
||||
<QtMoc>
|
||||
<CompilerFlavor>msvc</CompilerFlavor>
|
||||
<Include>./$(Configuration)/moc_predefs.h</Include>
|
||||
<ExecutionDescription>Moc'ing %(Identity)...</ExecutionDescription>
|
||||
<DynamicSource>output</DynamicSource>
|
||||
<QtMocDir>$(Configuration)</QtMocDir>
|
||||
<QtMocFileName>moc_%(Filename).cpp</QtMocFileName>
|
||||
</QtMoc>
|
||||
<QtRcc>
|
||||
<Compression>default</Compression>
|
||||
<ExecutionDescription>Rcc'ing %(Identity)...</ExecutionDescription>
|
||||
<QtRccDir>$(Configuration)</QtRccDir>
|
||||
<QtRccFileName>qrc_%(Filename).cpp</QtRccFileName>
|
||||
</QtRcc>
|
||||
<QtUic>
|
||||
<ExecutionDescription>Uic'ing %(Identity)...</ExecutionDescription>
|
||||
<QtUicDir>$(ProjectDir)</QtUicDir>
|
||||
<QtUicFileName>ui_%(Filename).h</QtUicFileName>
|
||||
</QtUic>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\rtaudio\RTAudio.cpp" />
|
||||
<ClCompile Include="aboutbox.cpp" />
|
||||
<ClCompile Include="audioconverter.cpp" />
|
||||
<ClCompile Include="audiodevices.cpp" />
|
||||
<ClCompile Include="audiohandler.cpp" />
|
||||
<ClCompile Include="calibrationwindow.cpp" />
|
||||
<ClCompile Include="cluster.cpp" />
|
||||
<ClCompile Include="commhandler.cpp" />
|
||||
<ClCompile Include="controllersetup.cpp" />
|
||||
<ClCompile Include="database.cpp" />
|
||||
<ClCompile Include="freqmemory.cpp" />
|
||||
<ClCompile Include="..\hidapi\windows\hid.c" />
|
||||
<ClCompile Include="logcategories.cpp" />
|
||||
<ClCompile Include="loggingwindow.cpp" />
|
||||
<ClCompile Include="main.cpp" />
|
||||
<ClCompile Include="meter.cpp" />
|
||||
<ClCompile Include="pahandler.cpp" />
|
||||
<ClCompile Include="pttyhandler.cpp" />
|
||||
<ClCompile Include="..\qcustomplot\qcustomplot.cpp" />
|
||||
<ClCompile Include="qledlabel.cpp" />
|
||||
<ClCompile Include="repeatersetup.cpp" />
|
||||
<ClCompile Include="resampler\resample.c" />
|
||||
|
@ -162,482 +437,112 @@
|
|||
<ClCompile Include="udpcivdata.cpp" />
|
||||
<ClCompile Include="udphandler.cpp" />
|
||||
<ClCompile Include="udpserver.cpp" />
|
||||
<ClCompile Include="usbcontroller.cpp" />
|
||||
<ClCompile Include="wfmain.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\rtaudio\RTAUdio.h" />
|
||||
<QtMoc Include="aboutbox.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="audiodevices.h" />
|
||||
<QtMoc Include="loggingwindow.h" />
|
||||
<QtMoc Include="cluster.h" />
|
||||
<ClInclude Include="resampler\arch.h" />
|
||||
<QtMoc Include="audioconverter.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="audiohandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="audiotaper.h" />
|
||||
<QtMoc Include="calibrationwindow.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="cluster.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="colorprefs.h" />
|
||||
<QtMoc Include="commhandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="controllersetup.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="database.h" />
|
||||
<ClInclude Include="freqmemory.h" />
|
||||
<ClInclude Include="logcategories.h" />
|
||||
<QtMoc Include="loggingwindow.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="meter.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="packettypes.h" />
|
||||
<QtMoc Include="pahandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="prefs.h" />
|
||||
<QtMoc Include="pttyhandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="..\qcustomplot\qcustomplot.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="qledlabel.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="repeaterattributes.h" />
|
||||
<QtMoc Include="repeatersetup.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="resampler\resample_sse.h" />
|
||||
<QtMoc Include="rigcommander.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="rigctld.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="rigidentities.h" />
|
||||
<ClInclude Include="rigstate.h" />
|
||||
<QtMoc Include="rthandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="satellitesetup.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="selectradio.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="resampler\speex_resampler.h" />
|
||||
<QtMoc Include="tcpserver.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="transceiveradjustments.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="udpaudio.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="udpbase.h" />
|
||||
<QtMoc Include="udpcivdata.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="udphandler.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="udpserver.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="ulaw.h" />
|
||||
<QtMoc Include="usbcontroller.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<QtMoc Include="wfmain.h">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtMoc>
|
||||
<ClInclude Include="wfviewtypes.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<CustomBuild Include="debug\moc_predefs.h.cbt">
|
||||
<FileType>Document</FileType>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -faligned-new -Zi -MDd -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >debug\moc_predefs.h</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -faligned-new -Zi -MDd -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >debug\moc_predefs.h</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -faligned-new -Zi -MDd -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >debug\moc_predefs.h</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Generate moc_predefs.h</Message>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Generate moc_predefs.h</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">debug\moc_predefs.h;%(Outputs)</Outputs>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">debug\moc_predefs.h;%(Outputs)</Outputs>
|
||||
</CustomBuild>
|
||||
<CustomBuild Include="release\moc_predefs.h.cbt">
|
||||
<FileType>Document</FileType>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(QTDIR)\mkspecs\features\data\dummy.cpp;%(AdditionalInputs)</AdditionalInputs>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -fvisibility=hidden -fvisibility-inlines-hidden -faligned-new -O2 -MD -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >release\moc_predefs.h</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -fvisibility=hidden -fvisibility-inlines-hidden -faligned-new -O2 -MD -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >release\moc_predefs.h</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">cl -Bx"$(QTDIR)\bin\qmake.exe" -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -permissive- -Zc:__cplusplus -Zc:externConstexpr -fvisibility=hidden -fvisibility-inlines-hidden -faligned-new -O2 -MD -std:c++17 -utf-8 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -E $(QTDIR)\mkspecs\features\data\dummy.cpp 2>NUL >release\moc_predefs.h</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Generate moc_predefs.h</Message>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Generate moc_predefs.h</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">release\moc_predefs.h;%(Outputs)</Outputs>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">release\moc_predefs.h;%(Outputs)</Outputs>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
</CustomBuild>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<QtUic Include="aboutbox.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="calibrationwindow.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="controllersetup.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="loggingwindow.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="loggingwindow.ui" />
|
||||
<QtUic Include="repeatersetup.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="satellitesetup.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="selectradio.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="transceiveradjustments.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
<QtUic Include="wfmain.ui">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</QtUic>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
@ -670,34 +575,21 @@
|
|||
<None Include="qdarkstyle\rc\radio_unchecked.png" />
|
||||
<None Include="qdarkstyle\rc\radio_unchecked_disabled.png" />
|
||||
<None Include="qdarkstyle\rc\radio_unchecked_focus.png" />
|
||||
<None Include="resources\rc28.png" />
|
||||
<QtRcc Include="resources\resources.qrc">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">resources</InitFuncName><InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">resources</InitFuncName></QtRcc>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|x64'">resources</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">resources</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">resources</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">resources</InitFuncName>
|
||||
</QtRcc>
|
||||
<None Include="qdarkstyle\rc\right_arrow.png" />
|
||||
<None Include="qdarkstyle\rc\right_arrow_disabled.png" />
|
||||
<None Include="resources\shuttlepro.png" />
|
||||
<None Include="resources\shuttlexpress.png" />
|
||||
<None Include="qdarkstyle\rc\sizegrip.png" />
|
||||
<QtRcc Include="qdarkstyle\style.qrc">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">style</InitFuncName><InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">style</InitFuncName></QtRcc>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|x64'">style</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">style</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">style</InitFuncName>
|
||||
<InitFuncName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">style</InitFuncName>
|
||||
</QtRcc>
|
||||
<None Include="qdarkstyle\style.qss" />
|
||||
<None Include="qdarkstyle\rc\stylesheet-branch-end.png" />
|
||||
<None Include="qdarkstyle\rc\stylesheet-branch-more.png" />
|
||||
|
@ -707,11 +599,13 @@
|
|||
<None Include="qdarkstyle\rc\up_arrow.png" />
|
||||
<None Include="qdarkstyle\rc\up_arrow_disabled.png" />
|
||||
<None Include="resources\wfview.png" />
|
||||
<None Include="resources\xbox.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include=".\wfview_resource.rc" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /><ImportGroup Condition="Exists('$(QtMsBuild)\qt.targets')"><Import Project="$(QtMsBuild)\qt.targets" /></ImportGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Condition="Exists('$(QtMsBuild)\qt.targets')">
|
||||
<Import Project="$(QtMsBuild)\qt.targets" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="ExtensionTargets" />
|
||||
</Project>
|
|
@ -56,6 +56,9 @@
|
|||
<ClCompile Include="audioconverter.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="audiodevices.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="audiohandler.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
|
@ -68,18 +71,9 @@
|
|||
<ClCompile Include="commhandler.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="controllersetup.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="database.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="freqmemory.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\hidapi\windows\hid.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="logcategories.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
|
@ -98,9 +92,6 @@
|
|||
<ClCompile Include="pttyhandler.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\qcustomplot\qcustomplot.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="qledlabel.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
|
@ -149,9 +140,6 @@
|
|||
<ClCompile Include="udpserver.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="usbcontroller.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wfmain.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
|
@ -169,6 +157,9 @@
|
|||
<QtMoc Include="audioconverter.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<QtMoc Include="audiodevices.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<QtMoc Include="audiohandler.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
|
@ -181,18 +172,9 @@
|
|||
<QtMoc Include="cluster.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<ClInclude Include="colorprefs.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<QtMoc Include="commhandler.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<QtMoc Include="controllersetup.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<ClInclude Include="database.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="freqmemory.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
|
@ -211,15 +193,9 @@
|
|||
<QtMoc Include="pahandler.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<ClInclude Include="prefs.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<QtMoc Include="pttyhandler.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<QtMoc Include="..\qcustomplot\qcustomplot.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<QtMoc Include="qledlabel.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
|
@ -241,9 +217,6 @@
|
|||
<ClInclude Include="rigidentities.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="rigstate.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<QtMoc Include="rthandler.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
|
@ -280,90 +253,17 @@
|
|||
<ClInclude Include="ulaw.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<QtMoc Include="usbcontroller.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<QtMoc Include="wfmain.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</QtMoc>
|
||||
<ClInclude Include="wfviewtypes.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<CustomBuild Include="debug\moc_predefs.h.cbt">
|
||||
<Filter>Generated Files</Filter>
|
||||
</CustomBuild>
|
||||
<CustomBuild Include="release\moc_predefs.h.cbt">
|
||||
<Filter>Generated Files</Filter>
|
||||
</CustomBuild>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<QtUic Include="aboutbox.ui">
|
||||
|
@ -372,9 +272,6 @@
|
|||
<QtUic Include="calibrationwindow.ui">
|
||||
<Filter>Form Files</Filter>
|
||||
</QtUic>
|
||||
<QtUic Include="controllersetup.ui">
|
||||
<Filter>Form Files</Filter>
|
||||
</QtUic>
|
||||
<QtUic Include="loggingwindow.ui">
|
||||
<Filter>Form Files</Filter>
|
||||
</QtUic>
|
||||
|
@ -482,9 +379,6 @@
|
|||
<None Include="qdarkstyle\rc\radio_unchecked_focus.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resources\rc28.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<QtRcc Include="resources\resources.qrc">
|
||||
<Filter>Resource Files</Filter>
|
||||
</QtRcc>
|
||||
|
@ -494,12 +388,6 @@
|
|||
<None Include="qdarkstyle\rc\right_arrow_disabled.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resources\shuttlepro.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resources\shuttlexpress.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="qdarkstyle\rc\sizegrip.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
|
@ -533,11 +421,8 @@
|
|||
<None Include="resources\wfview.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resources\xbox.png">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="C:\Users\Phil\source\repos\wfview\wfview_resource.rc" />
|
||||
<ResourceCompile Include=".\wfview_resource.rc" />
|
||||
</ItemGroup>
|
||||
</Project>
|
|
@ -1,15 +1,68 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<LocalDebuggerEnvironment>PATH=$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(QTDIR)\bin%3bC:\QT\5.15.2\MSVC2019\bin%3b$(PATH)</LocalDebuggerEnvironment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<DebuggerFlavor>WindowsLocalDebugger</DebuggerFlavor>
|
||||
<LocalDebuggerDebuggerType>NativeOnly</LocalDebuggerDebuggerType>
|
||||
<LocalDebuggerAmpDefaultAccelerator>
|
||||
</LocalDebuggerAmpDefaultAccelerator>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<DebuggerFlavor>WindowsLocalDebugger</DebuggerFlavor>
|
||||
<LocalDebuggerDebuggerType>NativeOnly</LocalDebuggerDebuggerType>
|
||||
<LocalDebuggerAmpDefaultAccelerator />
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<QtLastBackgroundBuild>2022-12-28T10:08:37.8704645Z</QtLastBackgroundBuild>
|
||||
<QtLastBackgroundBuild>2022-08-22T10:47:36.6935363Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2022-08-21T18:58:23.4329764Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2022-08-21T18:58:23.4329764Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2023-01-01T21:18:41.6777849Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2023-01-01T21:18:41.0898794Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="QtSettings" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<QtLastBackgroundBuild>2022-12-28T10:08:38.7333469Z</QtLastBackgroundBuild>
|
||||
<QtLastBackgroundBuild>2022-08-22T10:47:49.1255783Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2022-08-20T19:06:43.4553894Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2022-08-20T19:06:43.4553894Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2023-01-02T15:55:24.4600387Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="QtSettings">
|
||||
<QtLastBackgroundBuild>2023-01-01T21:18:42.4124187Z</QtLastBackgroundBuild>
|
||||
</PropertyGroup>
|
||||
</Project>
|
|
@ -45,7 +45,20 @@ struct timekind {
|
|||
bool isMinus;
|
||||
};
|
||||
|
||||
struct errorType {
|
||||
errorType() : alert(false) {};
|
||||
errorType(bool alert, QString message) : alert(alert), message(message) {};
|
||||
errorType(bool alert, QString device, QString message) : alert(alert), device(device), message(message) {};
|
||||
errorType(QString device, QString message) : alert(false), device(device), message(message) {};
|
||||
errorType(QString message) : alert(false), message(message) {};
|
||||
|
||||
bool alert;
|
||||
QString device;
|
||||
QString message;
|
||||
};
|
||||
|
||||
enum audioType {qtAudio,portAudio,rtAudio};
|
||||
enum codecType { LPCM, PCMU, OPUS };
|
||||
|
||||
|
||||
#endif // WFVIEWTYPES_H
|
||||
|
|
Ładowanie…
Reference in New Issue