Commit 07bad5b5 authored by Archit Tamarapu's avatar Archit Tamarapu
Browse files
Merge branch 'main' of ssh://forge.3gpp.org:29419/ivas-codec-pc/ivas-codec into ci/loudness-measurements-pinknoise
parents b6018aeb 12f3e947
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -210,6 +210,7 @@
    <ClCompile Include="..\lib_dec\ivas_cpe_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_decision_matrix_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_dec_render.c" />
    <ClCompile Include="..\lib_dec\ivas_dirac_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_dirac_output_synthesis_cov.c" />
    <ClCompile Include="..\lib_dec\ivas_entropy_decoder.c" />
@@ -219,7 +220,6 @@
    <ClCompile Include="..\lib_dec\ivas_ism_metadata_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_ism_param_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_ism_renderer.c" />
    <ClCompile Include="..\lib_dec\ivas_jbm_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_lfe_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_lfe_plc.c" />
    <ClCompile Include="..\lib_dec\ivas_ls_custom_dec.c" />
+3 −6
Original line number Diff line number Diff line
@@ -4,9 +4,6 @@
    <ClCompile Include="..\lib_dec\ivas_agc_dec.c">
      <Filter>decoder_ivas_c</Filter>
    </ClCompile>
    <ClCompile Include="..\lib_dec\ivas_binRenderer_internal.c">
      <Filter>decoder_ivas_c</Filter>
    </ClCompile>
    <ClCompile Include="..\lib_dec\ivas_core_dec.c">
      <Filter>decoder_ivas_c</Filter>
    </ClCompile>
@@ -49,9 +46,6 @@
    <ClCompile Include="..\lib_dec\ivas_ism_renderer.c">
      <Filter>decoder_ivas_c</Filter>
    </ClCompile>
    <ClCompile Include="..\lib_dec\ivas_jbm_dec.c">
      <Filter>decoder_ivas_c</Filter>
    </ClCompile>
    <ClCompile Include="..\lib_dec\ivas_lfe_dec.c">
      <Filter>decoder_ivas_c</Filter>
    </ClCompile>
@@ -515,6 +509,9 @@
      <Filter>decoder_all_c</Filter>
    </ClCompile>
    <ClCompile Include="..\lib_dec\lib_dec.c" />
    <ClCompile Include="..\lib_dec\ivas_dec_render.c">
      <Filter>decoder_ivas_c</Filter>
    </ClCompile>
  </ItemGroup>
  <ItemGroup>
    <ClInclude Include="..\lib_dec\ivas_stat_dec.h">
