00001 /* 00002 ----------------------------------------------------------------------------- 00003 This source file is part of OpenSpace3D 00004 For the latest info, see http://www.openspace3d.com 00005 00006 Copyright (c) 2010 I-maginer 00007 00008 This program is free software; you can redistribute it and/or modify it under 00009 the terms of the GNU Lesser General Public License as published by the Free Software 00010 Foundation; either version 2 of the License, or (at your option) any later 00011 version. 00012 00013 This program is distributed in the hope that it will be useful, but WITHOUT 00014 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 00015 FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. 00016 00017 You should have received a copy of the GNU Lesser General Public License along with 00018 this program; if not, write to the Free Software Foundation, Inc., 59 Temple 00019 Place - Suite 330, Boston, MA 02111-1307, USA, or go to 00020 http://www.gnu.org/copyleft/lesser.txt 00021 00022 You may alternatively use this source under the terms of a specific version of 00023 the OpenSpace3D Unrestricted License provided you have obtained such a license from 00024 I-maginer. 00025 ----------------------------------------------------------------------------- 00026 */ 00027 00028 00035 #ifndef __PLUGIN_H__ 00036 #define __PLUGIN_H__ 00037 00038 00040 #include <scol.h> 00041 #include <sapi.h> 00042 #include <sphelper.h> 00043 #include <spuihelp.h> 00044 #include <list> 00045 #include <mlang.h> 00046 #include "speech.h" 00047 #include "reco.h" 00048 #include <string> 00049 00050 00052 extern cbmachine ww; 00053 extern HWND HScol ; 00054 00055 00057 extern int OBJSPEECHSCOL; 00058 extern int OBJRECOSCOL; 00059 00060 00062 extern int SCOL_SPEECH_END_CB ; 00063 extern int SPEECH_END_CB; 00064 00065 extern int SCOL_SPEECH_WORD_CB; 00066 extern int SPEECH_WORD_CB; 00067 00068 extern int SCOL_SPEECH_TEXT_CB; 00069 extern int SPEECH_TEXT_CB; 00070 00071 extern int SCOL_SPEECH_PHONEME_CB; 00072 extern int SPEECH_PHONEME_CB; 00073 00074 00076 extern int SCOL_RECO_END_CB; 00077 extern int RECOGNITION_END_CB; 00078 00079 extern int SCOL_RECO_START_CB; 00080 extern int RECOGNITION_START_CB; 00081 00082 extern int SCOL_RECO_TEXT_CB; 00083 extern int RECOGNITION_TEXT_CB; 00084 00085 extern int SCOL_RECO_TEXTS_ALT_CB; 00086 extern int RECOGNITION_TEXTS_ALT_CB; 00087 00088 extern int SCOL_RECO_WORDS_CB; 00089 extern int RECOGNITION_WORDS_CB; 00090 00091 00093 wchar_t* convertCharToLPCWSTR(char * s_text); 00094 char* convertWcharToChar(wchar_t * w_text); 00095 00096 00098 struct pTextRec 00099 { 00100 CSpDynamicString altText ; 00101 float altConfidence ; 00102 }; 00103 00104 00106 class cbData 00107 { 00108 00109 public : 00110 00111 cbData(){} 00112 cbData(char *param1){ this->paramChar = param1; } 00113 cbData(int val){ this->val=val; } 00114 cbData(std::list <char *> lParamWord){ this->lParamWord = lParamWord; } 00115 cbData(std::list <pTextRec> lParamText1){ this->lParamText = lParamText1; } 00116 00117 void setParamChar(char *param1){ this->paramChar = param1; } 00118 char* getParamChar(){ return paramChar; } 00119 int getVal(){return val;} 00120 00121 std::list <pTextRec> getlParamText(){return lParamText;} 00122 std::list <char *> getlParamWords(){return lParamWord;} 00123 00124 ~cbData(){} 00125 private: 00126 00127 char * paramChar; 00128 int val; 00129 std::list <char *> lParamWord; 00130 std::list <pTextRec> lParamText; 00131 }; 00132 00133 #endif
1.6.3