Class CMUDiphoneVoice

All Implemented Interfaces:
Dumpable, UtteranceProcessor, de.dfki.lt.freetts.ConcatenativeVoice

public class CMUDiphoneVoice extends CMUVoice implements de.dfki.lt.freetts.ConcatenativeVoice
Defines an unlimited-domain diphone synthesis based voice
  • Field Details

    • database

      protected URL database
  • Constructor Details

    • CMUDiphoneVoice

      public CMUDiphoneVoice()
      Creates a simple voice. This is merely for backwards compatibility with versions of FreeTTS earlier than v1.2 (i.e., before the voice manager was introduced).
    • CMUDiphoneVoice

      public CMUDiphoneVoice(String name, Gender gender, Age age, String description, Locale locale, String domain, String organization, CMULexicon lexicon, URL database)
      Creates a simple voice
      Parameters:
      name - the name of the voice
      gender - the gender of the voice
      age - the age of the voice
      description - a human-readable string providing a description that can be displayed for the users.
      locale - the locale of the voice
      domain - the domain of this voice. For example,
      organization - the organization which created the voice "general", "time", or "weather".
      lexicon - the lexicon to load
      database - a url to the unit database file for this voice
  • Method Details

    • getDatabase

      public URL getDatabase()
      Gets the url to the database that defines the unit data for this voice.
      Specified by:
      getDatabase in interface de.dfki.lt.freetts.ConcatenativeVoice
      Returns:
      a url to the database
    • setupFeatureSet

      protected void setupFeatureSet() throws IOException
      Sets the FeatureSet for this Voice.
      Overrides:
      setupFeatureSet in class CMUVoice
      Throws:
      IOException - if an I/O error occurs
    • getPostLexicalAnalyzer

      protected UtteranceProcessor getPostLexicalAnalyzer() throws IOException
      Returns the post lexical processor to be used by this voice. Derived voices typically override this to customize behaviors.
      Overrides:
      getPostLexicalAnalyzer in class CMUVoice
      Returns:
      the Unit selector
      Throws:
      IOException - if an IO error occurs while getting processor
    • getPitchmarkGenerator

      public UtteranceProcessor getPitchmarkGenerator() throws IOException
      Returns the pitch mark generator to be used by this voice. Derived voices typically override this to customize behaviors. This voice uses a DiphonePitchMark generator to generate pitchmarks.
      Specified by:
      getPitchmarkGenerator in interface de.dfki.lt.freetts.ConcatenativeVoice
      Overrides:
      getPitchmarkGenerator in class CMUVoice
      Returns:
      the pitchmark processor
      Throws:
      IOException - if an IO error occurs while getting processor
    • getUnitConcatenator

      public UtteranceProcessor getUnitConcatenator() throws IOException
      Returns the unit concatenator to be used by this voice. Derived voices typically override this to customize behaviors. This voice uses a relp.UnitConcatenator to concatenate units.
      Specified by:
      getUnitConcatenator in interface de.dfki.lt.freetts.ConcatenativeVoice
      Overrides:
      getUnitConcatenator in class CMUVoice
      Returns:
      the unit concatenator processor
      Throws:
      IOException - if an IO error occurs while getting processor
    • getUnitSelector

      public UtteranceProcessor getUnitSelector() throws IOException
      Returns the unit selector to be used by this voice. Derived voices typically override this to customize behaviors. This voice uses the DiphoneUnitSelector to select units. The unit selector requires the name of a diphone database. If no diphone database has been specified then an Error is thrown.
      Specified by:
      getUnitSelector in interface de.dfki.lt.freetts.ConcatenativeVoice
      Overrides:
      getUnitSelector in class CMUVoice
      Returns:
      the unit selector processor
      Throws:
      IOException - if an IO error occurs while getting processor
    • toString

      public String toString()
      Converts this object to a string
      Overrides:
      toString in class CMUVoice
      Returns:
      a string representation of this object