Partager via


classe HybridSpeechConfig

Classe qui définit des configurations hybrides (cloud et incorporées) pour la reconnaissance vocale ou la synthèse vocale.

Membres

opérateur SPXSPEECHCONFIGHANDLE

Syntaxe : public inline explicit operator SPXSPEECHCONFIGHANDLE ( ) const;

Opérateur interne utilisé pour obtenir la valeur de handle sous-jacente.

Retours

Handle.

SetSpeechRecognitionOutputFormat

Syntaxe : public inline void SetSpeechRecognitionOutputFormat ( OutputFormat format );

Définit le format de sortie de la reconnaissance vocale.

Paramètres

  • format Format de sortie de la reconnaissance vocale (simple ou détaillé).

GetSpeechRecognitionOutputFormat

Syntaxe : public inline OutputFormat GetSpeechRecognitionOutputFormat ( ) const;

Obtient le format de sortie de la reconnaissance vocale.

Retours

Format de sortie de la reconnaissance vocale (simple ou détaillé).

SetSpeechSynthesisOutputFormat

Syntaxe : public inline void SetSpeechSynthesisOutputFormat ( SpeechSynthesisOutputFormat formatId );

Définit le format de sortie de synthèse vocale (par exemple, Riff16Khz16BitMonoPcm).

Paramètres

  • formatId Spécifie l’ID de format de sortie

GetSpeechSynthesisOutputFormat

Syntaxe : public inline std::string GetSpeechSynthesisOutputFormat ( ) const;

Obtient le format de sortie de synthèse vocale.

Retours

Format de sortie de synthèse vocale.

SetProperty

Syntaxe : public inline void SetProperty ( const std::string & name , const std::string & value );

Définit une valeur de propriété par nom.

Paramètres

  • name Nom de la propriété.

  • value Valeur de propriété.

SetProperty

Syntaxe : public inline void SetProperty ( PropertyId id , const std::string & value );

Définit une valeur de propriété par ID.

Paramètres

  • id ID de propriété.

  • value Valeur de propriété.

Getproperty

Syntaxe : public inline std::string GetProperty ( const std::string & name ) const;

Obtient une valeur de propriété par nom.

Paramètres

  • name Nom du paramètre.

Retours

Valeur de la propriété.

Getproperty

Syntaxe : public inline std::string GetProperty ( PropertyId id ) const;

Obtient une valeur de propriété par ID.

Paramètres

  • id ID de paramètre.

Retours

Valeur de la propriété.

~HybridSpeechConfig

Syntaxe : public virtual ~HybridSpeechConfig ( ) = default;

Détruit l’objet .

FromConfigs

Syntaxe : public inline static std::shared_ptr< HybridSpeechConfig > FromConfigs ( std::shared_ptr< SpeechConfig > cloudSpeechConfig , std::shared_ptr< EmbeddedSpeechConfig > embeddedSpeechConfig );

Crée une instance de la configuration vocale hybride avec des configurations cloud et de reconnaissance vocale incorporées spécifiées.

Paramètres

  • cloudSpeechConfig Pointeur intelligent partagé d’une configuration de reconnaissance vocale cloud.

  • embeddedSpeechConfig Pointeur intelligent partagé d’une configuration vocale incorporée.

Retours

Pointeur partagé vers la nouvelle instance de configuration de reconnaissance vocale hybride.