Fix sound-issue. You will have to restart ZSNES each

time you modify the sound settings within the sound menu for them to work
properly, though.

PR:		ports/67644
Submitted by:	Travis Poppe
Approved by:	maintainer timeout
This commit is contained in:
Volker Stolz 2004-07-24 22:42:44 +00:00
parent de9584ba62
commit 4d89db6ec3
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=114600
2 changed files with 24 additions and 1 deletions

View File

@ -7,7 +7,7 @@
PORTNAME= zsnes
PORTVERSION= 1.36
PORTREVISION= 2
PORTREVISION= 3
PORTEPOCH= 1
CATEGORIES= emulators
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
@ -36,4 +36,7 @@ WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}/src
GNU_CONFIGURE= yes
ALL_TARGET= ALL
post-install:
@${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>

View File

@ -0,0 +1,20 @@
--- linux/sdllink.c.orig Mon May 31 01:15:18 2004
+++ linux/sdllink.c Mon May 31 01:16:17 2004
@@ -493,7 +493,7 @@
int InitSound(void)
{
SDL_AudioSpec wanted;
- const int samptab[7] = { 1, 1, 2, 4, 2, 4, 4 };
+ const int samptab[7] = { 64, 64, 128, 256, 128, 256, 256 };
const int freqtab[7] = { 8000, 11025, 22050, 44100, 16000, 32000, 48000 };
SDL_CloseAudio();
@@ -519,7 +519,7 @@
wanted.channels = 1;
}
- wanted.samples = samptab[SoundQuality] * 128 * wanted.channels;
+ wanted.samples = samptab[SoundQuality] * 8 * wanted.channels;
wanted.format = AUDIO_S16LSB;
wanted.userdata = NULL;
wanted.callback = UpdateSound;