]> git.immae.eu Git - perso/Immae/Projets/Python/MusicSampler.git/commitdiff
Remove unused functions heads/remove_pygame
authorIsmaël Bouya <ismael.bouya@normalesup.org>
Sun, 17 Jul 2016 14:02:27 +0000 (16:02 +0200)
committerIsmaël Bouya <ismael.bouya@normalesup.org>
Sun, 17 Jul 2016 14:02:27 +0000 (16:02 +0200)
helpers/music_file.py

index efa8628b83c4b078abd6d87b00f30edace769310..5baab7ef36d0bf09b92e888f013554506602b59e 100644 (file)
@@ -212,13 +212,3 @@ class MusicFile(Machine):
         self.wait_event.clear()
         self.wait_event.wait()
 
-# Add some more functions to AudioSegments
-def get_sample_slice_data(self, start_sample=0, end_sample=float('inf')):
-    max_val = int(self.frame_count())
-
-    start_i = max(start_sample, 0) * self.frame_width
-    end_i =   min(end_sample, max_val) * self.frame_width
-
-    return self._data[start_i:end_i]
-
-pydub.AudioSegment.get_sample_slice_data = get_sample_slice_data