+40 −35
Original line number Diff line number Diff line
@@ -441,7 +441,6 @@ int main(

    asked_num_subframes = arg.render_num_subframes;
    uint16_t aeID = arg.aeSequence.count > 0 ? arg.aeSequence.pID[0] : IVAS_DEFAULT_AEID;
    arg.enableHeadRotation = arg.enableHeadRotation || arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM;

    if ( ( error = IVAS_DEC_Configure( hIvasDec, arg.output_Fs, arg.outputConfig, arg.render_num_subframes, arg.customLsOutputEnabled, arg.hrtfReaderEnabled,
                                       arg.enableHeadRotation, arg.enableExternalOrientation, arg.orientation_tracking, arg.renderConfigEnabled, arg.roomSize, arg.non_diegetic_pan_enabled,
@@ -451,17 +450,6 @@ int main(
        goto cleanup;
    }

    if ( ( error = IVAS_DEC_GetRenderNumSubfr( hIvasDec, &arg.render_num_subframes ) ) != IVAS_ERR_OK )
    {
        fprintf( stderr, "\nIVAS_DEC_GetRenderNumSubfr failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
        goto cleanup;
    }

    if ( arg.render_num_subframes != asked_num_subframes )
    {
        fprintf( stderr, "\nChanged render framesize, only 20ms are allowed for decoding to EXT!\n" );
    }

    /*------------------------------------------------------------------------------------------*
     * Configure Split rendering
     *------------------------------------------------------------------------------------------*/
@@ -474,6 +462,7 @@ int main(
            fprintf( stderr, "\nSplit rendering configure failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
            goto cleanup;
        }
    }

    if ( ( error = IVAS_DEC_GetRenderNumSubfr( hIvasDec, &arg.render_num_subframes ) ) != IVAS_ERR_OK )
    {
@@ -483,8 +472,7 @@ int main(

    if ( !arg.renderConfigEnabled && ( arg.render_num_subframes != asked_num_subframes ) )
    {
            fprintf( stderr, "\nChanged render framesize, only 20ms are allowed for non-0dof split rendering!\n" );
        }
        fprintf( stderr, "\nChanged render framesize, only 20ms allowed!\n" );
    }

    /*------------------------------------------------------------------------------------------*
@@ -2230,6 +2218,7 @@ static ivas_error decodeG192(
#endif
#endif
    IsmFileWriter *ismWriters[IVAS_MAX_NUM_OBJECTS];
    IVAS_QUATERNION Quaternions[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES] = { { -3, 0, 0, 0 }, { -3, 0, 0, 0 }, { -3, 0, 0, 0 }, { -3, 0, 0, 0 } };
    IVAS_VECTOR3 Pos[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES] = { { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } };
    int16_t vec_pos_update, vec_pos_len;
    SplitFileReadWrite *splitRendWriter = NULL;
@@ -2417,10 +2406,8 @@ static ivas_error decodeG192(
        }

        /* Head-tracking input simulation */
        if ( arg.enableHeadRotation )
        if ( arg.enableHeadRotation || isSplitRend )
        {
            IVAS_QUATERNION Quaternions[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];

            if ( headRotReader == NULL )
            {
                for ( i = 0; i < (int16_t) num_subframes; i++ )
@@ -2458,7 +2445,6 @@ static ivas_error decodeG192(

        if ( arg.enableExternalOrientation )
        {
            IVAS_QUATERNION Quaternions[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
            int8_t enableHeadRotation[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
            int8_t enableExternalOrientation[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
            int8_t enableRotationInterpolation[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
@@ -2846,16 +2832,28 @@ static ivas_error decodeG192(
        }

        /* Head-tracking input simulation */
        if ( arg.enableHeadRotation )
        if ( arg.enableHeadRotation || isSplitRend )
        {
            IVAS_QUATERNION Quaternion;
            if ( ( error = HeadRotationFileReading( headRotReader, &Quaternion, &Pos[0] ) ) != IVAS_ERR_OK )
            if ( headRotReader == NULL )
            {
                Quaternions[0].w = -3.0f;
                Quaternions[0].x = 0.0f;
                Quaternions[0].y = 0.0f;
                Quaternions[0].z = 0.0f;
                Pos[0].x = 0.0f;
                Pos[0].y = 0.0f;
                Pos[0].z = 0.0f;
            }
            else
            {
                if ( ( error = HeadRotationFileReading( headRotReader, &Quaternions[0], &Pos[0] ) ) != IVAS_ERR_OK )
                {
                    fprintf( stderr, "\nError %s while reading head orientation from %s\n", IVAS_DEC_GetErrorMessage( error ), RotationFileReader_getFilePath( headRotReader ) );
                    goto cleanup;
                }
            }

            if ( ( error = IVAS_DEC_FeedHeadTrackData( hIvasDec, Quaternion, Pos[0], 0, DEFAULT_AXIS ) ) != IVAS_ERR_OK )
            if ( ( error = IVAS_DEC_FeedHeadTrackData( hIvasDec, Quaternions[0], Pos[0], 0, DEFAULT_AXIS ) ) != IVAS_ERR_OK )
            {
                fprintf( stderr, "\nIVAS_DEC_FeedHeadTrackData failed: %s\n", IVAS_DEC_GetErrorMessage( error ) );
                goto cleanup;
@@ -3178,6 +3176,7 @@ static ivas_error decodeVoIP(

    IVAS_DEC_BS_FORMAT bsFormat = IVAS_DEC_BS_UNKOWN;
    IsmFileWriter *ismWriters[IVAS_MAX_NUM_OBJECTS];
    IVAS_QUATERNION Quaternions[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES] = { { -3, 0, 0, 0 }, { -3, 0, 0, 0 }, { -3, 0, 0, 0 }, { -3, 0, 0, 0 } };
    IVAS_VECTOR3 Pos[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES] = { { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } };
    int16_t vec_pos_update, vec_pos_len;
    int16_t nOutSamples = 0;
@@ -3380,10 +3379,8 @@ static ivas_error decodeVoIP(
        }

        /* Head-tracking input simulation */
        if ( arg.enableHeadRotation )
        if ( arg.enableHeadRotation || isSplitRend )
        {
            IVAS_QUATERNION Quaternions[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];

            if ( headRotReader == NULL )
            {
                for ( i = 0; i < (int16_t) num_subframes; i++ )
@@ -3422,7 +3419,6 @@ static ivas_error decodeVoIP(

        if ( arg.enableExternalOrientation )
        {
            IVAS_QUATERNION Quaternions[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
            int8_t enableHeadRotation[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
            int8_t enableExternalOrientation[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
            int8_t enableRotationInterpolation[IVAS_MAX_PARAM_SPATIAL_SUBFRAMES];
@@ -4332,6 +4328,15 @@ static ivas_error restartDecoder(
        goto cleanup;
    }

    if ( arg->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        if ( ( error = IVAS_DEC_EnableSplitRendering( hIvasDec ) ) != IVAS_ERR_OK )
        {
            fprintf( stderr, "\nSplit rendering configure failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
            goto cleanup;
        }
    }

    if ( ( error = IVAS_DEC_GetRenderNumSubfr( hIvasDec, &arg->render_num_subframes ) ) != IVAS_ERR_OK )
    {
        fprintf( stderr, "\nIVAS_DEC_GetRenderNumSubfr failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
+1 −1
Original line number Diff line number Diff line
@@ -2107,7 +2107,7 @@ static void usage_enc( void )
    fprintf( stdout, "                      where 0 = adaptive, 3-100 = fixed in number of frames,\n" );
    fprintf( stdout, "                      default is deactivated\n" );
    fprintf( stdout, "-dtx                : Activate DTX mode with a SID update rate of 8 frames\n" );
    fprintf( stdout, "                      Note: DTX is supported in EVS, stereo, ISM, SBA up to 80kbps and MASA up to 128kbps \n" );
    fprintf( stdout, "                      Note: DTX is supported on all bitrates for EVS, stereo, ISM, and MASA, and up to 80 kbps for SBA.\n" );
    fprintf( stdout, "-rf p o             : Activate channel-aware mode for WB and SWB signal at 13.2kbps, \n" );
    fprintf( stdout, "                      where FEC indicator, p: LO or HI, and FEC offset, o: 2, 3, 5, or 7 in number of frames.\n" );
    fprintf( stdout, "                      Alternatively p and o can be replaced by a rf configuration file with each line  \n" );
+1 −1
Original line number Diff line number Diff line
@@ -2207,7 +2207,7 @@ static void usage_enc( void )
    fprintf( stdout, "                      where 0 = adaptive, 3-100 = fixed in number of frames,\n" );
    fprintf( stdout, "                      default is deactivated\n" );
    fprintf( stdout, "-dtx                : Activate DTX mode with a SID update rate of 8 frames\n" );
    fprintf( stdout, "                      Note: DTX is supported in EVS, stereo, ISM, SBA up to 80kbps and MASA up to 128kbps \n" );
    fprintf( stdout, "                      Note: DTX is supported on all bitrates for EVS, stereo, ISM, and MASA, and up to 80 kbps for SBA.\n" );
    fprintf( stdout, "-rf p o             : Activate channel-aware mode for WB and SWB signal at 13.2kbps, \n" );
    fprintf( stdout, "                      where FEC indicator, p: LO or HI, and FEC offset, o: 2, 3, 5, or 7 in number of frames.\n" );
    fprintf( stdout, "                      Alternatively p and o can be replaced by a rf configuration file with each line  \n" );
Loading