-
Notifications
You must be signed in to change notification settings - Fork 0
/
stenographer.h
73 lines (65 loc) · 1.73 KB
/
stenographer.h
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
#ifndef STENOGRAPHER_H
#define STENOGRAPHER_H
#include <QObject>
#include <QVariant>
#include <QFile>
#include <QAudioFormat>
#include <QAudioOutput>
class RecThread;
class GoogleSpeech;
class QAudioInput;
class DownloadAndPlay;
class Stenographer : public QObject
{
Q_OBJECT
public:
explicit Stenographer(QObject *parent = 0);
RecThread * getRec(){ return recThread; }
signals:
void updateData(QVariant);
void updateLog(QVariant);
void setImage(QVariant);
void setVolumeValue(QVariant);
void setVolumeRange(QVariant);
void testStopped(QVariant);
void needToStop();
void setAudioDevices(QVariant);
public slots:
void getOptions();
void beginStopRec();
void stopRec();
void playLast(QVariant);
void convertAndSent();
void closeFile();
void addRecText(QString);
void logging(QString);
void getVolumeValue(QVariant);
void getVolumeRange(QVariant);
void startTest();
void _testStopped(int);
void switchAutoMod();
void setOverK(QVariant);
void setIT1(QVariant);
void setITstep1(QVariant);
void setIT2(QVariant);
void setITstep2(QVariant);
void setDelay(QVariant);
void changeAudioDevice(QVariant);
void saveText(QVariant,QVariant);
void setSaveTempFiles(QVariant);
void setNewLang(QVariant);
private:
QString lastWavFile;
RecThread * recThread;
QAudioFormat format;
QAudioOutput* outputAudio;
GoogleSpeech * googleSpeech;
DownloadAndPlay * downloadAndPlay;
QFile * m_file;
bool m_autoMod;
bool m_isActive;
bool m_saveTmpFiles;
QString lang;
// QAudioInput * inputAudio;
};
#endif // STENOGRAPHER_H