[MPlayer-cvslog] CVS: main/libmpcodecs dec_audio.c,1.36,1.37

Zoltan Hidvegi CVS syncmail at mplayerhq.hu
Fri Feb 25 11:39:19 CET 2005


CVS change done by Zoltan Hidvegi CVS

Update of /cvsroot/mplayer/main/libmpcodecs
In directory mail:/var2/tmp/cvs-serv27919/libmpcodecs

Modified Files:
	dec_audio.c 
Log Message:
If -af-adv force=4 is in effect, use ADCTRL_QUERY_FORMAT to query the
ad codec about float support and set floatne format if supported.

Index: dec_audio.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/dec_audio.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -r1.36 -r1.37
--- dec_audio.c	25 Feb 2005 10:21:14 -0000	1.36
+++ dec_audio.c	25 Feb 2005 10:39:16 -0000	1.37
@@ -49,6 +49,14 @@
 
 int init_audio_codec(sh_audio_t *sh_audio)
 {
+  if ((af_cfg.force & AF_INIT_FORMAT_MASK) == AF_INIT_FLOAT) {
+      int fmt = AF_FORMAT_FLOAT_NE;
+      if (mpadec->control(sh_audio, ADCTRL_QUERY_FORMAT,
+				       &fmt) == CONTROL_TRUE) {
+	  sh_audio->sample_format = fmt;
+	  sh_audio->samplesize = 4;
+      }
+  }
   if(!mpadec->preinit(sh_audio))
   {
       mp_msg(MSGT_DECAUDIO,MSGL_ERR,MSGTR_ADecoderPreinitFailed);




More information about the MPlayer-cvslog mailing list