[vlc-commits] [Git][videolan/vlc][master] aout: replace assert by a if check

Rémi Denis-Courmont (@Courmisch) gitlab at videolan.org
Tue Oct 4 18:18:53 UTC 2022



Rémi Denis-Courmont pushed to branch master at VideoLAN / VLC


Commits:
702b258d by Thomas Guillem at 2022-10-04T17:17:39+00:00
aout: replace assert by a if check

Modules should be able to report headphones while playing mono or
surround.

The Binaural mode must be done only when Stereo + headphones.

- - - - -


1 changed file:

- src/audio_output/output.c


Changes:

=====================================
src/audio_output/output.c
=====================================
@@ -788,9 +788,9 @@ int aout_OutputNew(audio_output_t *aout, vlc_aout_stream *stream,
      * request any mode */
     if (aout->current_sink_info.headphones
      && owner->requested_mix_mode == AOUT_VAR_CHAN_UNSET
+     && fmt->i_physical_channels == AOUT_CHANS_STEREO
      && aout_HasMixModeChoice(aout, AOUT_MIX_MODE_BINAURAL))
     {
-        assert(fmt->i_physical_channels == AOUT_CHANS_STEREO);
         assert(stereo_mode == AOUT_VAR_CHAN_UNSET);
         aout_UpdateMixMode(aout, AOUT_MIX_MODE_BINAURAL, fmt);
     }



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/702b258dfc7debcf71de3309acdc336505866eae

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/702b258dfc7debcf71de3309acdc336505866eae
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list