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

Re: [pygame] Pygame Mixer Crackle noise not an SDL_Mixer problem



hi,

I think the delay is there, because the directx sound driver is meant
for low latency sound, whereas the other driver is meant for basic
sound playback.



On Mon, Apr 21, 2008 at 4:59 PM, etrek <etrek@xxxxxxx> wrote:
>
>
> Forgot to mention, I also tried it with both env vars set and the delay is
> still there.
>
>
> ----- Original Message -----
> From: etrek
> To: pygame-users@xxxxxxxx
>
> Sent: Sunday, April 20, 2008 11:52 PM
> Subject: Re: [pygame] Pygame Mixer Crackle noise not an SDL_Mixer problem
>
>
> I removed SDL_AUDIODRIVER  and then  set SDL_VIDEODRIVER=directx, but the
> crackling and wierdness came back.
>
>
>
> ----- Original Message -----
> From: Brian Fisher
> To: pygame-users@xxxxxxxx
> Sent: Sunday, April 20, 2008 10:55 PM
> Subject: Re: [pygame] Pygame Mixer Crackle noise not an SDL_Mixer problem
>
> I wonder if it could also be related to a mismatch between audio driver and
> video driver?
> does SDL_VIDEODRIVER=directx also fix things?
>
>
> On Sun, Apr 20, 2008 at 8:23 PM, etrek <etrek@xxxxxxx> wrote:
>
> > Yeah, don't mess with your DirectX 8 setup.
> >
> > I tried setting the env var SDL_AUDIODRIVER=waveout  as you mentioned in
> > your previous email.  Yes it does clear up the audio in Pygame.  I'm still
> new to Pygame/SDL,
> > so correct me if I'm wrong:  Setting this variable to wavout causes Pygame
> Mixer
> > to use software audio instead of hardware?
> >
> > While the crackling noise is gone, there is a slight delay now in
> bouncesound.py (Chap 10)
> > when the ball hits the ground/wall and the bounce sound plays.
> >
> > Do you have Pygame 1.8 on your Win98 machine?
> >
> > Let me know if I can help or anything I can do.  Just keep in mind that
> I'm new
> > to Python/Pygame; I'm starting to play around with Boost.Python.
> >
> > -Ethan
> > Python ROCKS!
> >
> >
> >
> >
> >
> > ----- Original Message ----- From: "Lenard Lindstrom" <len-l@xxxxxxxxx>
> > To: <pygame-users@xxxxxxxx>
> > Sent: Sunday, April 20, 2008 6:34 PM
> >
> > Subject: Re: [pygame] Pygame Mixer Crackle noise not an SDL_Mixer problem
> >
> >
> >
> >
> >
> > I tried jukebox.py on my slow Windows 98 computer with DirectX 8 and it
> sounded
> > fine. I also altered waveIt to initialize SDL like Pygame would:
> >
> > SDL_Init(SDL_INIT_TIMER | SDL_INIT_NOPARACHUTE);
> > SDL_InitSubSystem(SDL_INIT_VIDEO);
> > SDL_InitSubSystem(SDL_INIT_AUDIO);
> >
> > This also sounds fine on the XP machine. I also reversed the order of
> > video/audio initialization. So that leaves these three factors: Windows
> > XP/Vista, Pygame 1.8 and DirectX 9. I am hesitant to install DirectX 9 on
> my
> > Windows 98 box in case it breaks everything and I am unable to revert back
> to
> > DirectX 8. So I am out or ideas for the moment.
> >
> > Lenard
> >
> >
> > Quoting Lenard Lindstrom <len-l@xxxxxxxxx>:
> >
> >
> > >
> > > Thanks. I tried the jukebox.py example. It sounded awful (getout.ogg).
> > >
> > > Python 2.5
> > > Pygame 1.8.1pre
> > > XP Professional (51., Build 2600)
> > > Dell DM051
> > > Phoenix ROM BIOS PLUS Version 1.10 A05
> > > Intel Pentium D CPU 2.80GHz (2 CPUs)
> > > 1014MB RAM
> > > DirectX 9.0c (4.09.0000.0904)
> > > Intel 82945G Express Chipset Family video (Internal) 224.0 MB
> > > SigmaTel Audio
> > >
> > > It crackled and played at half-speed. Changing the audio driver to
> waveout
> > > "set
> > > SDL_AUDIODRIVER=waveout" cleared everything up. Could it be a DirectX 9
> > > problem
> > > (not properly DirectX 5 compatible). I will try this on my Windows 98
> Dell
> > > with
> > > DirectX 8 for comparison.
> > >
> > > One thing I noted, Pygame initializes the video and audio separately
> while
> > > all
> > > the C/C++ programs I have seen so far do everthing in the call to
> SDL_Init. I
> > >
> > > will try instializing SDL subsystems instead to see what happens.
> > >
> > > Lenard
> > >
> > >
> > >
> > >
> > > Quoting etrek <etrek@xxxxxxx>:
> > >
> > > > Hi Lenard,
> > > > You can download the media/Pygame scripts for the Book from:
> > > > http://apress.com/book/downloadfile/3765
> > > >
> > > > Chapter 10 has the audio example scripts; a bouncing balls script, and
> a
> > > > jukebox.py script that plays .ogg files.
> > > > The jukebox.py script is very simple, it comes with "please put some >
> .ogg
> > > > file in the music folder", you can add the getout.ogg file to the
> media
> > > > folder for the jukebox.
> > >
> >
> >
> >
>
>