diff options
author | Mark Michelson <mmichelson@digium.com> | 2017-05-24 10:09:22 -0500 |
---|---|---|
committer | Mark Michelson <mmichelson@digium.com> | 2017-05-30 10:24:20 -0500 |
commit | 39d14834f83e8727e841c51d1752d90bc7be5c63 (patch) | |
tree | baf5bbd256aa89a34a2a6e0b0f38b6d0f7201ced /main/bridge.c | |
parent | 2da869408ae5556022526bcd0f526d92fdbb5a5f (diff) |
Confbridge: Add "sfu" video mode to bridge profile options.
A previous commit added plumbing to bridge_softmix to allow for an SFU
experience with Asterisk. This commit adds an option to app_confbridge
that allows for a confbridge to actually make use of the SFU video mode.
SFU mode is implemented in a "set it and forget it" kind of way. That
is, when the bridge is created, if SFU mode is enabled, then the video
mode gets set to SFU and cannot be changed. Future improvements may
allow for a hybrid experience (e.g. forward multiple video streams,
specifically those of the most recent talkers), but for this addition,
no such capability is present.
Change-Id: I87bbcb63dec6dbbb42488f894871b86f112b2020
Diffstat (limited to 'main/bridge.c')
-rw-r--r-- | main/bridge.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/main/bridge.c b/main/bridge.c index 7d6bdfaa0..4631e5a52 100644 --- a/main/bridge.c +++ b/main/bridge.c @@ -3807,6 +3807,14 @@ void ast_bridge_set_talker_src_video_mode(struct ast_bridge *bridge) ast_bridge_unlock(bridge); } +void ast_bridge_set_sfu_video_mode(struct ast_bridge *bridge) +{ + ast_bridge_lock(bridge); + cleanup_video_mode(bridge); + bridge->softmix.video_mode.mode = AST_BRIDGE_VIDEO_MODE_SFU; + ast_bridge_unlock(bridge); +} + void ast_bridge_update_talker_src_video_mode(struct ast_bridge *bridge, struct ast_channel *chan, int talker_energy, int is_keyframe) { struct ast_bridge_video_talker_src_data *data; |