Commit d8642314 authored by vaclav's avatar vaclav
Browse files

acceptance of switches, step 1

parent 4a523053
Loading
Loading
Loading
Loading
+3 −16
Original line number Diff line number Diff line
@@ -78,11 +78,8 @@ static
#define NUM_BITS_SID_IVAS_5K2     104

#endif
#ifdef NONBE_FIX_BASOP_2233_RTPDUMP_DIFFERING_BITSTREAMS
#define RANDOM_INITSEED_DEC ( 0xFADE )
#else
#define RANDOM_INITSEED_DEC ( 0xFEEDFADE )
#endif


/*------------------------------------------------------------------------------------------*
 * Local structure for storing cmdln arguments
@@ -1951,21 +1948,12 @@ static ivas_error initOnFirstGoodFrame(
        int16_t splitRendIsarFrameSizeMs;
        int16_t lc3plusHighRes;

#ifdef NONBE_FIX_BASOP_2233_RTPDUMP_DIFFERING_BITSTREAMS
        /* Ideally ssrc is negotiated via SDP and sequence number is radomized but we
           use fixed seed for random num generator for regression based tests. Any realtime
           application should implement this initialization seperately */
        uint16_t rtpDecSeed = RANDOM_INITSEED_DEC;
        uint32_t ssrc = ( (uint32_t) IVAS_RTP_OwnRandom( &rtpDecSeed ) & 0x0000FFFF ) | ( (uint32_t) IVAS_RTP_OwnRandom( &rtpDecSeed ) << 16 );
        uint16_t seqNumInitVal = IVAS_RTP_OwnRandom( &rtpDecSeed );
#else
        /* Ideally ssrc is negotiated via SDP and sequence number is radomized but we
        use fixed seed for random num generator for regression based tests. Any realtime
        application should implement this initialization seperately */
        srand( RANDOM_INITSEED_DEC );
        uint32_t ssrc = ( (uint32_t) rand() & 0x0000FFFF ) | ( (uint32_t) rand() << 16 );
        uint16_t seqNumInitVal = (uint16_t) ( rand() & 0xFFFF );
#endif

        if ( ( error = IVAS_DEC_GetDelay( hIvasDec, delayNumSamples_temp, &delayTimeScale_temp ) ) != IVAS_ERR_OK )
        {
@@ -4053,8 +4041,8 @@ static void do_object_editing(
                        editableParameters->ism_metadata[obj_idx].elevation = readInfo->obj_ele[obj_idx];
                    }
                }
#ifdef FIX_1427_OBJ_EDITING_EXT_METADATA
                /* object direction editing only for diegetic objects */

                /* object orientation editing only for diegetic objects */
                if ( readInfo->obj_yaw_edited[obj_idx] )
                {
                    if ( readInfo->obj_yaw_relative[obj_idx] )
@@ -4092,7 +4080,6 @@ static void do_object_editing(
                        editableParameters->ism_metadata[obj_idx].radius = readInfo->obj_radius[obj_idx];
                    }
                }
#endif
            }

            /* gain editing for all objects */
+0 −13
Original line number Diff line number Diff line
@@ -59,11 +59,7 @@ static
#endif
    int32_t frame = 0; /* Counter of frames */

#ifdef NONBE_FIX_BASOP_2233_RTPDUMP_DIFFERING_BITSTREAMS
#define RANDOM_INITSEED_ENC ( 0xDEAF )
#else
#define RANDOM_INITSEED_ENC ( 0xFEEDDEAF )
#endif

#define DEFAULT_FIXED_SID_RATE 8 /* DTX SID rate */

