ptts.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
#ifndef _PTEXTTOSPEECH
00049
#define _PTEXTTOSPEECH
00050
00051
#ifdef P_USE_PRAGMA
00052
#pragma interface
00053
#endif
00054
00055
#include <ptlib.h>
00056
#include <ptclib/ptts.h>
00057
00058 class PTextToSpeech :
public PObject
00059 {
00060
PCLASSINFO(
PTextToSpeech,
PObject);
00061
public:
00062 enum TextType {
00063
Default,
00064
Literal,
00065
Digits,
00066
Number,
00067
Currency,
00068
Time,
00069
Date,
00070
Phone,
00071
IPAddress,
00072
Duration
00073 };
00074
00075
virtual PStringArray GetVoiceList() = 0;
00076
virtual BOOL SetVoice(
const PString & voice) = 0;
00077
00078
virtual BOOL SetRate(
unsigned rate) = 0;
00079
virtual unsigned GetRate() = 0;
00080
00081
virtual BOOL SetVolume(
unsigned volume) = 0;
00082
virtual unsigned GetVolume() = 0;
00083
00084
virtual BOOL OpenFile (
const PFilePath & fn) = 0;
00085
virtual BOOL OpenChannel(
PChannel * chanel) = 0;
00086
virtual BOOL
IsOpen() = 0;
00087
00088
virtual BOOL
Close () = 0;
00089
virtual BOOL Speak (
const PString & text, TextType hint = Default) = 0;
00090 };
00091
00092
#ifdef _WIN32
00093
# ifndef P_DISABLE_FACTORY_INSTANCES
00094
# ifndef P_FACTORY_INSTANCE_PTextToSpeech
00095
# define P_FACTORY_INSTANCE_PTextToSpeech 1
00096
# pragma message("Including PTextToSpeech factory loader")
00097
PLOAD_FACTORY(
PTextToSpeech,
PString)
00098 # endif
00099
# endif
00100
#endif
00101
00102
#endif
Generated on Sat Jul 24 15:35:56 2004 for PWLib by
1.3.7