Browse Source

MT#55283 switch to cc_client_float2opus_new_ext

Change-Id: Ie2f6a19b2b1bed9068b1e1e2b747013f0451593b
rfuchs/dataport
Richard Fuchs 2 years ago
parent
commit
f4def66d3d
2 changed files with 20 additions and 8 deletions
  1. +1
    -1
      debian/control
  2. +19
    -7
      lib/codeclib.c

+ 1
- 1
debian/control View File

@ -49,7 +49,7 @@ Build-Depends:
libwebsockets-dev,
libxmlrpc-core-c3-dev (>= 1.16.07),
libxtables-dev (>= 1.4) | iptables-dev (>= 1.4),
ngcp-libcodec-chain-dev (>= 12.4) <pkg.ngcp-rtpengine.codec-chain>,
ngcp-libcodec-chain-dev (>= 12.5) <pkg.ngcp-rtpengine.codec-chain>,
pandoc,
pkgconf,
python3,


+ 19
- 7
lib/codeclib.c View File

@ -180,7 +180,7 @@ static __typeof__(codec_chain_pcmu2opus_runner_async_do_nonblock) *cc_pcmu2opus_
static __typeof__(codec_chain_opus2pcma_runner_async_do_nonblock) *cc_opus2pcma_runner_async_do_nonblock;
static __typeof__(codec_chain_opus2pcmu_runner_async_do_nonblock) *cc_opus2pcmu_runner_async_do_nonblock;
static __typeof__(codec_chain_client_float2opus_new) *cc_client_float2opus_new;
static __typeof__(codec_chain_client_float2opus_new_ext) *cc_client_float2opus_new_ext;
static __typeof__(codec_chain_client_opus2float_new) *cc_client_opus2float_new;
static __typeof__(codec_chain_client_float2opus_free) *cc_client_float2opus_free;
@ -1434,8 +1434,8 @@ static void cc_dlsym_resolve(const char *fn) {
cc_opus2pcmu_runner_async_do_nonblock = dlsym_assert(cc_lib_handle,
"codec_chain_opus2pcmu_runner_async_do_nonblock", fn);
cc_client_float2opus_new = dlsym_assert(cc_lib_handle,
"codec_chain_client_float2opus_new", fn);
cc_client_float2opus_new_ext = dlsym_assert(cc_lib_handle,
"codec_chain_client_float2opus_new_ext", fn);
cc_client_opus2float_new = dlsym_assert(cc_lib_handle,
"codec_chain_client_opus2float_new", fn);
@ -5238,7 +5238,10 @@ static codec_cc_t *codec_cc_new_sync(codec_def_t *src, format_t *src_format, cod
return NULL;
codec_cc_t *ret = g_slice_alloc0(sizeof(*ret));
ret->pcma2opus.enc = cc_client_float2opus_new(cc_client, bitrate);
ret->pcma2opus.enc = cc_client_float2opus_new_ext(cc_client,
(codec_chain_opus_arguments) {
.bitrate = bitrate,
});
ret->clear = cc_float2opus_clear;
ret->clear_arg = ret->pcma2opus.enc;
ret->pcma2opus.runner = pcma2opus_runner;
@ -5261,7 +5264,10 @@ static codec_cc_t *codec_cc_new_sync(codec_def_t *src, format_t *src_format, cod
return NULL;
codec_cc_t *ret = g_slice_alloc0(sizeof(*ret));
ret->pcmu2opus.enc = cc_client_float2opus_new(cc_client, bitrate);
ret->pcmu2opus.enc = cc_client_float2opus_new_ext(cc_client,
(codec_chain_opus_arguments) {
.bitrate = bitrate,
});
ret->clear = cc_float2opus_clear;
ret->clear_arg = ret->pcmu2opus.enc;
ret->pcmu2opus.runner = pcmu2opus_runner;
@ -5340,7 +5346,10 @@ static codec_cc_t *codec_cc_new_async(codec_def_t *src, format_t *src_format, co
return NULL;
codec_cc_t *ret = g_slice_alloc0(sizeof(*ret));
ret->pcma2opus.enc = cc_client_float2opus_new(cc_client, bitrate);
ret->pcma2opus.enc = cc_client_float2opus_new_ext(cc_client,
(codec_chain_opus_arguments) {
.bitrate = bitrate,
});
ret->clear = cc_float2opus_clear;
ret->clear_arg = ret->pcma2opus.enc;
ret->pcma2opus_async.runner = pcma2opus_async_runner;
@ -5369,7 +5378,10 @@ static codec_cc_t *codec_cc_new_async(codec_def_t *src, format_t *src_format, co
return NULL;
codec_cc_t *ret = g_slice_alloc0(sizeof(*ret));
ret->pcmu2opus.enc = cc_client_float2opus_new(cc_client, bitrate);
ret->pcmu2opus.enc = cc_client_float2opus_new_ext(cc_client,
(codec_chain_opus_arguments) {
.bitrate = bitrate,
});
ret->clear = cc_float2opus_clear;
ret->clear_arg = ret->pcmu2opus.enc;
ret->pcmu2opus_async.runner = pcmu2opus_async_runner;


Loading…
Cancel
Save