Skip to content

Commit f16b948

Browse files
committed
play_long_file example: Change ctype -> dtype
This was changed in bastibe/python-soundfile#179 and removed in bastibe/python-soundfile#200.
1 parent 92adb69 commit f16b948

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

examples/play_long_file.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ def callback(outdata, frames, time, status):
7070

7171
with sf.SoundFile(args.filename) as f:
7272
for _ in range(args.buffersize):
73-
data = f.buffer_read(args.blocksize, ctype='float')
73+
data = f.buffer_read(args.blocksize, dtype='float32')
7474
if not data:
7575
break
7676
q.put_nowait(data) # Pre-fill queue
@@ -82,7 +82,7 @@ def callback(outdata, frames, time, status):
8282
with stream:
8383
timeout = args.blocksize * args.buffersize / f.samplerate
8484
while data:
85-
data = f.buffer_read(args.blocksize, ctype='float')
85+
data = f.buffer_read(args.blocksize, dtype='float32')
8686
q.put(data, timeout=timeout)
8787
event.wait() # Wait until playback is finished
8888
except KeyboardInterrupt:

0 commit comments

Comments
 (0)