The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Speech::Festival::Synthesiser - Simple text-to-speech using festival.

SYNOPSIS

  use Speech::Speech::Festival::Synthesiser;
  $festival = new Speech::Festival::Synthesiser 'serverhost', 1314;

  start $festival;
  stop $festival;

  @voices = voice_list $festival;
  voice $festival "myvoice";
  voice_description $festival;

  synth_description $festival;
  speak $festival $text;

DESCRIPTION

Speech::Festival::Synthesiser provides a simple way to add speech to a perl application. It is a sub-class of Speech::Festival and so you can use any of the methods in that class to manipulate festival if necessary.

This package conform to the interface defined by Speech::Synthesiser and so provides a synthesiser for use throughthat interface.

Actual sound output is provided by an auiliary class, by default Audio::FileWave which runs an external program to play sound, but you can replace it with another class if you have a better way of playing sounds (eg a perl extension providing sound output), see the documentation for Audio::FileWave for the interface an alternative should provide should implement.

If you do use Audio::FileWave you may need to set up the command it uses to play sounds, see the documentation for "set_play_command" in Audio::FileWave.

$festival = new Speech::Festival::Synthesiser -host => 'serverhost', -port => 1314, ...

Create a new festival session which will connect to the given host and port. If ommitted these default to localhost and 1314.

start $festival;

Connect to festival and inistilise the session. Returns true if all is well, false otherwise. In the event of an error the variable $festival_error conatains a description of it.

stop $festival;

Disconnect from festival. The connection may be reopened later with "start", but any state will have been lost.

@voices = voice_list $festival;

Return a list of the voices available from this server.

voice $festival "myvoice";

Select a voice.

voice_description $festival;

Returns the description of the current voice.

synth_description $festival;

Synthesize the standard festival introductory text.

speak $festival $text;

Speak the given text.

AUTHOR

Richard Caley, R.Caley@ed.ac.uk

SEE ALSO

Speech::Synthesiser, Speech::Festival, Audio::FileWave, perl(1), festival(1), Festival Documentation