Author gpolo
Recipients alex_python_org, gpolo
Date 2009-01-12.15:34:29
SpamBayes Score 0.059784
Marked as misclassified No
Message-id <>
Aren't 8 bit samples stored as unsigned bytes ? If yes, they don't range
between -128 and 127 (first disagreement). So this line: wav = [ s - 128
for s in wav ] and the respective one (that adds +128 in writesamples)
should go.

Why is this check: "if len(wavs) not in [ 1, 2, 4 ]" needed ?

Calling setnchannels inside writesamples looks very wrong to me, weren't
you going to writesamples ? Then why is it modified the number of
channels ? The caller should be responsible for calling setnchannels,
besides, what is the use of calling setnchannels here ?

I see writesamples is expecting "wavs" to be a list of lists containing
integers, is that the best format to expect ? writeframes works with
strings (which are actually byte strings).

The code layout didn't help me to get in agreement with it either.

The above paragraphs are the things I disagree with the patch, hopefully
you can help on those questions. Also, it would be better to hand write
the wave file for testing so we can be sure about its content without
needing much analysis.
Date User Action Args
2009-01-12 15:34:32gpolosetrecipients: + gpolo, alex_python_org
2009-01-12 15:34:31gpolosetmessageid: <>
2009-01-12 15:34:31gpololinkissue4913 messages
2009-01-12 15:34:30gpolocreate