[vlc-devel] [PATCH 07/12] aout: add aout_SetDefaultPhysicalChannels

Rémi Denis-Courmont remi at remlab.net
Fri Jul 7 17:06:18 CEST 2017


Le 7 juillet 2017 16:39:54 GMT+03:00, Thomas Guillem <thomas at gllm.fr> a écrit :
>Set the default wg4 channel layout from a numbers of channels.
>---
> include/vlc_aout.h | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
>diff --git a/include/vlc_aout.h b/include/vlc_aout.h
>index bbe7b4cbbe..458ed606f8 100644
>--- a/include/vlc_aout.h
>+++ b/include/vlc_aout.h
>@@ -257,6 +257,15 @@ VLC_API char *aout_DeviceGet (audio_output_t *);
> VLC_API int aout_DeviceSet (audio_output_t *, const char *);
> VLC_API int aout_DevicesList (audio_output_t *, char ***, char ***);
> 
>+static inline void
>aout_SetDefaultPhysicalChannels(audio_sample_format_t *fmt)
>+{
>+    fmt->i_physical_channels = 0;
>+    for (int i = 0; i < fmt->i_channels && i < AOUT_CHAN_MAX; ++i)
>+        fmt->i_physical_channels |= pi_vlc_chan_order_wg4[i];
>+    fmt->i_original_channels = fmt->i_physical_channels;
>+    aout_FormatPrepare(fmt);
>+}
>+
> /**
>  * Report change of configured audio volume to the core and UI.
>  */
>-- 
>2.11.0
>
>_______________________________________________
>vlc-devel mailing list
>To unsubscribe or modify your subscription options:
>https://mailman.videolan.org/listinfo/vlc-devel

That does not seem like a sane set of defaults, which makes me suspect this is useless.
-- 
Rémi Denis-Courmont
Typed on an inconvenient virtual keyboard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20170707/afdd6c72/attachment.html>


More information about the vlc-devel mailing list