aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2016-07-17 16:02:27 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2016-07-17 16:02:27 +0200
commit176642649ad18f056675f7d89ea84482084234bc (patch)
tree8adaf478d308d8e2e226aa316dfb71898d1452e1
parentd6290f14246b69e10a73e2798dd3905e866b3e88 (diff)
downloadMusicSampler-176642649ad18f056675f7d89ea84482084234bc.tar.gz
MusicSampler-176642649ad18f056675f7d89ea84482084234bc.tar.zst
MusicSampler-176642649ad18f056675f7d89ea84482084234bc.zip
Remove unused functions
-rw-r--r--helpers/music_file.py10
1 files changed, 0 insertions, 10 deletions
diff --git a/helpers/music_file.py b/helpers/music_file.py
index efa8628..5baab7e 100644
--- a/helpers/music_file.py
+++ b/helpers/music_file.py
@@ -212,13 +212,3 @@ class MusicFile(Machine):
212 self.wait_event.clear() 212 self.wait_event.clear()
213 self.wait_event.wait() 213 self.wait_event.wait()
214 214
215# Add some more functions to AudioSegments
216def get_sample_slice_data(self, start_sample=0, end_sample=float('inf')):
217 max_val = int(self.frame_count())
218
219 start_i = max(start_sample, 0) * self.frame_width
220 end_i = min(end_sample, max_val) * self.frame_width
221
222 return self._data[start_i:end_i]
223
224pydub.AudioSegment.get_sample_slice_data = get_sample_slice_data