1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
9 * Copyright (C) 2007 by Dominik Wenger
10 * $Id: voicefile.h 15932 2007-12-15 13:13:57Z domonoky $
12 * All files in this archive are subject to the GNU General Public License.
13 * See the file COPYING in the source tree root for full license agreement.
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
18 ****************************************************************************/
25 #include "progressloggerinterface.h"
34 #include "voicefont.h"
37 class VoiceFileCreator
:public QObject
41 VoiceFileCreator(QObject
* parent
=0);
44 bool createVoiceFile(ProgressloggerInterface
* logger
);
47 void setSettings(QSettings
* uSettings
,QSettings
* dSettings
) { userSettings
= uSettings
;deviceSettings
= dSettings
;}
49 void setMountPoint(QString mountpoint
) {m_mountpoint
=mountpoint
; }
50 void setTargetId(int id
){m_targetid
= id
;}
51 void setLang(QString name
){m_lang
=name
;}
52 void setWavtrimThreshold(int th
){m_wavtrimThreshold
= th
;}
53 void setProxy(QUrl proxy
){m_proxy
= proxy
;}
57 void downloadRequestFinished(int id
, bool error
);
58 void downloadDone(bool error
);
59 void updateDataReadProgress(int read
, int total
);
63 // ptr to encoder, tts and settings
66 QSettings
*userSettings
;
67 QSettings
*deviceSettings
;
72 QString filename
; //the temporary file
74 QString m_mountpoint
; //mountpoint of the device
75 QString m_path
; //path where the wav and mp3 files are stored to
76 int m_targetid
; //the target id
77 QString m_lang
; // the language which will be spoken
78 int m_wavtrimThreshold
;
80 ProgressloggerInterface
* m_logger
;