diff options
author | frahaase <fra.haase@googlemail.com> | 2016-08-12 18:23:18 +0200 |
---|---|---|
committer | George Joseph <gjoseph@digium.com> | 2017-02-23 10:34:58 -0700 |
commit | 094c26aa689664177e156d17bf5e9ab67c442a53 (patch) | |
tree | 29a03da022373e1b90804dbc30c9a927848a9217 /include | |
parent | 9ad1df71b363d1b3c92622873bb193dca5ddbb8c (diff) |
Binaural synthesis (confbridge): Adds binaural synthesis to bridge_softmix.
Adds binaural synthesis to bridge_softmix (via convolution using libfftw3).
Binaural synthesis is conducted at 48kHz.
For a conference, only one spatial representation is rendered.
The default rendering is applied for mono-capable channels.
ASTERISK-26292
Change-Id: Iecdb381b6adc17c961049658678f6219adae1ddf
Diffstat (limited to 'include')
-rw-r--r-- | include/asterisk/autoconfig.h.in | 7 | ||||
-rw-r--r-- | include/asterisk/bridge.h | 10 | ||||
-rw-r--r-- | include/asterisk/bridge_channel.h | 11 |
3 files changed, 25 insertions, 3 deletions
diff --git a/include/asterisk/autoconfig.h.in b/include/asterisk/autoconfig.h.in index eecd957fa..b9b4e1f81 100644 --- a/include/asterisk/autoconfig.h.in +++ b/include/asterisk/autoconfig.h.in @@ -124,6 +124,10 @@ /* Define to 1 if you have the Bluetooth library. */ #undef HAVE_BLUETOOTH +/* Define to 1 if you have the file `bridges/bridge_softmix/include/hrirs.h'. + */ +#undef HAVE_BRIDGES_BRIDGE_SOFTMIX_INCLUDE_HRIRS_H + /* Define to 1 if byteswap.h macros are available. */ #undef HAVE_BYTESWAP_H @@ -236,9 +240,6 @@ /* Define to 1 if you have the `ffsll' function. */ #undef HAVE_FFSLL -/* Define 1 if your system has fftw. */ -#undef HAVE_FFTW - /* Define to 1 if you have the LIBFFTW3 library. */ #undef HAVE_FFTW3 diff --git a/include/asterisk/bridge.h b/include/asterisk/bridge.h index 61cecbdd6..ffe08da13 100644 --- a/include/asterisk/bridge.h +++ b/include/asterisk/bridge.h @@ -263,6 +263,8 @@ struct ast_bridge_softmix { * for itself. */ unsigned int internal_mixing_interval; + /*! TRUE if binaural convolve is activated in configuration. */ + unsigned int binaural_active; }; /*! @@ -868,6 +870,14 @@ void ast_bridge_set_internal_sample_rate(struct ast_bridge *bridge, unsigned int void ast_bridge_set_mixing_interval(struct ast_bridge *bridge, unsigned int mixing_interval); /*! + * \brief Activates the use of binaural signals in a conference bridge. + * + * \param bridge Channel to activate the binaural signals. + * \param binaural_active If true binaural signal processing will be active for the bridge. + */ +void ast_bridge_set_binaural_active(struct ast_bridge *bridge, unsigned int binaural_active); + +/*! * \brief Set a bridge to feed a single video source to all participants. */ void ast_bridge_set_single_src_video_mode(struct ast_bridge *bridge, struct ast_channel *video_src_chan); diff --git a/include/asterisk/bridge_channel.h b/include/asterisk/bridge_channel.h index 797be4ebc..a7971df27 100644 --- a/include/asterisk/bridge_channel.h +++ b/include/asterisk/bridge_channel.h @@ -172,6 +172,17 @@ struct ast_bridge_channel { /*! Collected DTMF digits for DTMF hooks. */ char collected[MAXIMUM_DTMF_FEATURE_STRING]; } dtmf_hook_state; + union { + uint32_t raw; + struct { + /*! TRUE if binaural is suspended. */ + unsigned int binaural_suspended:1; + /*! TRUE if a change of binaural positions has to be performed. */ + unsigned int binaural_pos_change:1; + /*! Padding */ + unsigned int padding:30; + }; + }; }; /*! |