??uh??
do you mean the i've done the fix for pocketquake2
for no good?
IT STANDS in the sorcecode that it doesnt work and it didn't when i tried so. i begun to look up the error and i found it
snd_mem.c
void ResampleSfx (sfx_t *sfx, int inrate, int inwidth, byte *data)
{
int outcount;
int srcsample;
float stepscale;
int i;
int sample, samplefrac, fracstep;
sfxcache_t *sc;
sc = sfx->cache;
if (!sc)
return;
stepscale = (float)inrate / dma.speed; // this is usually 0.5, 1, or 2
outcount = sc->length / stepscale;
sc->length = outcount;
if (sc->loopstart != -1)
sc->loopstart = sc->loopstart / stepscale;
sc->speed = dma.speed;
if (s_loadas8bit->value)//Chriva404: note:the "load s_loadas8bit" is still working but-
//i told Pq2 to use stereo sound instead.
//sc->width = 1; //the sound doesn't work if this one is enabled
//else
sc->width = inwidth;
sc->stereo = 1; //was 0
//set it to 0 and it sounds like smurf
// resample / decimate to the current source rate
if (stepscale == 1 && inwidth == 1 && sc->width == 1)
{
// fast special case
for (i=0 ; i<outcount ; i++)
((signed char *)sc->data)[i]
= (int)( (unsigned char)(data[i]) - 128);
}
else
{
// general case
samplefrac = 0;
fracstep = stepscale*256;
for (i=0 ; i<outcount ; i++)
{
srcsample = samplefrac >> 8;
samplefrac += fracstep;
if (inwidth == 2)
sample = LittleShort ( ((short *)data)[srcsample] );
else
sample = (int)( (unsigned char)(data[srcsample]) - 128) << 8;
if (sc->width == 2)
((short *)sc->data)[i] = sample;
else
((signed char *)sc->data)[i] = sample >> 8;
}
}
}