mirror of
https://github.com/ndarilek/tts-rs.git
synced 2024-11-17 12:39:36 +00:00
Add example for unscientifically measuring latency of TTS.
This commit is contained in:
parent
669c94af36
commit
728c409e25
14
examples/latency.rs
Normal file
14
examples/latency.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
use std::io;
|
||||
|
||||
use tts::*;
|
||||
|
||||
fn main() -> Result<(), Error> {
|
||||
env_logger::init();
|
||||
let mut tts = TTS::default()?;
|
||||
println!("Press Enter and wait for speech.");
|
||||
loop {
|
||||
let mut _input = String::new();
|
||||
io::stdin().read_line(&mut _input)?;
|
||||
tts.speak("Hello, world.", true)?;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user