creating SAPI tts engine

hello,
i want to create a SAPI tts engine and as you know, it requires com to be used
now, i have a question:
can i use IUnknown in my class instead of deriving from ISpTTSEngine and ISpObjectWithToken?
because if i include spddk.h in MinGW, it gives a lot of errors related to vs for example, __in_out not defined
i've defined them and it worked, but i couldn't use std::string and other std stuff
so, can i use IUnknown instead of deriving from those 2 interfaces and write Speak andGetOutput methods?
thanks
Is is really necessary to use COM?
Things are much easier in .NET.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#using <mscorlib.dll>
#using <System.Speech.dll>

using namespace System;
using namespace System::Speech::Synthesis;

int main()
{
    String^ output = "Hello from the Text to Speech Engine";
    SpeechSynthesizer^ ss = gcnew SpeechSynthesizer();
    ss->Speak(output);

    Console::ReadKey();
    return 0;
}
The problem lies in MinGW headers, recommended to use Visual Studio instead (or just its headers from another IDE if you prefer)
Topic archived. No new replies allowed.