[MPlayer-cvslog] CVS: main mplayer.c,1.818,1.819
Reimar Döffinger CVS
syncmail at mplayerhq.hu
Fri Dec 17 17:23:53 CET 2004
CVS change done by Reimar Döffinger CVS
Update of /cvsroot/mplayer/main
In directory mail:/var2/tmp/cvs-serv2248
Modified Files:
mplayer.c
Log Message:
Set mixer.afilter at a more appropriate place.
Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.818
retrieving revision 1.819
diff -u -r1.818 -r1.819
--- mplayer.c 10 Dec 2004 23:04:54 -0000 1.818
+++ mplayer.c 17 Dec 2004 16:23:50 -0000 1.819
@@ -924,8 +924,12 @@
static int build_afilter_chain(sh_audio_t *sh_audio, ao_data_t *ao_data)
{
int new_srate;
+ int result;
if (!sh_audio)
+ {
+ mixer.afilter = NULL;
return 0;
+ }
new_srate = sh_audio->samplerate * playback_speed;
if (new_srate != ao_data->samplerate) {
// limits are taken from libaf/af_resample.c
@@ -935,11 +939,13 @@
new_srate = 192000;
playback_speed = (float)new_srate / (float)sh_audio->samplerate;
}
- return init_audio_filters(sh_audio, new_srate,
+ result = init_audio_filters(sh_audio, new_srate,
sh_audio->channels, sh_audio->sample_format, sh_audio->samplesize,
ao_data->samplerate, ao_data->channels, ao_data->format,
audio_out_format_bits(ao_data->format) / 8, /* ao_data.bps, */
ao_data->outburst * 4, ao_data->buffersize);
+ mixer.afilter = sh_audio->afilter;
+ return result;
}
int main(int argc,char* argv[]){
@@ -2128,7 +2134,6 @@
#endif
}
mixer.audio_out = audio_out;
- mixer.afilter = sh_audio ? sh_audio->afilter : NULL;
mixer.volstep = volstep;
}
More information about the MPlayer-cvslog
mailing list