[opus] [EXTERNAL] Re: Developing OPUS on TI CC3220

Jean-Marc Valin jmvalin at jmvalin.ca
Fri Feb 23 17:12:02 UTC 2018


On 02/23/2018 10:47 AM, Rodriguez, Vince wrote:
> Currently decode takes 16~22 ms and encode is ~13 ms. What is the best
> way to try to reduce this time? Also, unsure why encode is taking less
> time than decode...

Tried running a profiler?

> I've also noticed if I change my encoder to silk only, I get a Heap
> overflow... I have dynamically allocated a heap for the codec, got the
> size using the api and used encode init so that the memory is allocated
> to my created heap. I have 30k currently in heap, since the return of
> get  size was ~25 kB. This seems to happen when I change the application
> as well. :/

SILK and CELT use exactly as much heap since the only heap Opus needs is
the encoder state which holds both the SILK and the CELT state. What
stack allocator did you end up choosing? If you used the pseudo-stack,
then that allocates a lot of heap memory. If not, then maybe you have
some sort of collision between the stack and heap?

>     i32error = opus_encoder_init(sOpusEnc, 16000, 1,
> OPUS_APPLICATION_RESTRICTED_LOWDELAY);

OPUS_APPLICATION_RESTRICTED_LOWDELAY will force CELT-only mode here,
regardless of other options.

>    opus_encoder_ctl(sOpusEnc, OPUS_SET_FORCE_CHANNELS(1));//Mono

No need to force mono since you're only encoding one channel (this does
nothing).

	Jean-Marc


More information about the opus mailing list