search for: opus_encoder_ctl

Displaying 20 results from an estimated 39 matches for "opus_encoder_ctl".

2018 Jan 15
1
Ask for suggestions about optimizing opus on STM32F407
...cribe the details of my encode/decode test on STM32F407ZG. A. opus version: latest 1.2.1 (TI: opus 1.1.2) B. KEIL 5.23 (TI: ARM compiler tool chain 5.2.7) C. setup the encoder as the below (fs is the sampling frequency) enc = opus_encoder_create(fs, chans, OPUS_APPLICATION_AUDIO, &opus_err); opus_encoder_ctl(enc, OPUS_SET_BITRATE(fs * 2)); opus_encoder_ctl(enc, OPUS_SET_BANDWIDTH(OPUS_AUTO)); opus_encoder_ctl(enc, OPUS_SET_VBR(1)); opus_encoder_ctl(enc, OPUS_SET_VBR_CONSTRAINT(0)); opus_encoder_ctl(enc, OPUS_SET_COMPLEXITY(0)); opus_encoder_ctl(enc, OPUS_SET_INBAND_FEC(0)); opus_encoder_ctl(enc,...
2020 Jun 11
1
OPUS encoded data size and bandwidth of encoder
Hey, I am having trouble with the size of the encoded bytes by Opus. I am also having issue with the Bandwidth ctl. Here is the scenario. If I encode 16khz sampled audio: opus_encoder_ctl(enc,OPUS_SET_MAX_BANDWIDTH(OPUS_BANDWIDTH_WIDEBAND)) opus_encoder_ctl(enc, OPUS_GET_BANDWIDTH(&x)) = 1102 opus_encoder_ctl(enc, OPUS_GET_MAX_BANDWIDTH(&x)) = 1103 average encoded size = 120 bytes if I encode 48khz sampled audio: opus_encoder_ctl(enc, OPUS_SET_BANDWIDTH(OPUS_BANDWIDTH_W...
2018 Feb 23
3
[EXTERNAL] Re: Developing OPUS on TI CC3220
...lloc(OpusHeap,size,NULL,NULL); // // sOpusEnc = opus_encoder_create(16000, // 1, // OPUS_APPLICATION_VOIP, &i32error); i32error = opus_encoder_init(sOpusEnc, 16000, 1, OPUS_APPLICATION_RESTRICTED_LOWDELAY); opus_encoder_ctl(sOpusEnc, OPUS_SET_BITRATE(16000)); opus_encoder_ctl(sOpusEnc, OPUS_SET_VBR(1)); opus_encoder_ctl(sOpusEnc, OPUS_SET_VBR_CONSTRAINT(0)); opus_encoder_ctl(sOpusEnc, OPUS_SET_COMPLEXITY(0)); opus_encoder_ctl(sOpusEnc, OPUS_SET_INBAND_FEC(0)); opus_encoder_ctl(sOpusEnc, OPUS_S...
2018 Jan 06
3
Ask for suggestions about optimizing opus on STM32F407
<style>table.customTableClassName {margin-bottom: 10px;border-collapse: collapse;display: table;}.customTableClassName td, .customTableClassName th {border: 1px solid #ddd;}</style><div id="write-custom-write" tabindex="0" style="font-size: 12px; font-family: 宋体; outline: medium none currentcolor;"><p style="margin:0px;">Dear
2018 Feb 20
2
[EXTERNAL] Re: Developing OPUS on TI CC3220
Jean-Marc, Thanks for the response and the helpful info. I am trying to get the library to build without using the pseudostack define, and use either VAR_ARRAYS or ALLOC, but it seems the global stack is not defined. Where do can I define this in my example? VR -----Original Message----- From: Jean-Marc Valin [mailto:jmvalin at jmvalin.ca] Sent: Tuesday, February 20, 2018 5:40 PM To:
2015 Mar 04
2
adaptive bandwidth
...mize impact? Mark from IRC suggests that the app has to be aware of the losses and change it on the fly. Has anybody on the list tried this? Kelvin Chua On Wed, Mar 4, 2015 at 5:53 PM, Dragos Oancea <droancea at yahoo.com> wrote: > Hi Kelvin, > > You can use something like : > opus_encoder_ctl(enc,OPUS_SET_BITRATE(bitrate)); > opus_encoder_ctl(enc,OPUS_SET_MAX_BANDWIDTH(bandpass)); > bandpass is the audio bandpass , eg: OPUS_BANDWIDTH_WIDEBAND . > > You will need to calculate the codec bitrate from the available network > bitrate (by taking into account the size of the IP+...
2017 Apr 06
1
Encoding OPUS with difference bitrates
...nd store and send respective encoded frames/packet to the respective channel. For this I changed the opus_demo as below. But the output of the second encoded frames is completely garbled. Appreciate if anyone can suggest how to handle this case. if(1) { opus_encoder_ctl(enc, OPUS_SET_BITRATE(bitrate_bps)); len[toggle] = opus_encode(enc, in, frame_size, data[toggle], max_payload_bytes); } if(1) { opus_encoder_ctl(enc, OPUS_SET_BITRATE(32000)); enc_size = opus_encode(enc,...
2018 Apr 25
0
How to change codec frame_size at runtime
...ate = 48kbps...), then in runtime changing: - bitrate = 24, 16, 6kbps: sound is OK - frame_size = 40ms, 60ms: Not OK, sound is distort so bad 2. init codec with frame_size = 40ms , others is default, then in runtime changing: - bitrate = 6kbps: OK - bitrate = 24, 48kbps: Not OK I'm using opus_encoder_ctl api: opus_encoder_ctl(opus_data->enc,OPUS_SET_EXPERT_FRAME_DURATION(frame_duration)); opus_encoder_ctl(opus_data->enc, OPUS_SET_BITRATE(avg_bps)); Regards, Kamin -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.xiph.org/pipermail/opus/...
2015 Mar 04
2
adaptive bandwidth
I am using libopus for my implementation. I wonder if anybody in the list have any experience on how to make libopus dynamically adjust its bitrate? On Mar 3, 2015 10:42 PM, "Benjamin Schwartz" <benjamin.m.schwartz at gmail.com> wrote: > It sounds like your software isn't adjusting the opus bitrate in response > to network conditions. For example, many WebRTC
2015 Mar 04
0
adaptive bandwidth
Hi Kelvin, You can use something like :opus_encoder_ctl(enc,OPUS_SET_BITRATE(bitrate));opus_encoder_ctl(enc,OPUS_SET_MAX_BANDWIDTH(bandpass)); bandpass is the audio bandpass?, eg: OPUS_BANDWIDTH_WIDEBAND . You will need to calculate the codec bitrate from the available network bitrate (by taking into account the size of the IP+UDP+RTP headers which is 4...
2016 Jan 01
0
Confusion on CELT or Silk
...so that I can then begin making an update to reduce the memory (on chip flash and RAM) footprint. Thanks Amit On Thu, Dec 31, 2015 at 7:58 PM, Joshua Bowman <silverbacknet at gmail.com> wrote: > Opus will always use whatever mode it feels best encodes the frame, though > you can use opus_encoder_ctl(ctx,OPUS_SET_SIGNAL(signal)); where signal is > either OPUS_SIGNAL_VOICE or OPUS_SIGNAL_MUSIC to influence the decision. > SILK won't be used when picking incompatible frame sizes, but you're not > really supposed to know or care what underlying algorithm makes the magic > happe...
2016 Apr 26
2
opus-tools: Fix potential uninitialized access for set-ctl-int
Here is a simple patch to fix a bug in opusenc's set-ctl-int code -- Thanks, Michael Graczyk -------------- next part -------------- A non-text attachment was scrubbed... Name: 0001-Fix-potential-uninitialized-access-for-set-ctl-int.patch Type: text/x-patch Size: 992 bytes Desc: not available URL: <http://lists.xiph.org/pipermail/opus/attachments/20160425/22994ffa/attachment.bin>
2017 Mar 08
0
OPUS Encoder Bitrate setting
...S client When i try to encode a same voice frame(20ms sample frame) at different time intervals(not parallel encoding) for both A & B using same encoder handle by changing only bit rate. Issue here is, some noise is heard for B OPUS client, Ex: OpusEncoder* encoder = (OpusEncoder*)encHandle; opus_encoder_ctl(encoder, OPUS_SET_BITRATE(encProp->bitrate)); Is encoder fails to change bitrate to 16kbps even after setting the bit rate using opus_encoder_ctl API? Is there anyway to set bitrate according to requirement for same frame(20ms) encoding? -- Thanks & Regards Vittalprasad B R 8722397247
2019 Nov 13
0
about speech/music detector in opus 1.3.1
Hi, I’m wondering how can I get the speech/music classification result when encoding the audio in opus 1.3.1? I found in the file opus_encoder.c, there is a opus_encoder_ctl request as OPUS_GET_VOICE_RATIO_REQUEST, so I wrote in my program the below code: #define OPUS_GET_VOICE_RATIO(x) 11019, __opus_check_int_ptr(x) int32_t voiceRatio; opus_encoder_ctl(encoder, OPUS_GET_VOICE_RATIO(&voiceRatio)); LOGI("voice ratio:%d", voiceRatio); But it always retur...
2015 Mar 04
0
adaptive bandwidth
...ft bitrate down to minimize impact?Mark from IRC suggests that the app has to be aware of the losses and change it on the fly.Has anybody on the list tried this? Kelvin Chua On Wed, Mar 4, 2015 at 5:53 PM, Dragos Oancea <droancea at yahoo.com> wrote: Hi Kelvin, You can use something like :opus_encoder_ctl(enc,OPUS_SET_BITRATE(bitrate));opus_encoder_ctl(enc,OPUS_SET_MAX_BANDWIDTH(bandpass)); bandpass is the audio bandpass?, eg: OPUS_BANDWIDTH_WIDEBAND . You will need to calculate the codec bitrate from the available network bitrate (by taking into account the size of the IP+UDP+RTP headers which is 4...
2013 Oct 06
1
Encoder off by one
If you encode with int iByteSizeEncoded = opus_encode(m_enc, m_ShortsInput, (1920/sizeof(short)), m_EncodedBytes, (960*6)); ... the byte size is 120. I thought that an odd value like 359 has to be a fault on my side. I thought it would be a multiple of something. So 359 is really correct??? Thank you for clearing this up. Am 06.10.2013 16:50, schrieb Jean-Marc Valin: > Why
2012 Oct 19
3
How to cross-compile opus-tools?
..._string' /home/user/source/opus-tools/src/opusenc.c:566: undefined reference to `opus_multistream_encoder_create' /home/user/source/opus-tools/src/opusenc.c:577: undefined reference to `opus_multistream_encoder_ctl' /home/user/source/opus-tools/src/opusenc.c:578: undefined reference to `opus_encoder_ctl' /home/user/source/opus-tools/src/opusenc.c:580: undefined reference to `opus_strerror' /home/user/source/opus-tools/src/opusenc.c:596: undefined reference to `opus_multistream_encoder_ctl' /home/user/source/opus-tools/src/opusenc.c:602: undefined reference to `opus_multistream_encoder_...
2014 Feb 27
1
OPUS_SET_MAX_BANDWIDTH does not have expected results
...TH. I expect that setting this to OPUS_BANDWIDTH_NARROWBAND would give similar results to passing an 8Khz sample rate stream, but OPUS_SET_MAX_BANDWIDTH has almost no effect with any settings. My test data has 4Khz bandwidth. I am testing the opus encoder (latest versions) with the following opus_encoder_ctl options: OPUS_SET_VBR=1, OPUS_SET_VBR_CONSTRAINT=unconstrained, OPUS_SET_COMPLEXITY=10, OPUS_APPLICATION_AUDIO, frame=60ms I compress 2 separate audio streams which only differ in the sample rate. One is 8Khz and the other is 16Khz. Both contain identical 4Khz bandwidth audio (the 16Khz fil...
2019 Apr 01
2
API for checking whether the encoder is in DTX (PR #107)
.../dd> + * </dl> + * @hideinitializer */ +#define OPUS_GET_IN_DTX(x) OPUS_GET_IN_DTX_REQUEST, __opus_check_int_ptr(x) /**@}*/ diff --git a/src/opus_encoder.c b/src/opus_encoder.c index cbeb40ae..0d84737a 100644 --- a/src/opus_encoder.c +++ b/src/opus_encoder.c @@ -2725,6 +2725,27 @@ int opus_encoder_ctl(OpusEncoder *st, int request, ...) ret = celt_encoder_ctl(celt_enc, OPUS_SET_ENERGY_MASK(value)); } break; + case OPUS_GET_IN_DTX_REQUEST: + { + opus_int32 *value = va_arg(ap, opus_int32*); + if (!value) + { +...
2017 Nov 08
4
Gapless concatenation of Opus frames
...independent blocks (say, as an example, 50 frames or 1s each), encode these as raw Opus frames and cache them on disc ahead of time. For each block I'd like to reset the encoder to ensure independence between the first frame of each block and the last frames in the previous block, e.g., using opus_encoder_ctl(enc_ctx, OPUS_RESET_STATE) When the client requests a certain sequence of blocks (which may originate from various input files in (let's pretend) any order) my goal is to (on-demand) encapsulate the pre-encoded frames as WebM and send them to the client. However, in early experiments [2], res...