提交 b78a6003 authored 作者: Anthony Minessale's avatar Anthony Minessale 提交者: Brian West

FS-7903 #resolve [proxy_media gives Codec PROXY Exists but not at the desired…

FS-7903 #resolve [proxy_media gives Codec PROXY Exists but not at the desired implementation. 0hz 0ms 1ch]
上级 03656d5c
...@@ -666,6 +666,17 @@ SWITCH_DECLARE(switch_status_t) switch_core_codec_init_with_bitrate(switch_codec ...@@ -666,6 +666,17 @@ SWITCH_DECLARE(switch_status_t) switch_core_codec_init_with_bitrate(switch_codec
return SWITCH_STATUS_GENERR; return SWITCH_STATUS_GENERR;
} }
if (!strncasecmp(codec_name, "PROXY", 5)) {
for (iptr = codec_interface->implementations; iptr; iptr = iptr->next) {
if ((!channels || channels == iptr->number_of_channels)) {
implementation = iptr;
break;
}
}
goto found;
}
/* If no specific codec interval is requested opt for 20ms above all else because lots of stuff assumes it */ /* If no specific codec interval is requested opt for 20ms above all else because lots of stuff assumes it */
if (!ms) { if (!ms) {
for (iptr = codec_interface->implementations; iptr; iptr = iptr->next) { for (iptr = codec_interface->implementations; iptr; iptr = iptr->next) {
......
...@@ -782,7 +782,6 @@ SWITCH_DECLARE(payload_map_t *) switch_core_media_add_payload_map(switch_core_se ...@@ -782,7 +782,6 @@ SWITCH_DECLARE(payload_map_t *) switch_core_media_add_payload_map(switch_core_se
pmap->allocated = 1; pmap->allocated = 1;
pmap->recv_pt = (switch_payload_t) pt; pmap->recv_pt = (switch_payload_t) pt;
...@@ -8410,7 +8409,7 @@ SWITCH_DECLARE(void) switch_core_media_patch_sdp(switch_core_session_t *session) ...@@ -8410,7 +8409,7 @@ SWITCH_DECLARE(void) switch_core_media_patch_sdp(switch_core_session_t *session)
SDP_TYPE_RESPONSE, SDP_TYPE_RESPONSE,
0, 0,
8000, 8000,
8000, 20,
1, 1,
SWITCH_TRUE); SWITCH_TRUE);
...@@ -9834,7 +9833,7 @@ SWITCH_DECLARE(void) switch_core_media_check_outgoing_proxy(switch_core_session_ ...@@ -9834,7 +9833,7 @@ SWITCH_DECLARE(void) switch_core_media_check_outgoing_proxy(switch_core_session_
SDP_TYPE_RESPONSE, SDP_TYPE_RESPONSE,
0, 0,
8000, 8000,
8000, 20,
1, 1,
SWITCH_TRUE); SWITCH_TRUE);
......
...@@ -402,7 +402,7 @@ SWITCH_MODULE_LOAD_FUNCTION(core_pcm_load) ...@@ -402,7 +402,7 @@ SWITCH_MODULE_LOAD_FUNCTION(core_pcm_load)
switch_proxy_decode, /* function to decode encoded data into raw data */ switch_proxy_decode, /* function to decode encoded data into raw data */
switch_proxy_destroy); /* deinitalize a codec handle using this implementation */ switch_proxy_destroy); /* deinitalize a codec handle using this implementation */
SWITCH_ADD_CODEC(codec_interface, "PROXY PASS-THROUGH");
switch_core_codec_add_implementation(pool, codec_interface, SWITCH_CODEC_TYPE_AUDIO, /* enumeration defining the type of the codec */ switch_core_codec_add_implementation(pool, codec_interface, SWITCH_CODEC_TYPE_AUDIO, /* enumeration defining the type of the codec */
0, /* the IANA code number */ 0, /* the IANA code number */
"PROXY", /* the IANA code name */ "PROXY", /* the IANA code name */
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论