Movatterモバイル変換


[0]ホーム

URL:


Up one LevelPython Library ReferenceContentsModule IndexIndex


19.4.2 AU_write Objects

AU_write objects, as returned byopen() above, have thefollowing methods:

setnchannels(n)
Set the number of channels.

setsampwidth(n)
Set the sample width (in bytes.)

setframerate(n)
Set the frame rate.

setnframes(n)
Set the number of frames. This can be later changed, when and if more frames are written.

setcomptype(type, name)
Set the compression type and description.Only'NONE' and'ULAW' are supported on output.

setparams(tuple)
Thetuple should be(nchannels,sampwidth,framerate,nframes,comptype,compname), withvalues valid for theset*() methods. Set all parameters.

tell()
Return current position in the file, with the same disclaimer fortheAU_read.tell() andAU_read.setpos() methods.

writeframesraw(data)
Write audio frames, without correctingnframes.

writeframes(data)
Write audio frames and make surenframes is correct.

close()
Make surenframes is correct, and close the file.

This method is called upon deletion.

Note that it is invalid to set any parameters after callingwriteframes() orwriteframesraw().


Up one LevelPython Library ReferenceContentsModule IndexIndex

Release 2.5.2, documentation updated on 21st February, 2008.
SeeAbout this document... for information on suggesting changes.
[8]ページ先頭

©2009-2025 Movatter.jp