Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 16364 - Distorted sound when running snes9x.
Summary: Distorted sound when running snes9x.
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: PPC Linux
: High major
Assignee: Bartosch Pixa (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-02-25 14:32 UTC by Ernst Sjöstrand
Modified: 2006-02-04 06:03 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
BE sound fixes (snes9x-139-r1-BE-fix.diff,545 bytes, patch)
2003-03-01 21:42 UTC, Bartosch Pixa (RETIRED)
Details | Diff
A ppc-patch for snes9x (patch.diff,550 bytes, patch)
2003-03-02 02:53 UTC, Ernst Sjöstrand
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ernst Sjöstrand 2003-02-25 14:32:34 UTC
If I build snes9x on my iMac 266 (old problem, so it's been like this with many kernel 
versions) I get distorted sound in all supernintendo games. 
With the debian version on the other hand, sound works perfectly! 
 
Avaliable at 
ftp://ftp.sunet.se/pub/os/Linux/distributions/debian/pool/non-free/s/snes9x/ 
install with 
dpkg-deb -x snes9x-x_1.39-8.0.1_powerpc.deb / 
dpkg-deb -x snes9x-opengl_1.39-8.0.1_powerpc.deb / 
dpkg-deb -x snes9x-common_1.39-8_all.deb / 

Reproducible: Always
Steps to Reproduce:
1. emerge snes9x 
2a. Turn down your speaker volume! 
2b. snes9x FinalFantasy3.smc 
3. Listen to the horrible sound 
Actual Results:
Comment 1 Bartosch Pixa (RETIRED) gentoo-dev 2003-03-01 14:38:50 UTC
i can't reproduce this, snes9x works fine for me, can you give me some more info ?
"emerge info" for example 
Comment 2 Bartosch Pixa (RETIRED) gentoo-dev 2003-03-01 16:56:58 UTC
drop -mpowerpc-gfxopt -fsigned-char from your compilerflags, both can cause
packages to break and are removed from the gentoo's make.conf for some time now

also you might want to try -O2 instead -O3 
Comment 3 Ernst Sjöstrand 2003-03-01 18:39:41 UTC
Everything on my system is compiled with -mpowerpc-gfxopt -fsigned-char, I have 
no problems in other programs, and it wasn't removed from the 1.4-rc4  stage 
tarballs. 
 
Just to make sure, I compiled snes9x with no optimisations at all, but I get exactly 
the same results. 
 
It's an old bug, I think it was exactly like this when I ran yellowdog with gcc-2.9x too 
and with all versions of Mandrake. 
 
My computer is an iMac 266 and I'm guessing that it's somehow specific to my 
soundcard (since it works on your computer!), but on the other hand, the debian 
packages works.. 
Comment 4 Justin Blanchard 2003-03-01 21:18:47 UTC
It's had endian confusion for me.
My experiene is that with all games the sound was more than distorted- it was completely scrambled, worse than static. (I'm using an old b&w g3/300 with gcc 3.2 and ALSA, and my CFLAGS include -O2 -mpowerpc-gfxopt -fsigned-char.) I just edited unix/unix.cpp and changed all occurrences of AFMT_S16_LE to AFMT_S16_NE and continued the merge. Most of the time it now works perfectly, but occasionally the sound scrambles itself again. When that happens, it usually goes away if I wait a few seconds or tell it to use its freeze/defrost features.
Has anyone else experienced that?
Comment 5 Bartosch Pixa (RETIRED) gentoo-dev 2003-03-01 21:42:32 UTC
Created attachment 8864 [details, diff]
BE sound fixes

patch to fix sound
Comment 6 Bartosch Pixa (RETIRED) gentoo-dev 2003-03-01 21:44:11 UTC
plz test if this patch fixes the issues
Comment 7 Ernst Sjöstrand 2003-03-02 02:53:42 UTC
Created attachment 8870 [details, diff]
A ppc-patch for snes9x

Nope, your patch is wrong (you can't remove an if statement just like that!)
but after some modification it works great! Played for an hour now, perfect
sound all the time.

Attached version 2.0
Comment 8 Bartosch Pixa (RETIRED) gentoo-dev 2003-03-03 10:46:04 UTC
yes you are right, sorry seems i attatched a buggy patch.
a fixed ebuild should be in the rsync mirrirs soon