[vlc-commits] Waveout: Fix SPDIF output
Andy Tather
git at videolan.org
Thu Dec 5 18:33:54 CET 2013
vlc | branch: master | Andy Tather <andy at andytather.co.uk> | Thu Dec 5 18:32:38 2013 +0100| [4fcfd8479f462ca964bdb061b55b0d4cdfb055b0] | committer: Jean-Baptiste Kempf
Waveout: Fix SPDIF output
Ref #9522
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=4fcfd8479f462ca964bdb061b55b0d4cdfb055b0
---
modules/audio_output/waveout.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/modules/audio_output/waveout.c b/modules/audio_output/waveout.c
index 478b7bb..3ce8158 100644
--- a/modules/audio_output/waveout.c
+++ b/modules/audio_output/waveout.c
@@ -175,12 +175,6 @@ static int Start( audio_output_t *p_aout, audio_sample_format_t *restrict fmt )
/* Default behaviour is to use software gain */
p_aout->sys->b_soft = true;
- /*
- check for configured audio device!
- */
- fmt->i_format = var_InheritBool( p_aout, "waveout-float32" )?
- VLC_CODEC_FL32: VLC_CODEC_S16N;
-
char *dev = var_GetNonEmptyString( p_aout, "waveout-audio-device");
uint32_t devid = findDeviceID( dev );
@@ -230,6 +224,12 @@ static int Start( audio_output_t *p_aout, audio_sample_format_t *restrict fmt )
if( fmt->i_format != VLC_CODEC_SPDIFL )
{
+ /*
+ check for configured audio device!
+ */
+ fmt->i_format = var_InheritBool( p_aout, "waveout-float32" )?
+ VLC_CODEC_FL32: VLC_CODEC_S16N;
+
int max_chan = var_InheritInteger( p_aout, "waveout-audio-channels");
int i_channels = aout_FormatNbChannels(fmt);
i_channels = ( i_channels < max_chan )? i_channels: max_chan;
More information about the vlc-commits
mailing list