]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-9474 #resolve [Add variables to set initial volume on mod_conference]
authorAnthony Minessale <anthm@freeswitch.org>
Thu, 1 Sep 2016 18:30:55 +0000 (13:30 -0500)
committerAnthony Minessale <anthm@freeswitch.org>
Thu, 1 Sep 2016 18:30:55 +0000 (13:30 -0500)
src/mod/applications/mod_conference/conference_member.c

index 21e29dbc2aa51e115e891ed1c96e994fe9db2c9d..423b4076253db56bd93c81483f623e1feb85bc25 100644 (file)
@@ -742,6 +742,22 @@ switch_status_t conference_member_add(conference_obj_t *conference, conference_m
 
                conference_video_check_avatar(member, SWITCH_FALSE);
 
+               if ((var = switch_channel_get_variable_dup(member->channel, "conference_join_volume_in", SWITCH_FALSE, -1))) {
+                       uint32_t id = atoi(var) - 1;
+
+                       if (id > -5 && id < 5) {
+                               member->volume_in_level = id;
+                       }
+               }
+
+               if ((var = switch_channel_get_variable_dup(member->channel, "conference_join_volume_out", SWITCH_FALSE, -1))) {
+                       uint32_t id = atoi(var) - 1;
+
+                       if (id > -5 && id < 5) {
+                               member->volume_out_level = id;
+                       }
+               }
+               
                if ((var = switch_channel_get_variable_dup(member->channel, "video_initial_canvas", SWITCH_FALSE, -1))) {
                        uint32_t id = atoi(var) - 1;
                        if (id < conference->canvas_count) {