1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
//! # FFI Bindings for VOICEVOX CORE.
//!
//! This is an unofficial Rust FFI wrapper for VOICEVOX CORE.
//!
//! # APIs
//!
//! It provides a high-level API for calling VOICEVOX CORE.
//!
//! - [VoicevoxCore]
//!
//!
//! It also provides a low-level API for directly calling the ffi provided by VOICEVOX CORE.
//!
//! - [api](api/index.html#functions)
//!
//! # Example
//!
//! ```
//! use std::io::Write;
//! use vvcore::*;
//!
//! let dir = std::ffi::CString::new("./voicevox_core/open_jtalk_dic_utf_8-1.11").unwrap();
//! let vvc = VoicevoxCore::new_from_options(AccelerationMode::Auto, 0, true, dir.as_c_str()).unwrap();
//!
//! let text: &str = "こんにちは";
//! let speaker: u32 = 1;
//! let wav = vvc.tts_simple(text, speaker).unwrap();
//!
//! let mut file = std::fs::File::create("audio.wav").unwrap();
//! file.write_all(&wav.as_slice()).unwrap();
//! ```
pub use ;