blob: 3740628b8f5b3953e8c0d15ac474eb622a4be879 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
// Copyright 2007-2021 The Mumble Developers. All rights reserved.
// Use of this source code is governed by a BSD-style license
// that can be found in the LICENSE file at the root of the
// Mumble source tree or at <https://www.mumble.info/LICENSE>.
#ifndef MUMBLE_MUMBLE_AUDIOWIZARD_H_
#define MUMBLE_MUMBLE_AUDIOWIZARD_H_
#include "ui_AudioWizard.h"
#include "AudioInput.h"
#include "AudioOutput.h"
#include "AudioStats.h"
#include "Settings.h"
class AudioWizard : public QWizard, public Ui::AudioWizard {
private:
Q_OBJECT
Q_DISABLE_COPY(AudioWizard)
/// Which echo cancellation is usable depends on the audio backend and the device combination.
/// This function will iterate through the list of available echo cancellation in the audio backend and check with
/// the backend whether this echo cancellation option works for current device combination.
EchoCancelOptionID firstUsableEchoCancellation(AudioInputRegistrar *air, QString outputSys);
protected:
QList< QVariant > pttButtons;
bool bTransmitChanged;
QGraphicsScene *qgsScene;
QGraphicsItem *qgiSource;
AudioOutputSample *aosSource;
float fAngle;
float fX, fY;
Settings sOldSettings;
QTimer *ticker;
bool bInit;
bool bDelay;
bool bLastActive;
QPixmap qpTalkingOn, qpTalkingOff;
int iMaxPeak;
int iTicks;
void restartAudio();
void playChord();
bool eventFilter(QObject *, QEvent *) Q_DECL_OVERRIDE;
public slots:
void on_qcbInput_activated(int);
void on_qcbInputDevice_activated(int);
void on_qcbOutput_activated(int);
void on_qcbOutputDevice_activated(int);
void on_qsOutputDelay_valueChanged(int);
void on_qsMaxAmp_valueChanged(int);
void on_Ticker_timeout();
void on_qsVAD_valueChanged(int);
void on_qrAmplitude_clicked(bool);
void on_qrSNR_clicked(bool);
void on_qrPTT_clicked(bool);
void on_qpbPTT_clicked();
void on_qcbEcho_clicked(bool);
void on_qcbHeadphone_clicked(bool);
void on_qcbPositional_clicked(bool);
void on_qcbAttenuateOthers_clicked(bool);
void on_qcbHighContrast_clicked(bool);
void on_qrbQualityUltra_clicked();
void on_qrbQualityBalanced_clicked();
void on_qrbQualityLow_clicked();
void on_qrbQualityCustom_clicked();
void showPage(int);
void updateTriggerWidgets(bool);
public:
AudioWizard(QWidget *parent);
void reject() Q_DECL_OVERRIDE;
void accept() Q_DECL_OVERRIDE;
bool validateCurrentPage() Q_DECL_OVERRIDE;
virtual int nextId() const Q_DECL_OVERRIDE;
};
#endif
|