winegstreamer: Translate GST_AUDIO_CHANNEL_POSITION_MONO to SPEAKER_FRONT_CENTER.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2021-10-07 10:47:06 -05:00 committed by Alexandre Julliard
parent fd60414fce
commit 009c1d66fa
1 changed files with 4 additions and 1 deletions

View File

@ -159,7 +159,10 @@ static uint32_t wg_channel_position_from_gst(GstAudioChannelPosition position)
SPEAKER_TOP_BACK_CENTER,
};
if (position < ARRAY_SIZE(position_map))
if (position == GST_AUDIO_CHANNEL_POSITION_MONO)
return SPEAKER_FRONT_CENTER;
if (position >= 0 && position < ARRAY_SIZE(position_map))
return position_map[position];
return 0;
}