@@ -228,21 +224,12 @@ int main(
    uint8_t au[IVAS_MAX_BITS_PER_FRAME / 8];
    IVAS_RTP ivasRtp = { 0 };

#ifdef NONBE_FIX_BASOP_2233_RTPDUMP_DIFFERING_BITSTREAMS
    /* Ideally ssrc is negotiated via SDP and sequence number is radomized but we
       use fixed seed for random num generator for regression based tests. Any realtime
       application should implement this initialization seperately */
    uint16_t rtpEncSeed = RANDOM_INITSEED_ENC;
    uint32_t ssrc = ( (uint32_t) IVAS_RTP_OwnRandom( &rtpEncSeed ) & 0x0000FFFF ) | ( (uint32_t) IVAS_RTP_OwnRandom( &rtpEncSeed ) << 16 );
    uint16_t seqNumInitVal = IVAS_RTP_OwnRandom( &rtpEncSeed );
#else
    /* Ideally ssrc is negotiated via SDP and sequence number is radomized but we
       use fixed seed for random num generator for regression based tests. Any realtime
       application should implement this initialization seperately */
    srand( RANDOM_INITSEED_ENC );
    uint32_t ssrc = ( (uint32_t) rand() & 0x0000FFFF ) | ( (uint32_t) rand() << 16 );
    uint16_t seqNumInitVal = (uint16_t) ( rand() & 0xFFFF );
#endif

    /*------------------------------------------------------------------------------------------*
     * Parse command-line arguments
+0 −13
Original line number Diff line number Diff line
@@ -62,11 +62,7 @@ static
#endif
    int32_t frame = 0; /* Counter of frames */

#ifdef NONBE_FIX_BASOP_2233_RTPDUMP_DIFFERING_BITSTREAMS
#define RANDOM_INITSEED_ENC ( 0xDEAF )
#else
#define RANDOM_INITSEED_ENC ( 0xFEEDDEAF )
#endif

#define DEFAULT_FIXED_SID_RATE 8 /* DTX SID rate */

@@ -338,21 +334,12 @@ int encoder_main(
    uint8_t au[IVAS_MAX_BITS_PER_FRAME / 8];
    /* IVAS_RTP ivasRtp = { 0 }; */

#ifdef NONBE_FIX_BASOP_2233_RTPDUMP_DIFFERING_BITSTREAMS
    /* Ideally ssrc is negotiated via SDP and sequence number is radomized but we
       use fixed seed for random num generator for regression based tests. Any realtime
       application should implement this initialization seperately */
    uint16_t rtpEncSeed = RANDOM_INITSEED_ENC;
    uint32_t ssrc = ( (uint32_t) IVAS_RTP_OwnRandom( &rtpEncSeed ) & 0x0000FFFF ) | ( (uint32_t) IVAS_RTP_OwnRandom( &rtpEncSeed ) << 16 );
    uint16_t seqNumInitVal = IVAS_RTP_OwnRandom( &rtpEncSeed );
#else
    /* Ideally ssrc is negotiated via SDP and sequence number is radomized but we
       use fixed seed for random num generator for regression based tests. Any realtime
       application should implement this initialization seperately */
    srand( RANDOM_INITSEED_ENC );
    uint32_t ssrc = ( (uint32_t) rand() & 0x0000FFFF ) | ( (uint32_t) rand() << 16 );
    uint16_t seqNumInitVal = (uint16_t) ( rand() & 0xFFFF );
#endif

    /*------------------------------------------------------------------------------------------*
     * Parse command-line arguments
+0 −17
Original line number Diff line number Diff line
@@ -5409,20 +5409,3 @@ void evs_dec_previewFrame(

    return;
}
#ifndef NONBE_MDCT_ST_DTX_FIX_SUBOPT_SPATIAL_CNG

void dtx_read_padding_bits(
    DEC_CORE_HANDLE st,
    const int16_t num_bits )
{
    /* TODO: temporary hack, need to decide what to do with core-coder bitrate */
    int32_t tmp;

    tmp = st->total_brate;
    st->total_brate = st->total_brate + num_bits * FRAMES_PER_SEC;
    get_next_indice( st, num_bits );
    st->total_brate = tmp;

    return;
}
#endif
+0 −20
Original line number Diff line number Diff line
@@ -275,14 +275,9 @@ void edxt(
            {
                for ( k = Nm1 >> 1; k > 0; k-- )
                {
#ifdef NONBE_FIX_NONBE_BETWEEN_OPTIMIZATION_LEVELS_2
                    volatile float angle_tmp = scale * k;
                    const float wRe = cosf( angle_tmp );
                    const float wIm = sinf( angle_tmp );
#else
                    const float wRe = cosf( scale * k );
                    const float wIm = sinf( scale * k );
#endif

                    y[k] /*pt 1*/ = wRe * re[k] + wIm * im[k];
                    y[length - k] = wIm * re[k] - wRe * im[k];
@@ -293,14 +288,9 @@ void edxt(
            {
                for ( k = Nm1 >> 1; k > 0; k-- )
                {
#ifdef NONBE_FIX_NONBE_BETWEEN_OPTIMIZATION_LEVELS_2
                    volatile float angle_tmp = scale * k;
                    const float wRe = cosf( angle_tmp );
                    const float wIm = sinf( angle_tmp );
#else
                    const float wRe = cosf( scale * k );
                    const float wIm = sinf( scale * k );
#endif

                    y[Nm1 - k] = wRe * re[k] + wIm * im[k];
                    y[k - 1] = wIm * re[k] - wRe * im[k];
@@ -316,14 +306,9 @@ void edxt(
            {
                for ( k = Nm1 >> 1; k > 0; k-- )
                {
#ifdef NONBE_FIX_NONBE_BETWEEN_OPTIMIZATION_LEVELS_2
                    volatile float angle_tmp = scale * k;
                    const float wRe = cosf( angle_tmp ) * 0.5f;
                    const float wIm = sinf( angle_tmp ) * 0.5f;
#else
                    const float wRe = cosf( scale * k ) * 0.5f;
                    const float wIm = sinf( scale * k ) * 0.5f;
#endif

                    re[k] = wRe * x[k] + wIm * x[length - k];
                    im[k] = wRe * x[length - k] - wIm * x[k];
@@ -334,14 +319,9 @@ void edxt(
            {
                for ( k = Nm1 >> 1; k > 0; k-- )
                {
#ifdef NONBE_FIX_NONBE_BETWEEN_OPTIMIZATION_LEVELS_2
                    volatile float angle_tmp = scale * k;
                    const float wRe = cosf( angle_tmp ) * 0.5f;
                    const float wIm = sinf( angle_tmp ) * 0.5f;
#else
                    const float wRe = cosf( scale * k ) * 0.5f;
                    const float wIm = sinf( scale * k ) * 0.5f;
#endif

                    re[k] = wRe * x[Nm1 - k] + wIm * x[k - 1];
                    im[k] = wRe * x[k - 1] - wIm * x[Nm1 - k];
Loading