FS-8127 #resolve [update codec when detecting rate change in mod_conference more often]
This commit is contained in:
parent
02cc5bcd14
commit
fab435479a
|
@ -4267,7 +4267,7 @@ static void *SWITCH_THREAD_FUNC conference_loop_input(switch_thread_t *thread, v
|
||||||
switch_frame_t *read_frame = NULL;
|
switch_frame_t *read_frame = NULL;
|
||||||
uint32_t hangover = 40, hangunder = 5, hangover_hits = 0, hangunder_hits = 0, diff_level = 400;
|
uint32_t hangover = 40, hangunder = 5, hangover_hits = 0, hangunder_hits = 0, diff_level = 400;
|
||||||
switch_core_session_t *session = member->session;
|
switch_core_session_t *session = member->session;
|
||||||
uint32_t flush_len, loops = 0;
|
uint32_t flush_len;
|
||||||
switch_frame_t tmp_frame = { 0 };
|
switch_frame_t tmp_frame = { 0 };
|
||||||
|
|
||||||
if (switch_core_session_read_lock(session) != SWITCH_STATUS_SUCCESS) {
|
if (switch_core_session_read_lock(session) != SWITCH_STATUS_SUCCESS) {
|
||||||
|
@ -4531,20 +4531,16 @@ static void *SWITCH_THREAD_FUNC conference_loop_input(switch_thread_t *thread, v
|
||||||
member->last_score = member->score;
|
member->last_score = member->score;
|
||||||
}
|
}
|
||||||
|
|
||||||
loops++;
|
|
||||||
|
|
||||||
if (switch_channel_test_flag(member->channel, CF_CONFERENCE_RESET_MEDIA)) {
|
if (switch_channel_test_flag(member->channel, CF_CONFERENCE_RESET_MEDIA)) {
|
||||||
switch_channel_clear_flag(member->channel, CF_CONFERENCE_RESET_MEDIA);
|
switch_channel_clear_flag(member->channel, CF_CONFERENCE_RESET_MEDIA);
|
||||||
|
|
||||||
if (loops > 500) {
|
|
||||||
member->loop_loop = 1;
|
member->loop_loop = 1;
|
||||||
|
|
||||||
if (setup_media(member, member->conference)) {
|
if (setup_media(member, member->conference)) {
|
||||||
switch_mutex_unlock(member->read_mutex);
|
switch_mutex_unlock(member->read_mutex);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
goto do_continue;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* skip frames that are not actual media or when we are muted or silent */
|
/* skip frames that are not actual media or when we are muted or silent */
|
||||||
|
@ -4877,6 +4873,11 @@ static void conference_loop_output(conference_member_t *member)
|
||||||
switch_buffer_t *use_buffer = NULL;
|
switch_buffer_t *use_buffer = NULL;
|
||||||
uint32_t mux_used = 0;
|
uint32_t mux_used = 0;
|
||||||
|
|
||||||
|
if (switch_channel_test_flag(member->channel, CF_CONFERENCE_RESET_MEDIA)) {
|
||||||
|
switch_cond_next();
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
switch_mutex_lock(member->write_mutex);
|
switch_mutex_lock(member->write_mutex);
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue