Function bliss_audio::distance::song_to_song[][src]

pub fn song_to_song(
    first_song: &Song,
    songs: &mut Vec<Song>,
    distance: impl DistanceMetric
)
Expand description

Sort songs in place using the distance metric and ordering by the smallest distance between each song. Deduplicate identical songs.

If the generated playlist is [song1, song2, song3, song4], it means song2 is closest to song1, song3 is closest to song2, and song4 is closest to song3.