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

[pygame] pygame.mixer on windoes



I'm trying to play a wav through pygame. It works on Linux, but on
Windows I get no sound. The same file plays correctly though WinAmp
and MS Media player on the Windows machine. I followed the suggestion
at http://www.pygame.org/docs/ref/mixer.html and tried specifying a
larger buffer in pygame.mixer.pre_init, but that had no effect. I
haven't used Windows in a few years. Is there something obvious I
should be checking for?

The wav is 8kpbs, unsigned 8-bit, mono stream created with the Python
wave module. Both Linux and Windows show the same output in
interactive shell, but on Windows there is no sound:

>>> import pygame
>>> from pygame.locals import *
>>> pygame.init()
open /dev/sequencer: No such file or directory
(6, 0)
>>> s=pygame.mixer.Sound("/home/ari/aa.wav")
>>> s.play
<built-in method play of pygame.mixer.Sound object at 0xb7d770f0>
>>> s.play()
<Channel object at 0xb7d770e0>
>>> 

-- 
Elections only count as free and trials as fair if you can lose money
betting on the outcome.