sapi registration

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi..

I am trying to use Sapi 5.0 for windows ce
The problem is when I try to instantiate the ISpVoice interface of Sapi it returns class not registered;
hr = CoCreateInstance(CLSID_SpVoice, NULL, CLSCTX_INPROC_SERVER, IID_ISpVoic
,(VOID FAR **) &pVoice);

Do I need Sapi.dll on my device??
I am using the sapi.h & sapi.idl shipped with wince .net 4.
Where can I get sapi.dll???

Any help is appreciated.
Thanks
Nidhi
 
SAPI can be built into your custom CE.NET platform using Platform Builder,
you'll also need a voice engine as well as the API itself. What sort of
device are you using?

Peter
 
CE 4.x has a *lot* of features available. I've not seen any shipped device
that included all of them (I tried to make one once just to see how insanely
big the image would be). Did your OEM include SAPI? Even if they did I've
found it very near impossible to actually get it to function for even simple
TTS - just trying to compile the voices is not straightforward. After a
week of work I abandoned it and the customer went with a 3rd party TTS
solution.

The moral of that long-winded answer is that only your OEM can answer your
question.
 
Hi Peter

Thanks for your reply.
I am doing exactly that. I created a custome platform(webpad) containing the sapi5.0 sdk using platform builder. Then created a text to speech client in evc++. Following is the code I use

ISpVoice *pVoice = NULL
// Initialise COM
hr = CoInitializeEx(NULL, COINIT_MULTITHREADED);
hr = CoCreateInstance(CLSID_SpVoice, NULL, CLSCTX_INPROC_SERVER, IID_ISpVoic
,(VOID FAR **) &pVoice);
if(pVoice

hr = pVoice->Speak(L"Hello",SPF_DEFAULT,NULL)
pVoice->Release();


The program fails at pVoice->Speak(L"Hello",SPF_DEFAULT,NULL)
returning -2147200966 in hr.

I have not included any voice engine exclusively for this.
Do I need to do any configurations.

Thanks in advanc
Nidhi
 
You picked a strange group in which to ask. The Platform Builder group would
be the normal place for Platform Builder questions. I think that, if you're
talking about the Speech API, you should simply add the Speech API item from
the CE6 catalog to your operating system configuration and do a clean sysgen.
I can't say that I've actually verified that it gets built into the OS, but
it should.

Paul T.
 
Back
Top