[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [pygame] Pygame Mixer Crackle noise not an SDL_Mixer problem
- To: pygame-users@xxxxxxxx
- Subject: Re: [pygame] Pygame Mixer Crackle noise not an SDL_Mixer problem
- From: "René Dudfield" <renesd@xxxxxxxxx>
- Date: Thu, 24 Apr 2008 12:44:03 +1000
- Delivered-to: archiver@xxxxxxxx
- Delivered-to: pygame-users-outgoing@xxxxxxxx
- Delivered-to: pygame-users@xxxxxxxx
- Delivery-date: Wed, 23 Apr 2008 22:44:08 -0400
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=l1TZPAFryI9/sajg58H4AtrCoxTPr19fzwLrAIZL7cs=; b=ukUNNxhrJXKE4C/BbQSYuiBldoWpEtO04eOktLfSOym0yzsiP+f/q2qx40M92f1qO4YbI67xyafPFg+xxk7anW6xM1mOXf7SEWBHAAcDzvfqZljIq6ZJzsHwoV5XCWt2ST2Av2oUtZvwe9oK30ugDuoTNIWJH+pQrqTq5AYthOM=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=N74BBz5HhjGtRx1cu7A3cyVzybZr67QiHsmCayUhdvSbJURlndhWhQFmTgf4boF43ocqbA3A9vk5gTBEJoAYuIKz51taCYxnScTVnaJzp4vv6i25Q7yapKtoegNeD7yEASEQDM7VJXqHlGtUVOTl5ZVNFQVaXYkw4xu19bBu8cY=
- In-reply-to: <1209003862.480fef56ae53e@xxxxxxxxxxxxxxxxx>
- References: <1209003862.480fef56ae53e@xxxxxxxxxxxxxxxxx>
- Reply-to: pygame-users@xxxxxxxx
- Sender: owner-pygame-users@xxxxxxxx
ah,
feel free to change that back... I mistakenly added the extra
brackets, thinking I was cleaning it up - when I was adding the bug
fix for reverse stereo in 8bit. I should have just left that part
alone.
...
But strangely we were having the crackling sound problem way before I
made that change (about one month ago).
On Thu, Apr 24, 2008 at 12:24 PM, Lenard Lindstrom <len-l@xxxxxxxxx> wrote:
> Beat Nicholas. It is revision 1143 (need 1146 to compile) that breaks things.
> It deals with an SDL_mixer bug where the stereo channels are reversed for 8 bit
> sound. I wonder if this is our culprit:
>
> ==== From around line 160 in mixer.c ===============
> /*make chunk a power of 2*/
> for (i = 0; 1 << i < chunk; ++i); //yes, semicolon on for loop
> chunk = MAX (1 << i, 256);
> ==== To around line 167 ============================
> /*make chunk a power of 2*/
> for (i = 0; 1 << i < chunk; ++i) {
> chunk = MAX (1 << i, 256);
> }
>
> Lenard
>
>
>
>
> Quoting René Dudfield <renesd@xxxxxxxxx>:
>
> > This would be a good script to add to pygame for the google testing
> > project by Nicholas...
> >
> > test_between_revisions.py r990 r1175 run_tests.py
> >
> > Then it could to a bisect build, and test between the revisions. It
> > could take a file name to run between revisions. So you could pass it
> > a file to run tests for you.
> >
> > eg. for this bug it could be:
> > test_between_revisions.py r990 r1175 tests/manual/music.py
> >
> > It would download, and build them all, then run the tests.
> >
> >
> > cu,
> >
> >
> > On Thu, Apr 24, 2008 at 11:13 AM, Brian Fisher
> > <brian@xxxxxxxxxxxxxxxxxxx> wrote:
> > > sweet, you rock. with 185 revisions between, then it only takes 8 more
> > > get-build-test cycles to narrow it down to a single change :)
> > >
> > >
> > >
> > > On Wed, Apr 23, 2008 at 4:22 PM, Lenard Lindstrom <len-l@xxxxxxxxx> wrote:
> > >
> > > > I have been going through SVN. I have narrowed the problem to between
> > > revisions 990 (1.0.0 rc 0) and 1175 (1.8.0release). SDL may be involved
> > only
> > > indirectly. Simple C programs using it don't have the problem. It could be
> > > Pygame doing something it shouldn't. Of course Pygame could be exposing an
> > > SDL problem that has remained dormant until now.
> > > >
> > > > Lenard
> > > >
> > > >
> > > > Brian Fisher wrote:
> > > >
> > > > >
> > > > > Your test demonstrates that 1.8 changes are required to cause the
> > > problem, but clearly SDL is involved, otherwise why would waveout solve
> > the
> > > problem as well? If possible, a test of pygame 1.8 against the 1.7 SDL
> > > versions could still help solve the case.
> > > > >
> > > > > maybe in order to figure out what pygame 1.8 change made the crackling
> > > start happen, you could binary search against svn revisions? i.e. if
> > pygame
> > > 1.8 was rev. 1200 and 1.7 was rev 600 (made up numbers) then try rev. 900?
> > > > >
> > > > >
> > > > > On Wed, Apr 23, 2008 at 8:42 AM, Lenard Lindstrom <len-l@xxxxxxxxx
> > > <mailto:len-l@xxxxxxxxx>> wrote:
> > > > >
> > > > > I have narrowed the problem some. It has something to do with
> > > > > Pygame 1.8, not
> > > > > SDL. I built Pygame 1.7 and linked against the 1.8 prebuilts. The
> > > > > crackling
> > > > > went away. I don't know if anyone else thought to move the 1.8
> > > > > dependencies to
> > > > > 1.7. And it definitely involves the SDL DirectX audio driver.
> > > > > Changes to that
> > > > > driver improved sound quality for 1.8, though it did not
> > > > > completely eliminate
> > > > > the noise. I fear it is another memory access problem. Let's hope
> > > > > it was
> > > > > introduced with Pygame 1.8. That should be easier to track down.
> > > > >
>
>
>