summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSND\weimingzhi_cp <SND\weimingzhi_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2010-05-21 05:14:52 +0000
committerSND\weimingzhi_cp <SND\weimingzhi_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2010-05-21 05:14:52 +0000
commit2030af5d172802ddc2c74dfe4962a220237ebd20 (patch)
treeb83b71c1391fd9c746a1eb0fad050b3d4f505ff8
parentf0684f680a9d2611b3854b72c356c6f3354b65c9 (diff)
downloadpcsxr-2030af5d172802ddc2c74dfe4962a220237ebd20.tar.gz
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@48429 e17a0e51-4ae3-4d35-97c3-1a29b211df97
-rw-r--r--ChangeLog1
-rw-r--r--libpcsxcore/psxbios.c6
-rw-r--r--plugins/dfsound/sdl.c8
3 files changed, 8 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index aee9fdbd..6bc7af20 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -11,6 +11,7 @@ May 21, 2010 Wei Mingzhi <whistler_wmz@users.sf.net>
Updated.
* libpcsxcore/psxbios.c: Implemented several HLE BIOS functions inside the
core instead of calling the standard C functions. (Not done yet)
+ * plugins/dfsound/sdl.c: Changed buffer size.
May 20, 2010 Wei Mingzhi <whistler_wmz@users.sf.net>
diff --git a/libpcsxcore/psxbios.c b/libpcsxcore/psxbios.c
index 722a7232..9ddec9a8 100644
--- a/libpcsxcore/psxbios.c
+++ b/libpcsxcore/psxbios.c
@@ -366,7 +366,7 @@ void psxBios_strcat() { // 0x15
while (*p1++);
--p1;
- while (*p1++ = *p2++);
+ while ((*p1++ = *p2++) != '\0');
v0 = a0; pc0 = ra;
}
@@ -381,7 +381,7 @@ void psxBios_strncat() { // 0x16
while (*p1++);
--p1;
- while (*p1++ = *p2++) {
+ while ((*p1++ = *p2++) != '\0') {
if (--n < 0) {
*--p1 = '\0';
break;
@@ -432,7 +432,7 @@ void psxBios_strncmp() { // 0x18
void psxBios_strcpy() { // 0x19
char *p1 = (char *)Ra0, *p2 = (char *)Ra1;
- while (*p1++ = *p2++);
+ while ((*p1++ = *p2++) != '\0');
v0 = a0; pc0 = ra;
}
diff --git a/plugins/dfsound/sdl.c b/plugins/dfsound/sdl.c
index 31cf5e1d..45ccba2d 100644
--- a/plugins/dfsound/sdl.c
+++ b/plugins/dfsound/sdl.c
@@ -21,11 +21,11 @@
#include "externals.h"
#include <SDL.h>
-#define BUFFER_SIZE 11025
+#define BUFFER_SIZE 22050
short *pSndBuffer = NULL;
-int iBufSize = 0;
-volatile int iReadPos = 0, iWritePos = 0;
+int iBufSize = 0;
+volatile int iReadPos = 0, iWritePos = 0;
static void SOUND_FillAudio(void *unused, Uint8 *stream, int len) {
short *p = (short *)stream;
@@ -71,7 +71,7 @@ void SetupSound(void) {
spec.freq = 44100;
spec.format = AUDIO_S16SYS;
spec.channels = iDisStereo ? 1 : 2;
- spec.samples = 1024;
+ spec.samples = 512;
spec.callback = SOUND_FillAudio;
if (SDL_OpenAudio(&spec, NULL) < 0) {