Text to Speech with Monologue for Windows 
Author Message
 Text to Speech with Monologue for Windows

Here is the source code for Text to Speech with Monologue for Windows

'======>> Filename: README.TXT <<=======

Interfacing to Monologue For Windows

Requirements:

        Works with Monologue for Windows v. 1.02 or
        any Monologue that uses the SPEECH.DLL.

        Visual Basic for Windows, any version

        You Monologue for Windows directory should be
        included in your autoexec.bat path statement.

How to run the sample:

        In the SPEECH.BAS file you will need to change the
        directory in the 2 declare statements to your own
        directory where Monologue is located.

        Thats it... run the sample.  The interface to the
        DLL is very easy to understand.

        I have the documentation on interfacing to the
        newer Monologues that use the FB_SPCH.* files.
        But I have to go thru my license agreement and
        see if I am able to give this out.  But the
        older Monologue works just a well and it takes
        less memory.  I use the older one for all of my
        projects even though I have the development kit
        for the newer Monologues.  Here in Seattle there
        is a liquidation company that still sells the older
        Monologue, still shrink wrapped.  Let me know and
        I can chk out the pricing.

        Also for you developers out there... First Byte
        offers a development package, called their Provoice
        Aware Development Kit.  It is a development kit for
        their newer text to speech engine, same one that the
        newer Monologues uses.  The development kit is free.
        They just have you fill out some info regarding what
        products you are developing.  They also have voice
        fonts that they include, including a female voice.
        Its a pretty good deal if you develop apps for the
        general public.

        Contact for First Byte:

                First Byte
                19840 Pioneer Ave
                Torrance, CA 90503

                Voice: 310-793-0610
                BBS:   310-793-0602

        You can get a signup kit for their Provoice Aware
        Package off of their BBS.  Its in Word for Windows 2.0
        format and the filename is SIGNUP.EXE.

        By the way, I am not an employee of First Byte.

        Have fun!

        Dale Morrison
        Smart Home Technology

        Voice: (206) 813-8410  USA

'======>> Filename: SPEECH.MAK <<=======

SPEECH.FRM
C:\WINDOWS\SYSTEM\THREED.VBX
SPEECH.BAS
ProjWinSize=3,568,229,157
ProjWinShow=2
IconForm="dfrmSpeechConfig"

'======>> Filename: SPEECH.FRM <<=======

VERSION 2.00
Begin Form dfrmSpeechConfig
   BackColor       =   &H00C0C0C0&
   Caption         =   "Speech Configuration"
   ClientHeight    =   4785
   ClientLeft      =   2520
   ClientTop       =   1830
   ClientWidth     =   5685
   Height          =   5190
   Left            =   2460
   LinkTopic       =   "Form1"
   ScaleHeight     =   540
   ScaleWidth      =   540
   Top             =   1485
   Width           =   5805
   Begin CommandButton cmdCancel
      Cancel          =   -1  'True
      Caption         =   "&Cancel"
      Height          =   495
      Left            =   3900
      TabIndex        =   1
      Top             =   3120
      Width           =   1215
   End
   Begin HScrollBar hsbVolume
      Height          =   255
      Left            =   540
      Max             =   9
      TabIndex        =   6
      Top             =   3900
      Width           =   2415
   End
   Begin HScrollBar hsbSpeed
      Height          =   255
      Left            =   540
      Max             =   9
      TabIndex        =   7
      Top             =   2940
      Width           =   2415
   End
   Begin SSPanel pnl3dVolume
      AutoSize        =   3  'AutoSize Child To Panel
      BackColor       =   &H00C0C0C0&
      BevelInner      =   1  'Inset
      BevelOuter      =   0  'None
      BevelWidth      =   2
      BorderWidth     =   2
      Font3D          =   0  'None
      Height          =   375
      Left            =   480
      TabIndex        =   8
      Top             =   3840
      Width           =   2535
   End
   Begin SSPanel pnl3dSpeed
      AutoSize        =   3  'AutoSize Child To Panel
      BackColor       =   &H00C0C0C0&
      BevelInner      =   1  'Inset
      BevelOuter      =   0  'None
      BevelWidth      =   2
      BorderWidth     =   2
      Font3D          =   0  'None
      Height          =   375
      Left            =   480
      TabIndex        =   16
      Top             =   2880
      Width           =   2535
   End
   Begin HScrollBar hsbPitch
      Height          =   255
      Left            =   540
      Max             =   9
      TabIndex        =   15
      Top             =   1980
      Width           =   2415
   End
   Begin SSPanel pnl3dPitch
      AutoSize        =   3  'AutoSize Child To Panel
      BackColor       =   &H00C0C0C0&
      BevelInner      =   1  'Inset
      BevelOuter      =   0  'None
      BevelWidth      =   2
      BorderWidth     =   2
      Font3D          =   0  'None
      Height          =   375
      Left            =   480
      TabIndex        =   14
      Top             =   1920
      Width           =   2535
   End
   Begin TextBox txtTestString
      Height          =   855
      Left            =   540
      MultiLine       =   -1  'True
      ScrollBars      =   2  'Vertical
      TabIndex        =   10
      Top             =   300
      Width           =   4515
   End
   Begin SSPanel pnl3dText
      AutoSize        =   3  'AutoSize Child To Panel
      BackColor       =   &H00C0C0C0&
      BevelInner      =   1  'Inset
      BevelOuter      =   0  'None
      BevelWidth      =   2
      BorderWidth     =   2
      Font3D          =   0  'None
      Height          =   975
      Left            =   480
      TabIndex        =   9
      Top             =   240
      Width           =   4635
   End
   Begin CommandButton cmdOk
      Caption         =   "&Ok"
      Height          =   495
      Left            =   3900
      TabIndex        =   2
      Top             =   3720
      Width           =   1215
   End
   Begin CommandButton cmdTest
      BackColor       =   &H00C0C0C0&
      Caption         =   "&Test"
      Default         =   -1  'True
      Height          =   495
      Left            =   3900
      TabIndex        =   0
      Top             =   2520
      Width           =   1215
   End
   Begin Label lblVolumeValue
      BackColor       =   &H00C0C0C0&
      Height          =   195
      Left            =   1320
      TabIndex        =   13
      Top             =   3540
      Width           =   375
   End
   Begin Label lblSpeedValue
      BackColor       =   &H00C0C0C0&
      Height          =   195
      Left            =   1260
      TabIndex        =   12
      Top             =   2580
      Width           =   375
   End
   Begin Label lblPitchValue
      BackColor       =   &H00C0C0C0&
      Height          =   195
      Left            =   1140
      TabIndex        =   11
      Top             =   1620
      Width           =   375
   End
   Begin Label lblVolume
      AutoSize        =   -1  'True
      BackColor       =   &H00C0C0C0&
      Caption         =   "Volume:"
      Height          =   195
      Left            =   540
      TabIndex        =   5
      Top             =   3540
      Width           =   690
   End
   Begin Label lblSpeed
      AutoSize        =   -1  'True
      BackColor       =   &H00C0C0C0&
      Caption         =   "Speed:"
      Height          =   195
      Left            =   540
      TabIndex        =   4
      Top             =   2580
      Width           =   615
   End
   Begin Label lblPitch
      AutoSize        =   -1  'True
      BackColor       =   &H00C0C0C0&
      Caption         =   "Pitch:"
      Height          =   195
      Left            =   540
      TabIndex        =   3
      Top             =   1620
      Width           =   510
   End
