add aivmx test

This commit is contained in:
tuna2134
2024-11-20 02:36:42 +00:00
parent 2eda2fe9ca
commit 5e9df65656

View File

@@ -15,7 +15,14 @@ fn main_inner() -> anyhow::Result<()> {
.ok()
.and_then(|x| x.parse().ok()),
)?;
tts_holder.load_sbv2file(ident, fs::read(env::var("MODEL_PATH")?)?)?;
#[cfg(not(feature = "aivmx"))]
{
tts_holder.load_sbv2file(ident, fs::read(env::var("MODEL_PATH")?)?)?;
}
#[cfg(feature = "aivmx")]
{
tts_holder.load_aivmxfile(ident, fs::read(env::path("AIVMX_PATH")?)?)?;
}
let audio =
tts_holder.easy_synthesize(ident, &text, 0, 0, tts::SynthesizeOptions::default())?;