Displaying 5 results from an estimated 5 matches for "opus_decoder_init".
2017 Jun 05
3
Trying to use Opus in an STM32F429IIT6 embedded project
...flags OVERRIDE_OPUS_ALLOC OVERRIDE_OPUS_FREE 'opus_alloc(x)=NULL' and
'opus_free(x)=NULL', but still having no success.
The code I wrote is:
int size;
int error;
OpusDecoder* dec;
size = opus_decoder_get_size(1);
dec = (OpusDecoder *) malloc(size);
error = opus_decoder_init(dec, 8000, 1);
I also tried this code:
int error;
OpusDecoder *dec;
dec = opus_decoder_create(8000, 1, &error);
In this particular case, I got an error and the firmware crashes.
Once I'm totally new to embedded systems, I'd like to ask some help from
you. Can anyone shed...
2017 Jun 05
0
Trying to use Opus in an STM32F429IIT6 embedded project
On 05/06/17 08:28 AM, Ulisses Piassa wrote:
> I ported all the files from OpusLib 1.1.4 needed to compile the project,
> but when I try to create and OpusDecode state, it returns the error -7
> (OPUS_ALLOC_FAIL).
Are you getting OPUS_ALLOC_FAIL on the opus_decoder_init() too or just
on opus_decoder_create()?
> I'm compiling it with the USE_ALLOCA flag. I also tried to compile it
> with the flags OVERRIDE_OPUS_ALLOC OVERRIDE_OPUS_FREE
> 'opus_alloc(x)=NULL' and 'opus_free(x)=NULL', but still having no success.
when you use OVERRIDE_O...
2014 Feb 05
1
Documentation inconsistencies
...uch a great codec!
I have noticed a few smaller inconsistencies in the documentation, which
may be confusing:
* Encoder related CTLs
OPUS_GET_SAMPLE_RATE(x)
"Gets the sampling rate the encoder or decoder was initialized with.
This simply returns the Fs value passed to opus_encoder_init() or
opus_decoder_init()."
---> Is it a generic CTL?
OPUS_GET_LAST_PACKET_DURATION(x)
"Gets the duration (in samples) of the last packet successfully decoded
or concealed."
---> Is it a decoder CTL?
* Generic CTLs
OPUS_GET_PITCH(x)
"Gets the pitch of the last decoded frame, if available....
2012 Aug 31
1
Memory Size?
...er
memory requirements:
size = opus_encoder_get_size(config.channels);
enc = malloc(size);
error = opus_encoder_init(enc, config.Fs, config.channels,
config.application);
size = opus_decoder_get_size(config.channels);
dec = malloc(size);
error = opus_decoder_init(dec, config.Fs, config.channels);
Both the encode decoder init function return no error. However, opus_encode
crashes somewhere deep in the bowels of the function (I cannot determine
where since I have compiler optimizations enabled). Do I need more heap than
what is returned by the above get_s...
2013 May 23
2
ASM runtime detection and optimizations
...#include "define.h"
#include "mathops.h"
+#include "cpu_support.h"
struct OpusDecoder {
int celt_dec_offset;
@@ -70,6 +71,7 @@ struct OpusDecoder {
#endif
opus_uint32 rangeFinal;
+ int arch;
};
#ifdef FIXED_POINT
@@ -119,6 +121,7 @@ int opus_decoder_init(OpusDecoder *st, opus_int32 Fs, int channels)
st->Fs = Fs;
st->DecControl.API_sampleRate = st->Fs;
st->DecControl.nChannelsAPI = st->channels;
+ st->arch = opus_select_arch();
/* Reset decoder */
ret = silk_InitDecoder( silk_dec );
diff --git a/src/opu...