mirror of
https://github.com/FWGS/xash3d-fwgs
synced 2024-11-24 10:50:58 +01:00
engine: sound: allow cubic sound interpolation
This commit is contained in:
parent
54920f13df
commit
d347096396
@ -792,8 +792,6 @@ void S_MixBufferUpsample2x( int count, portable_samplepair_t *pbuffer, portable_
|
||||
pbuffer[i-1] = pbuffer[j];
|
||||
}
|
||||
|
||||
if( !s_lerping->value ) return;
|
||||
|
||||
// pass forward through buffer, interpolate all even slots
|
||||
switch( filtertype )
|
||||
{
|
||||
@ -993,7 +991,7 @@ void MIX_UpsampleAllPaintbuffers( int end, int count )
|
||||
// upsample all 11khz buffers by 2x
|
||||
// only upsample roombuffer if dsp fx are on KDB: perf
|
||||
MIX_SetCurrentPaintbuffer( IROOMBUFFER ); // operates on MixUpSample
|
||||
S_MixUpsample( count / (SOUND_DMA_SPEED / SOUND_11k), FILTERTYPE_LINEAR );
|
||||
S_MixUpsample( count / ( SOUND_DMA_SPEED / SOUND_11k ), s_lerping->value );
|
||||
|
||||
// mix 22khz sounds:
|
||||
MIX_MixChannelsToPaintbuffer( end, SOUND_22k, SOUND_22k );
|
||||
@ -1001,7 +999,7 @@ void MIX_UpsampleAllPaintbuffers( int end, int count )
|
||||
// upsample all 22khz buffers by 2x
|
||||
// only upsample roombuffer if dsp fx are on KDB: perf
|
||||
MIX_SetCurrentPaintbuffer( IROOMBUFFER );
|
||||
S_MixUpsample( count / ( SOUND_DMA_SPEED / SOUND_22k ), FILTERTYPE_LINEAR );
|
||||
S_MixUpsample( count / ( SOUND_DMA_SPEED / SOUND_22k ), s_lerping->value );
|
||||
|
||||
// mix all 44khz sounds to all active paintbuffers
|
||||
MIX_MixChannelsToPaintbuffer( end, SOUND_44k, SOUND_DMA_SPEED );
|
||||
|
Loading…
Reference in New Issue
Block a user