Commit 9394b1be authored by Gildas Bazin's avatar Gildas Bazin

* modules/audio_output/waveout.c,directx.c: fixed audio channel ordering.

parent 5344ba81
......@@ -673,10 +673,10 @@ static int CreateDSBuffer( aout_instance_t *p_aout, int i_format,
/* First set the sound buffer format */
waveformat.dwChannelMask = 0;
for( i = 0; i < sizeof(pi_channels_in)/sizeof(uint32_t); i++ )
for( i = 0; i < sizeof(pi_channels_src)/sizeof(uint32_t); i++ )
{
if( i_channels & pi_channels_in[i] )
waveformat.dwChannelMask |= pi_channels_out[i];
if( i_channels & pi_channels_src[i] )
waveformat.dwChannelMask |= pi_channels_in[i];
}
switch( i_format )
......
......@@ -494,10 +494,10 @@ static int OpenWaveOut( aout_instance_t *p_aout, int i_format,
#define waveformat p_aout->output.p_sys->waveformat
waveformat.dwChannelMask = 0;
for( i = 0; i < sizeof(pi_channels_in)/sizeof(uint32_t); i++ )
for( i = 0; i < sizeof(pi_channels_src)/sizeof(uint32_t); i++ )
{
if( i_channels & pi_channels_in[i] )
waveformat.dwChannelMask |= pi_channels_out[i];
if( i_channels & pi_channels_src[i] )
waveformat.dwChannelMask |= pi_channels_in[i];
}
switch( i_format )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment