[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Screeching, Howling Garbage in One Ear pygame.sndarray



Cheers, that works a treat, Mr. Shinners.
That samples[:,0] bit...  I don't think I've ever seen notation like that.  I would guess the [: indicates a slice, but then you've a comma and THEN the integer.  I'm sorry, but I don't even know what that means :S

On 5/5/06, Peter Shinners <pete@xxxxxxxxxxxx > wrote:
On Fri, 2006-05-05 at 20:33 -0700, andrew baker wrote:
> Hey, thanks for the fast response.
>
> Pete, I can't even get yours to run at the moment:

>     samples[:] = mono[:, Numeric.NewAxis]
> ValueError: matrices are not aligned for copy


I'm running Numeric 24.2. I know there is a syntax for this that works
in other Numeric versions, but I had to poke a bit to get this line
working. I'm actually surprised this is different between Numeric
versions.

If worse comes to worse, you can always bump it up into two lines.
    samples[:,0] = mono
    samples[:,1] = mono







--
Andrew Ulysses Baker
"failrate"