Commit 01c17c8c authored by Sandesh Venkatesh's avatar Sandesh Venkatesh
Browse files

Renderer crash fix, some float code cleanup

parent 36219e01
Loading
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -352,7 +352,9 @@ typedef enum

#define ISM_RADIUS_NBITS                        6 
#define ISM_RADIUS_MIN                          0.0f
#define ISM_RADIUS_MIN_Q9                       0
#define ISM_RADIUS_DELTA                        0.25f /* Max radius = (2^ISM_RADIUS_NBITS-1)*0.25 = 15.75 */
#define ISM_RADIUS_DELTA_Q8                     64
#define ISM_EXTENDED_METADATA_BRATE             IVAS_64k
#define ISM_METADATA_IS_NDP_BITS                1
#define ISM_EXTENDED_METADATA_BITS              1
+5 −1
Original line number Diff line number Diff line
@@ -1043,14 +1043,18 @@ ISM_MODE ivas_ism_mode_select(
)
{
    ISM_MODE ism_mode = ISM_MODE_NONE;
    move32();

    test();
    IF( GT_16( nchan_inp, 2 ) && LE_32( ivas_total_brate, ACELP_32k ) )
    {
        ism_mode = ISM_MODE_PARAM;
        move32();
    }
    ELSE
    {
        ism_mode = ISM_MODE_DISC;
        move32();
    }

    return ism_mode;
+19 −4
Original line number Diff line number Diff line
@@ -4668,12 +4668,14 @@ void ivas_param_mc_dec_close(
);
#endif // IVAS_FLOAT_FIXED

#ifndef IVAS_FLOAT_FIXED
void ivas_param_mc_dec_read_BS(
    const int32_t ivas_total_brate,                             /* i  : IVAS total bitrate                                  */
    Decoder_State *st,                                          /* i/o: decoder state structure                             */
    PARAM_MC_DEC_HANDLE hParamMC,                               /* i/o: decoder ParamMC handle                              */
    int16_t *nb_bits                                            /* o  : number of bits written                              */
);
#endif

void ivas_param_mc_dec_digest_tc(
    Decoder_Struct *st_ivas,                                    /* i/o: IVAS decoder handle                                 */
@@ -6445,7 +6447,6 @@ void update_bits_next_block(
    const int16_t max_i,                                        /* i  : max number of subands                           */
    const int16_t max_k                                         /* i  : max number of subframe                          */
);
#endif

void ivas_masa_prerender(
    Decoder_Struct *st_ivas,                                    /* i/o: IVAS decoder handle                             */
@@ -6453,6 +6454,7 @@ void ivas_masa_prerender(
    const int16_t output_frame,                                 /* i  : output frame length per channel                 */
    const int16_t nchan_remapped                                /* i  : number of transports used in core               */
);
#endif

void ivas_spar_param_to_masa_param_mapping(
    Decoder_Struct *st_ivas,                                       /* i/o: IVAS decoder struct                          */
@@ -6490,11 +6492,24 @@ void ivas_binRenderer_close(
void ivas_binaural_hrtf_close(
    HRTFS_FASTCONV_HANDLE *hHrtfFastConv                        /* i/o: decoder binaural hrtf handle                    */
);

#ifdef IVAS_FLOAT_FIXED
void ivas_init_binaural_hrtf_fx(
    HRTFS_FASTCONV *HrtfFastConv                                  /* i/o: FASTCONV HRTF structure                         */
);
#else
void ivas_init_binaural_hrtf(
  HRTFS_FASTCONV *HrtfFastConv                                  /* i/o: FASTCONV HRTF structure                         */
);

#endif
#ifdef IVAS_FLOAT_FIXED
ivas_error ivas_allocate_binaural_hrtf_fx(
    HRTFS_FASTCONV *HrtfFastConv,                       /* i/o: FASTCONV HRTF structure     */
    const AUDIO_CONFIG input_config,                    /* i  : input audio configuration   */
    const BINAURAL_INPUT_AUDIO_CONFIG bin_input_config, /* i  : binaural input audio config */
    const RENDERER_TYPE renderer_type,                  /* i  : renderer type               */
    const Word16 allocate_init_flag                     /* i  : Memory allocation flag      */
);
#else
ivas_error ivas_allocate_binaural_hrtf(
    HRTFS_FASTCONV *HrtfFastConv,                               /* i/o: FASTCONV HRTF structure */
    const AUDIO_CONFIG input_config,                            /* i  : input audio configuration                       */
@@ -6502,7 +6517,7 @@ ivas_error ivas_allocate_binaural_hrtf(
    const RENDERER_TYPE renderer_type,                          /* i  : renderer type                                   */
    const int16_t allocate_init_flag                            /* i  : Memory allocation flag                          */
);

#endif

void ivas_binRenderer(
    BINAURAL_RENDERER_HANDLE hBinRenderer,                      /* i/o: binaural renderer handle                                */
+7 −0
Original line number Diff line number Diff line
@@ -2164,4 +2164,11 @@ ivas_error ivas_spar_dec_open_fx(
    Decoder_Struct *st_ivas,         /* i/o: IVAS decoder handle        */
    const int16_t spar_reconfig_flag /* i  : SPAR reconfiguration flag  */
);

void ivas_param_mc_dec_read_BS_fx(
    const Word32 ivas_total_brate, /* i  : IVAS total bitrate      */
    Decoder_State *st,              /* i/o: decoder state structure */
    PARAM_MC_DEC_HANDLE hParamMC,   /* i/o: decoder ParamMC handle  */
    Word16 *nb_bits                /* o  : number of bits written  */
);
#endif
+1 −1
Original line number Diff line number Diff line
@@ -155,7 +155,7 @@ void ivas_spar_agc_dec_close_fx(
    hAgc = *hAgcDec;

    free( hAgc->agc_com.winFunc_fx );
    hAgc->agc_com.winFunc = NULL;
    hAgc->agc_com.winFunc_fx = NULL;

    free( hAgc->gain_state );
    hAgc->gain_state = NULL;
Loading