mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Remove currently unused audio assets
This clears out about 56MB of unused audio files. There were also some unused methods in the audio modules which referenced a file, which has also been removed.
This commit is contained in:
parent
0c97ad8913
commit
bafa6718a4
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -209,12 +209,6 @@ impl AudioFrontend {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn select_random_music() -> String {
|
||||
let soundtracks = load_soundtracks();
|
||||
let index = rand::random::<usize>() % soundtracks.len();
|
||||
soundtracks[index].clone()
|
||||
}
|
||||
|
||||
/// Returns the default audio device.
|
||||
/// Does not return rodio Device struct in case our audio backend changes.
|
||||
pub fn get_default_device() -> String {
|
||||
@ -224,21 +218,6 @@ pub fn get_default_device() -> String {
|
||||
.expect("Unable to get device name")
|
||||
}
|
||||
|
||||
/// Load the audio file directory selected by genre.
|
||||
pub fn load_soundtracks() -> Vec<String> {
|
||||
let assets = assets::read_dir("voxygen.audio.soundtrack.regional").unwrap();
|
||||
let soundtracks = assets
|
||||
.filter_map(|entry| {
|
||||
entry.ok().map(|f| {
|
||||
let path = f.path();
|
||||
path.to_string_lossy().into_owned()
|
||||
})
|
||||
})
|
||||
.collect::<Vec<String>>();
|
||||
|
||||
soundtracks
|
||||
}
|
||||
|
||||
/// Returns a vec of the audio devices available.
|
||||
/// Does not return rodio Device struct in case our audio backend changes.
|
||||
pub fn list_devices() -> Vec<String> {
|
||||
|
Loading…
x
Reference in New Issue
Block a user