Displaying 3 results from an estimated 3 matches for "ystack".
Did you mean:
stack
2019 Jun 14
0
resample of libopusenc-0.2.1 outputs all zeros if define FIXED_POINT
.../
+ x[j+st->filt_len-1]=WORD2INT(32768 * in[j*istride_save]);
#else
x[j+st->filt_len-1]=in[j*istride_save];
#endif
@@ -1017,7 +1018,8 @@ EXPORT int speex_resampler_process_int(S
for (j=0;j<ochunk+omagic;++j)
#ifdef FIXED_POINT
- out[j*ostride_save] = ystack[j];
+ /* [-32768, 32767] ==> [-1.0, 1.0] */
+ out[j*ostride_save] = ystack[j] / 32768.f;
#else
out[j*ostride_save] = WORD2INT(ystack[j]);
#endif
2008 May 03
2
Resampler (no api)
..., in_len, y, out_len);
- }
- st->in_stride = istride_save;
- st->out_stride = ostride_save;
- for (i=0;i<*out_len;i++)
- out[i*st->out_stride] = WORD2INT(y[i]);
+ const unsigned int ylen = (olen < FIXED_STACK_ALLOC) ? olen : FIXED_STACK_ALLOC;
+ VARDECL(spx_word16_t *ystack);
+ ALLOC(ystack, ylen, spx_word16_t);
#else
- spx_word16_t x[FIXED_STACK_ALLOC];
- spx_word16_t y[FIXED_STACK_ALLOC];
- spx_uint32_t ilen=*in_len, olen=*out_len;
- istride_save = st->in_stride;
- ostride_save = st->out_stride;
- while (ilen && olen)
- {
- spx_ui...
2008 May 03
0
Resampler, memory only variant
..., in_len, y, out_len);
- }
- st->in_stride = istride_save;
- st->out_stride = ostride_save;
- for (i=0;i<*out_len;i++)
- out[i*st->out_stride] = WORD2INT(y[i]);
+ const unsigned int ylen = (olen < FIXED_STACK_ALLOC) ? olen : FIXED_STACK_ALLOC;
+ VARDECL(spx_word16_t *ystack);
+ ALLOC(ystack, ylen, spx_word16_t);
#else
- spx_word16_t x[FIXED_STACK_ALLOC];
- spx_word16_t y[FIXED_STACK_ALLOC];
- spx_uint32_t ilen=*in_len, olen=*out_len;
- istride_save = st->in_stride;
- ostride_save = st->out_stride;
- while (ilen && olen)
- {
- spx_ui...