Skip to content

Commit

Permalink
is_gpu_modeに名称変更
Browse files Browse the repository at this point in the history
  • Loading branch information
qwerty2501 committed Aug 25, 2022
1 parent 7e50250 commit f6e4d9b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions crates/voicevox_core/src/publish.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ impl VoicevoxCore {
Ok(())
}

pub fn is_use_gpu(&self) -> bool {
pub fn is_gpu_mode(&self) -> bool {
self.use_gpu
}

Expand Down Expand Up @@ -656,7 +656,7 @@ mod tests {
#[rstest]
fn is_use_gpu_works() {
let internal = VoicevoxCore::new_with_mutex();
assert_eq!(false, internal.lock().unwrap().is_use_gpu());
assert_eq!(false, internal.lock().unwrap().is_gpu_mode());
internal
.lock()
.unwrap()
Expand All @@ -665,7 +665,7 @@ mod tests {
..Default::default()
})
.unwrap();
assert_eq!(false, internal.lock().unwrap().is_use_gpu());
assert_eq!(false, internal.lock().unwrap().is_gpu_mode());
}

#[rstest]
Expand Down
4 changes: 2 additions & 2 deletions crates/voicevox_core_c_api/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ pub extern "C" fn voicevox_load_model(speaker_id: usize) -> VoicevoxResultCode {
}

#[no_mangle]
pub extern "C" fn voicevox_is_use_gpu() -> bool {
lock_internal().is_use_gpu()
pub extern "C" fn voicevox_is_gpu_mode() -> bool {
lock_internal().is_gpu_mode()
}

#[no_mangle]
Expand Down

0 comments on commit f6e4d9b

Please sign in to comment.