wave.Wave_read.readframes()
wave.Wave_read.readframes() is a Python method in the Wave Module category. Reads and returns up to n frames of audio data as bytes. The syntax is Wave_read.readframes(n). Returns: Bytes. A typical example: frames = wav.readframes(1024) # Read 1024 frames. A close sibling is wave.open(), which opens a WAV audio file for reading or writing. A close sibling is wave.Wave_write.setparams(), which sets audio parameters: (nchannels, sampwidth, framerate, nframes, comptype, compname). A close sibling is wave.Wave_write.writeframes(), which writes audio frames to the file. More about this category: WAV audio file handling — open, readframes, writeframes, getparams. Related Wave Module entries: wave.open(), wave.Wave_write.setparams(), wave.Wave_write.writeframes(). This page is part of the free Python Reference documentation covering 978+ functions, methods, and modules with examples and parameter details. You can try wave.Wave_read.readframes() immediately in the Python playground, look up unfamiliar terms in the glossary, or return to the Python Reference homepage.