Loading apps/decoder.c +35 −1 Original line number Diff line number Diff line Loading @@ -2265,6 +2265,23 @@ static ivas_error decodeG192( } } #endif #ifdef FIX_HRTF_LOAD_API /* decode transport channels, do TSM and feed to renderer */ if ( ( error = IVAS_DEC_GetSamplesDecoder( hIvasDec, isSplitRend, splitRendBits ) ) != IVAS_ERR_OK ) { return error; } #endif #ifdef OBJ_EDITING_API /* Do the final preparations needed for rendering */ if ( ( error = IVAS_DEC_PrepareRenderer( hIvasDec ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError: could not prepare the renderer: %s\n\n", IVAS_DEC_GetErrorMessage( error ) ); goto cleanup; } #endif } if ( isSplitRend ) Loading Loading @@ -2714,6 +2731,9 @@ static ivas_error decodeVoIP( int16_t nOutSamples = 0; #ifdef FIX_CREND_SIMPLIFY_CODE bool bitstreamReadDone = false; #ifdef OBJ_EDITING_API bool parametersAvailableForEditing = false; #endif uint16_t nSamplesRendered; #endif Loading Loading @@ -3005,13 +3025,21 @@ static ivas_error decodeVoIP( #endif #ifdef SUPPORT_JBM_TRACEFILE #ifdef FIX_CREND_SIMPLIFY_CODE #ifdef OBJ_EDITING_API if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, writeJbmTraceFileFrameWrapper, jbmTraceWriter, &bitstreamReadDone, &nSamplesRendered, ¶metersAvailableForEditing ) ) != IVAS_ERR_OK ) #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, writeJbmTraceFileFrameWrapper, jbmTraceWriter, &bitstreamReadDone, &nSamplesRendered ) ) != IVAS_ERR_OK ) #endif #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, pcmBuf, systemTime_ms, writeJbmTraceFileFrameWrapper, jbmTraceWriter ) ) != IVAS_ERR_OK ) #endif #else #ifdef FIX_CREND_SIMPLIFY_CODE #ifdef OBJ_EDITING_API if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, &bitstreamReadDone, ¶metersAvailableForEditing ) ) != IVAS_ERR_OK ) #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, &bitstreamReadDone ) ) != IVAS_ERR_OK ) #endif #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, pcmBuf, systemTime_ms ) ) != IVAS_ERR_OK ) #endif Loading Loading @@ -3046,9 +3074,15 @@ static ivas_error decodeVoIP( } } #endif #ifdef FIX_HRTF_LOAD #ifdef OBJ_EDITING_API if ( parametersAvailableForEditing == true ) { /* do the object editing here */ } #endif #ifdef FIX_HRTF_LOAD } /* while ( nSamplesRendered < nOutSamples ) */ #endif /* write JBM Offset file entry */ if ( jbmOffsetWriter != NULL ) Loading lib_com/common_api_types.h +12 −0 Original line number Diff line number Diff line Loading @@ -137,9 +137,21 @@ typedef struct _IVAS_ISM_METADATA float yaw; float pitch; Word16 non_diegetic_flag; #ifdef OBJ_EDITING_API Word32 gain_fx; #endif } IVAS_ISM_METADATA; #ifdef OBJ_EDITING_API typedef struct _IVAS_EDITABLE_PARAMETERS { Word16 num_obj; IVAS_ISM_METADATA ism_metadata[IVAS_MAX_NUM_OBJECTS]; Word32 gain_bed_fx; } IVAS_EDITABLE_PARAMETERS; #endif typedef struct { // float w, x, y, z; Loading lib_com/ivas_ism_com_fx.c +11 −0 Original line number Diff line number Diff line Loading @@ -470,6 +470,17 @@ void ivas_ism_reset_metadata( hIsmMeta->non_diegetic_flag = 0; move16(); #ifdef OBJ_EDITING_API hIsmMeta->edited_gain_fx = ONE_IN_Q31; hIsmMeta->edited_azimuth_fx = 0; hIsmMeta->edited_elevation_fx = 0; hIsmMeta->edited_pitch_fx = 0; hIsmMeta->edited_yaw_fx = 0; hIsmMeta->edited_radius_fx = ONE_IN_Q9; hIsmMeta->gain_fx = ONE_IN_Q31; hIsmMeta->non_diegetic_flag = 0; #endif return; } Loading lib_com/ivas_prot_fx.h +31 −0 Original line number Diff line number Diff line Loading @@ -777,6 +777,12 @@ ivas_error ivas_ism_metadata_dec_fx( DEC_CORE_HANDLE st0 /* i : core-coder handle */ ); #ifdef OBJ_EDITING_API void ivas_ism_renderer_update_md( Decoder_Struct *st_ivas /* i/o: main IVAS decoder handle */ ); #endif void ivas_get_ism_sid_quan_bitbudget_fx( const Word16 nchan_ism, /* i : number of objects */ Word16 *nBits_azimuth, /* o : number of Q bits for azimuth */ Loading Loading @@ -4225,6 +4231,12 @@ void ivas_jbm_dec_feed_tc_to_renderer_fx( Word32 *data /* i/o: transport channels/output synthesis signal */ ); #ifdef OBJ_EDITING_API void ivas_jbm_dec_prepare_renderer( Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ ); #endif void ivas_jbm_dec_get_adapted_subframes( const Word16 nCldfbTs, /* i : number of time slots in the current frame */ Word16 *subframe_nbslots, /* i/o: subframe grid */ Loading Loading @@ -4320,6 +4332,18 @@ void ivas_param_ism_dec_digest_tc_fx( Word32 *transport_channels[], /* i : synthesized core-coder transport channels/DirAC output */ Word16 q_tc_in ); #ifdef OBJ_EDITING_API void ivas_param_ism_dec_dequant_md_fx( Decoder_Struct *st_ivas ); void ivas_param_ism_dec_prepare_renderer_fx( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const Word16 nCldfbSlots /* i : number of CLFBS slots in the transport channels */ ); #endif void ivas_param_ism_dec_render_fx( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const UWord16 nSamplesAsked, /* i : number of CLDFB slots requested */ Loading Loading @@ -5163,6 +5187,13 @@ void ivas_param_mc_dec_digest_tc_fx( Word32 *transport_channels_f_fx[], Word16 transport_f_e ); #ifdef OBJ_EDITING_API void ivas_param_mc_dec_prepare_renderer( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const UWord8 nCldfbSlots /* i : number of CLFBS slots in the transport channels */ ); #endif void ivas_param_mc_dec_render_fx( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const UWord16 nSamplesAsked, /* i : number of CLDFB slots requested */ Loading lib_com/ivas_stat_com.h +12 −0 Original line number Diff line number Diff line Loading @@ -65,6 +65,18 @@ typedef struct Word32 yaw_fx; /* yaw value read from the input metadata file */ /* Q22 */ Word32 pitch_fx; /* pitch value read from the input metadata file */ /* Q22 */ #ifdef OBJ_EDITING_API Word32 gain_fx; /* Q31 */ Word32 edited_azimuth_fx; /* Q22 */ Word32 edited_elevation_fx; /* Q22 */ Word16 edited_radius_fx; /* Q9 */ Word32 edited_yaw_fx; /* Q22 */ Word32 edited_pitch_fx; /* Q22 */ Word32 edited_gain_fx; /* Q31 */ #endif Word16 non_diegetic_flag; /* Non-diegetic (non-headtracked) object flag */ ISM_METADATA_ANGLE position_angle; /* Angle structs for azimuth and elevation */ Loading Loading
apps/decoder.c +35 −1 Original line number Diff line number Diff line Loading @@ -2265,6 +2265,23 @@ static ivas_error decodeG192( } } #endif #ifdef FIX_HRTF_LOAD_API /* decode transport channels, do TSM and feed to renderer */ if ( ( error = IVAS_DEC_GetSamplesDecoder( hIvasDec, isSplitRend, splitRendBits ) ) != IVAS_ERR_OK ) { return error; } #endif #ifdef OBJ_EDITING_API /* Do the final preparations needed for rendering */ if ( ( error = IVAS_DEC_PrepareRenderer( hIvasDec ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError: could not prepare the renderer: %s\n\n", IVAS_DEC_GetErrorMessage( error ) ); goto cleanup; } #endif } if ( isSplitRend ) Loading Loading @@ -2714,6 +2731,9 @@ static ivas_error decodeVoIP( int16_t nOutSamples = 0; #ifdef FIX_CREND_SIMPLIFY_CODE bool bitstreamReadDone = false; #ifdef OBJ_EDITING_API bool parametersAvailableForEditing = false; #endif uint16_t nSamplesRendered; #endif Loading Loading @@ -3005,13 +3025,21 @@ static ivas_error decodeVoIP( #endif #ifdef SUPPORT_JBM_TRACEFILE #ifdef FIX_CREND_SIMPLIFY_CODE #ifdef OBJ_EDITING_API if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, writeJbmTraceFileFrameWrapper, jbmTraceWriter, &bitstreamReadDone, &nSamplesRendered, ¶metersAvailableForEditing ) ) != IVAS_ERR_OK ) #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, writeJbmTraceFileFrameWrapper, jbmTraceWriter, &bitstreamReadDone, &nSamplesRendered ) ) != IVAS_ERR_OK ) #endif #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, pcmBuf, systemTime_ms, writeJbmTraceFileFrameWrapper, jbmTraceWriter ) ) != IVAS_ERR_OK ) #endif #else #ifdef FIX_CREND_SIMPLIFY_CODE #ifdef OBJ_EDITING_API if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, &bitstreamReadDone, ¶metersAvailableForEditing ) ) != IVAS_ERR_OK ) #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, (void *) pcmBuf, systemTime_ms, &bitstreamReadDone ) ) != IVAS_ERR_OK ) #endif #else if ( ( error = IVAS_DEC_VoIP_GetSamples( hIvasDec, nOutSamples, pcmBuf, systemTime_ms ) ) != IVAS_ERR_OK ) #endif Loading Loading @@ -3046,9 +3074,15 @@ static ivas_error decodeVoIP( } } #endif #ifdef FIX_HRTF_LOAD #ifdef OBJ_EDITING_API if ( parametersAvailableForEditing == true ) { /* do the object editing here */ } #endif #ifdef FIX_HRTF_LOAD } /* while ( nSamplesRendered < nOutSamples ) */ #endif /* write JBM Offset file entry */ if ( jbmOffsetWriter != NULL ) Loading
lib_com/common_api_types.h +12 −0 Original line number Diff line number Diff line Loading @@ -137,9 +137,21 @@ typedef struct _IVAS_ISM_METADATA float yaw; float pitch; Word16 non_diegetic_flag; #ifdef OBJ_EDITING_API Word32 gain_fx; #endif } IVAS_ISM_METADATA; #ifdef OBJ_EDITING_API typedef struct _IVAS_EDITABLE_PARAMETERS { Word16 num_obj; IVAS_ISM_METADATA ism_metadata[IVAS_MAX_NUM_OBJECTS]; Word32 gain_bed_fx; } IVAS_EDITABLE_PARAMETERS; #endif typedef struct { // float w, x, y, z; Loading
lib_com/ivas_ism_com_fx.c +11 −0 Original line number Diff line number Diff line Loading @@ -470,6 +470,17 @@ void ivas_ism_reset_metadata( hIsmMeta->non_diegetic_flag = 0; move16(); #ifdef OBJ_EDITING_API hIsmMeta->edited_gain_fx = ONE_IN_Q31; hIsmMeta->edited_azimuth_fx = 0; hIsmMeta->edited_elevation_fx = 0; hIsmMeta->edited_pitch_fx = 0; hIsmMeta->edited_yaw_fx = 0; hIsmMeta->edited_radius_fx = ONE_IN_Q9; hIsmMeta->gain_fx = ONE_IN_Q31; hIsmMeta->non_diegetic_flag = 0; #endif return; } Loading
lib_com/ivas_prot_fx.h +31 −0 Original line number Diff line number Diff line Loading @@ -777,6 +777,12 @@ ivas_error ivas_ism_metadata_dec_fx( DEC_CORE_HANDLE st0 /* i : core-coder handle */ ); #ifdef OBJ_EDITING_API void ivas_ism_renderer_update_md( Decoder_Struct *st_ivas /* i/o: main IVAS decoder handle */ ); #endif void ivas_get_ism_sid_quan_bitbudget_fx( const Word16 nchan_ism, /* i : number of objects */ Word16 *nBits_azimuth, /* o : number of Q bits for azimuth */ Loading Loading @@ -4225,6 +4231,12 @@ void ivas_jbm_dec_feed_tc_to_renderer_fx( Word32 *data /* i/o: transport channels/output synthesis signal */ ); #ifdef OBJ_EDITING_API void ivas_jbm_dec_prepare_renderer( Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ ); #endif void ivas_jbm_dec_get_adapted_subframes( const Word16 nCldfbTs, /* i : number of time slots in the current frame */ Word16 *subframe_nbslots, /* i/o: subframe grid */ Loading Loading @@ -4320,6 +4332,18 @@ void ivas_param_ism_dec_digest_tc_fx( Word32 *transport_channels[], /* i : synthesized core-coder transport channels/DirAC output */ Word16 q_tc_in ); #ifdef OBJ_EDITING_API void ivas_param_ism_dec_dequant_md_fx( Decoder_Struct *st_ivas ); void ivas_param_ism_dec_prepare_renderer_fx( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const Word16 nCldfbSlots /* i : number of CLFBS slots in the transport channels */ ); #endif void ivas_param_ism_dec_render_fx( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const UWord16 nSamplesAsked, /* i : number of CLDFB slots requested */ Loading Loading @@ -5163,6 +5187,13 @@ void ivas_param_mc_dec_digest_tc_fx( Word32 *transport_channels_f_fx[], Word16 transport_f_e ); #ifdef OBJ_EDITING_API void ivas_param_mc_dec_prepare_renderer( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const UWord8 nCldfbSlots /* i : number of CLFBS slots in the transport channels */ ); #endif void ivas_param_mc_dec_render_fx( Decoder_Struct *st_ivas, /* i/o: IVAS decoder handle */ const UWord16 nSamplesAsked, /* i : number of CLDFB slots requested */ Loading
lib_com/ivas_stat_com.h +12 −0 Original line number Diff line number Diff line Loading @@ -65,6 +65,18 @@ typedef struct Word32 yaw_fx; /* yaw value read from the input metadata file */ /* Q22 */ Word32 pitch_fx; /* pitch value read from the input metadata file */ /* Q22 */ #ifdef OBJ_EDITING_API Word32 gain_fx; /* Q31 */ Word32 edited_azimuth_fx; /* Q22 */ Word32 edited_elevation_fx; /* Q22 */ Word16 edited_radius_fx; /* Q9 */ Word32 edited_yaw_fx; /* Q22 */ Word32 edited_pitch_fx; /* Q22 */ Word32 edited_gain_fx; /* Q31 */ #endif Word16 non_diegetic_flag; /* Non-diegetic (non-headtracked) object flag */ ISM_METADATA_ANGLE position_angle; /* Angle structs for azimuth and elevation */ Loading