mirror of https://github.com/mpv-player/mpv
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. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@14816 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
abe18b2f02
commit
e3cfcb169f
|
@ -49,6 +49,14 @@ void afm_help(){
|
|||
|
||||
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);
|
||||
|
|
Loading…
Reference in New Issue