PRB: Speech.h Does Not Work with the Borland C++ CompilerID: Q147123
|
The Speech.h header file required to build applications written with the
Microsoft Speech SDK version 1.0 is not compatible with the Borland C\C++
compiler at this time. However, it is compatible with Microsoft Visual C++
versions 2.2 and 4.0, as well as the Symantec C++ version 7.2 compiler.
NOTE: Some products mentioned in this article are manufactured by vendors
independent of Microsoft; we make no warranty, implied or otherwise,
regarding these products' performance or reliability.
Microsoft compilers support a 64-bit integer type, _int64. Borland does not support this type. Also, Borland's compiler does not allow zero-length arrays, which are used in the speech-recognition APIs.
_int64 issue:
A workaround has been tried, which does seem to work, though its
effectiveness has not been rigorously verified. To implement the
workaround, change the following line in Speech.h:
typedef unsigned _int64 QWORD, * PQWORD;
#ifdef __BORLANDC__
typedef struct _tagQWORD {BYTE abData[8];} QWORD *PQWORD;
#else
typedef unsigned _int64 QWORD, *PQWORD;
#endif //__BORLANDC__
typedef struct {
DWORD dwSize;
DWORD dwUniqueID;
BYTE abData[0];
} SRCFGRULE, * PSRCFGRULE;
This behavior demonstrates a design incompatibility between the two products.
These problems only affect the speech-recognition and text-to-speech APIs. Voice-command and voice-text applications do not use QWORDs or the above- named structures. Therefore, users of the voice-command and voice-text APIs may make these changes, compile, and not worry about the results. If you use the speech-recognition and text-to-speech APIs, you must test the functions that use QWORDS rigorously to be sure that the values are coming out properly, and you must check carefully to ensure that the structures are being properly interpreted.
Additional query words: 1.00 SAPI VCMD VTXT SR TTS
Keywords : kb3rdparty kbmm MMSpeech
Version : 1.00 | 1.00
Platform : NT WINDOWS
Issue type :
Last Reviewed: March 6, 1999