mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-17 01:02:12 +00:00
FS-10529: [mod_native_file] mod_native_file: remove "opus" extension -- fix regression
This commit is contained in:
parent
e7269d7389
commit
d1f7899087
@ -181,13 +181,14 @@ SWITCH_MODULE_LOAD_FUNCTION(mod_native_file_load)
|
|||||||
|
|
||||||
const switch_codec_implementation_t *codecs[SWITCH_MAX_CODECS];
|
const switch_codec_implementation_t *codecs[SWITCH_MAX_CODECS];
|
||||||
uint32_t num_codecs = switch_loadable_module_get_codecs(codecs, sizeof(codecs) / sizeof(codecs[0]));
|
uint32_t num_codecs = switch_loadable_module_get_codecs(codecs, sizeof(codecs) / sizeof(codecs[0]));
|
||||||
uint32_t x;
|
uint32_t x, y = 0;
|
||||||
|
|
||||||
for (x = 0; x < num_codecs; x++) {
|
for (x = 0; x < num_codecs; x++) {
|
||||||
if (codecs[x]->encoded_bytes_per_packet == 0) {
|
if (codecs[x]->encoded_bytes_per_packet == 0 || codecs[x]->codec_type != SWITCH_CODEC_TYPE_AUDIO) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
supported_formats[x] = switch_core_strdup(pool, codecs[x]->iananame);
|
|
||||||
|
supported_formats[y++] = switch_core_strdup(pool, codecs[x]->iananame);
|
||||||
}
|
}
|
||||||
|
|
||||||
*module_interface = switch_loadable_module_create_module_interface(pool, modname);
|
*module_interface = switch_loadable_module_create_module_interface(pool, modname);
|
||||||
|
@ -394,7 +394,7 @@ SWITCH_MODULE_LOAD_FUNCTION(core_pcm_load)
|
|||||||
20000, /* number of microseconds per frame */
|
20000, /* number of microseconds per frame */
|
||||||
160, /* number of samples per frame */
|
160, /* number of samples per frame */
|
||||||
320, /* number of bytes per frame decompressed */
|
320, /* number of bytes per frame decompressed */
|
||||||
320, /* number of bytes per frame compressed */
|
0, /* number of bytes per frame compressed */
|
||||||
1, /* number of channels represented */
|
1, /* number of channels represented */
|
||||||
1, /* number of frames per network packet */
|
1, /* number of frames per network packet */
|
||||||
switch_proxy_init, /* function to initialize a codec handle using this implementation */
|
switch_proxy_init, /* function to initialize a codec handle using this implementation */
|
||||||
@ -413,7 +413,7 @@ SWITCH_MODULE_LOAD_FUNCTION(core_pcm_load)
|
|||||||
20000, /* number of microseconds per frame */
|
20000, /* number of microseconds per frame */
|
||||||
160, /* number of samples per frame */
|
160, /* number of samples per frame */
|
||||||
320 * 2, /* number of bytes per frame decompressed */
|
320 * 2, /* number of bytes per frame decompressed */
|
||||||
320 * 2, /* number of bytes per frame compressed */
|
0, /* number of bytes per frame compressed */
|
||||||
2, /* number of channels represented */
|
2, /* number of channels represented */
|
||||||
1, /* number of frames per network packet */
|
1, /* number of frames per network packet */
|
||||||
switch_proxy_init, /* function to initialize a codec handle using this implementation */
|
switch_proxy_init, /* function to initialize a codec handle using this implementation */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user