Debian Codegraph @

sapi/FliteCMUKalDiphone/FliteCMUKalDiphoneObj.h

raw
1 /*************************************************************************/
2 /* */
3 /* Cepstral, LLC */
4 /* Copyright (c) 2001 */
5 /* All Rights Reserved. */
6 /* */
7 /* Permission is hereby granted, free of charge, to use and distribute */
8 /* this software and its documentation without restriction, including */
9 /* without limitation the rights to use, copy, modify, merge, publish, */
10 /* distribute, sublicense, and/or sell copies of this work, and to */
11 /* permit persons to whom this work is furnished to do so, subject to */
12 /* the following conditions: */
13 /* 1. The code must retain the above copyright notice, this list of */
14 /* conditions and the following disclaimer. */
15 /* 2. Any modifications must be clearly marked as such. */
16 /* 3. Original authors' names are not deleted. */
17 /* 4. The authors' names are not used to endorse or promote products */
18 /* derived from this software without specific prior written */
19 /* permission. */
20 /* */
21 /* CEPSTRAL, LLC AND THE CONTRIBUTORS TO THIS WORK DISCLAIM ALL */
22 /* WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED */
23 /* WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL */
24 /* CEPSTRAL, LLC NOR THE CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, */
25 /* INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER */
26 /* RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION */
27 /* OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR */
28 /* IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */
29 /* */
30 /*************************************************************************/
31 /* Author: David Huggins-Daines ([email protected]) */
32 /* Date: December 2001 */
33 /*************************************************************************/
34 /* */
35 /* FliteCMUKalDiphone.h: instantiation of Flite SAPI for cmu_us_kal */
36 /* */
37 /*************************************************************************/
38
39 #ifndef __FLITECMUKALDIPHONEOBJ_H_
40 #define __FLITECMUKALDIPHONEOBJ_H_
41
42 #include "resource.h"
43 #include "FliteTTSEngineObj.h"
44 #include "flite_sapi_usenglish.h"
45
46 extern "C" {
47 #include "voxdefs.h"
48 cst_voice *REGISTER_VOX(const char *voxdir);
49 void UNREGISTER_VOX(cst_voice *vox);
50 };
51
52 class ATL_NO_VTABLE CFliteCMUKalDiphoneObj :
53 public CComCoClass<CFliteCMUKalDiphoneObj, &CLSID_FliteCMUKalDiphoneObj>,
54 public CFliteTTSEngineObj
55 {
56 public:
57 DECLARE_REGISTRY_RESOURCEID(IDR_FLITECMUKALDIPHONEOBJ)
58
59 BEGIN_COM_MAP(CFliteCMUKalDiphoneObj)
60 COM_INTERFACE_ENTRY(ISpTTSEngine)
61 COM_INTERFACE_ENTRY(ISpObjectWithToken)
62 END_COM_MAP()
63
64 public:
65 CFliteCMUKalDiphoneObj() {
66 regfunc = REGISTER_VOX;
67 unregfunc = UNREGISTER_VOX;
68 phonemefunc = flite_sapi_usenglish_phoneme;
69 visemefunc = flite_sapi_usenglish_viseme;
70 featurefunc = flite_sapi_usenglish_feature;
71 pronouncefunc = flite_sapi_usenglish_pronounce;
72 }
73 ~CFliteCMUKalDiphoneObj() {}
74 };
75
76 #endif //__FLITECMUKALDIPHONEOBJ_H_