End

Sub cmdCancel_Click ()
    End
End Sub

Sub cmdOk_Click ()
    End
End Sub

Sub cmdTest_Click ()

    SpeakText txtTestString.Text

    txtTestString.SetFocus
    txtTestString.SelStart = 0
    txtTestString.SelLength = Len(txtTestString.Text)

End Sub

Sub Form_Load ()
    lblPitchValue.Caption = hsbPitch.Value
    lblSpeedValue.Caption = hsbSpeed.Value
    lblVolumeValue.Caption = hsbVolume.Value

    SendSpeechGlobals

End Sub

Sub hsbPitch_Change ()

    lblPitchValue.Caption = hsbPitch.Value
    SetSpeechPitch hsbPitch.Value

End Sub

Sub hsbSpeed_Change ()

    lblSpeedValue.Caption = hsbSpeed.Value
    SetSpeechSpeed hsbSpeed.Value

End Sub

Sub hsbVolume_Change ()

    lblVolumeValue.Caption = hsbVolume.Value
    SetSpeechVolume hsbVolume.Value

End Sub

'======>> Filename: SPEECH.BAS <<=======

Declare Sub SpeakText Lib "\old_mono\speech.dll" Alias "Say" (ByVal Text As String)
Declare Function SetSpeechGlobals Lib "\old_mono\speech.dll" Alias "SetSayGlobals" (ByVal Reserved1 As Integer, ByVal Reserved2 As Integer, ByVal Pitch As Integer, ByVal Speed As Integer, ByVal Vol As Integer) As Integer

Dim mw_SpeechPitch As Integer
Dim mw_SpeechSpeed As Integer
Dim mw_SpeechVolume As Integer

Sub SendSpeechGlobals ()
    Dim w_Result As Integer

    w_Result = SetSpeechGlobals(0, 0, mw_SpeechPitch, mw_SpeechSpeed, mw_SpeechVolume)

End Sub

Sub SetSpeechPitch (ByVal w_Value As Integer)

    If (w_Value >= 0 And w_Value <= 9) Then
        mw_SpeechPitch = w_Value
        SendSpeechGlobals
    End If

End Sub

Sub SetSpeechSpeed (ByVal w_Value As Integer)

    If (w_Value >= 0 And w_Value <= 9) Then
        mw_SpeechSpeed = w_Value
        SendSpeechGlobals
    End If

End Sub

Sub SetSpeechVolume (ByVal w_Value As Integer)

    If (w_Value >= 0 And w_Value <= 9) Then
        mw_SpeechVolume = w_Value
        SendSpeechGlobals
    End If

End Sub



Sat, 18 Oct 1997 03:00:00 GMT
 
 [ 1 post ] 

 Relevant Pages 

1. Text to Speech and Speech to Text - ActiveX Control

2. Text to speech from VFP

3. Text to Speech with DDE?

4. converting text to speech using oracle-D2K

5. Text justification problems with 4.1 on Windows (fields and text boxes)

6. Nested speech marks in sql insert

7. Upcoming speeches

8. OSDA Keynote Speech - News from the Source

9. Speech SDK..Help Please

10. Office XP - Speech Recognition Dialog on ADP startup

11. English query with speech recognition input ?

12. Speech Marks and Apostraphies


 
Powered by phpBB® Forum Software