summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Geier <Matthias.Geier@gmail.com>2016-03-12 12:00:03 +0100
committerMatthias Geier <Matthias.Geier@gmail.com>2016-03-12 12:00:03 +0100
commit68e26a08527af179a249f77152387c37a129ac9b (patch)
tree7330a6f2dfeabb57dca722c3e20204dc09d2a5a2
parentb5e50e073ba70128c89e68018a42cd4920552375 (diff)
Fix playrec() to allow 'data' to be arbitrary sequence type
-rw-r--r--sounddevice.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/sounddevice.py b/sounddevice.py
index 52f578e..46c0ef2 100644
--- a/sounddevice.py
+++ b/sounddevice.py
@@ -422,7 +422,7 @@ def playrec(data, samplerate=None, channels=None, dtype=None,
ctx = _CallbackContext()
output_frames = ctx.check_data(data, output_mapping)
if dtype is None:
- dtype = data.dtype # ignore module defaults
+ dtype = ctx.data.dtype # ignore module defaults
input_frames = ctx.check_out(out, output_frames, channels, dtype,
input_mapping)
if input_frames != output_frames: