Commit cd639983 authored by sagnowski's avatar sagnowski
Browse files

Fix build errors

parent 7f5b4f63
Loading
Loading
Loading
Loading
Loading
+1 −6
Original line number Diff line number Diff line
@@ -2048,12 +2048,7 @@ static ivas_error decodeG192(
                    goto cleanup;
                }
            }
            error = IVAS_DEC_GetSamples( hIvasDec, nSamplesToRender, pcmBuf + nOutChannels * nSamplesRendered, &nSamplesRendered_loop, &needNewFrame
#ifdef SPLIT_REND_WITH_HEAD_ROT
    ,
    NULL /* TODO(sgi): pass IVAS_SPLIT_REND_BITS_HANDLE or change API so that split rendering has its dedicated GetSamples function */
#endif
             );
            error = IVAS_DEC_GetSamples( hIvasDec, nSamplesToRender, pcmBuf + nOutChannels * nSamplesRendered, &nSamplesRendered_loop, &needNewFrame );
            nSamplesRendered += nSamplesRendered_loop;
            nSamplesToRender -= nSamplesRendered_loop;
            if ( error != IVAS_ERR_OK )
+1 −6
Original line number Diff line number Diff line
@@ -2353,12 +2353,7 @@ ivas_error IVAS_DEC_VoIP_GetSamples(
            nSamplesToRender = nSamplesPerChannel - nSamplesRendered;

            /* render IVAS frames  directly to the output buffer */
            if ( ( error = IVAS_DEC_GetSamples( hIvasDec, nSamplesToRender, pcmBuf + nSamplesRendered * nOutChannels, &nSamplesRendered_loop, &tmp
#ifdef SPLIT_REND_WITH_HEAD_ROT
    ,
    NULL /* TODO(sgi): pass hSplitRendBits here or create separate get samples function for split rendering */
#endif
            ) ) != IVAS_ERR_OK )
            if ( ( error = IVAS_DEC_GetSamples( hIvasDec, nSamplesToRender, pcmBuf + nSamplesRendered * nOutChannels, &nSamplesRendered_loop, &tmp ) ) != IVAS_ERR_OK )
            {
                return error;
            }
+4 −0
Original line number Diff line number Diff line
@@ -1513,7 +1513,11 @@ ivas_error ivas_renderMultiBinToSplitBinaural(

void ivas_rend_CldfbSplitPreRendProcess(
    const BIN_HR_SPLIT_PRE_REND_HANDLE hBinHrSplitPreRend,
#ifdef API_5MS
	const IVAS_QUATERNION headPosition,
#else
	const IVAS_QUATERNION headPositions[MAX_PARAM_SPATIAL_SUBFRAMES],
#endif
    MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData,
    float Cldfb_In_BinReal[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
    float Cldfb_In_BinImag[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
+32 −1
Original line number Diff line number Diff line
@@ -1037,7 +1037,11 @@ static void ivas_SplitRenderer_code_md_huff(

static void ivas_SplitRenderer_quant_code(
    const BIN_HR_SPLIT_PRE_REND_HANDLE hBinHrSplitPreRend,
#ifdef API_5MS
    const IVAS_QUATERNION headPosition,
#else
    const IVAS_QUATERNION headPositions[MAX_PARAM_SPATIAL_SUBFRAMES],
#endif
    MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData,
    ivas_split_rend_bits_t *pBits,
    const int16_t low_res_pre_rend_rot,
@@ -1072,7 +1076,12 @@ static void ivas_SplitRenderer_quant_code(
    {
        int16_t angle;
        IVAS_QUATERNION head_pos_euler;
#ifdef API_5MS
        /* FhG@Dolby: please review, this can be likely optimised */
        Quat2EulerDegree( headPosition, &head_pos_euler.z, &head_pos_euler.y, &head_pos_euler.x );
#else
        Quat2EulerDegree( headPositions[sf_idx], &head_pos_euler.z, &head_pos_euler.y, &head_pos_euler.x );
#endif
        angle = (int16_t) roundf( head_pos_euler.x );
        angle += 180;
        ivas_split_rend_bitstream_write_int32( pBits, angle, IVAS_SPLIT_REND_HEAD_POSE_BITS );
@@ -1395,7 +1404,11 @@ void ivas_SplitRenderer_GetRotMd(

void ivas_rend_CldfbSplitPreRendProcess(
    const BIN_HR_SPLIT_PRE_REND_HANDLE hBinHrSplitPreRend,
#ifdef API_5MS
    const IVAS_QUATERNION headPosition,
#else
    const IVAS_QUATERNION headPositions[MAX_PARAM_SPATIAL_SUBFRAMES],
#endif
    MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData,
    float Cldfb_In_BinReal[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
    float Cldfb_In_BinImag[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
@@ -1414,7 +1427,11 @@ void ivas_rend_CldfbSplitPreRendProcess(

    ivas_SplitRenderer_quant_code(
        hBinHrSplitPreRend,
#ifdef API_5MS
        headPosition,
#else
        headPositions,
#endif
        pMultiBinPoseData,
        pBits,
        low_res_pre_rend_rot,
@@ -1992,7 +2009,11 @@ static ivas_error ivas_renderMultiTDBinToSplitBinaural(
        actual_md_bits = pBits->bits_written;
        ivas_rend_CldfbSplitPreRendProcess(
            hSplitBin->hBinHrSplitPreRend,
#ifdef API_5MS
            headPosition,
#else
            headPositions,
#endif
            &hSplitBin->multiBinPoseData,
            Cldfb_In_BinReal,
            Cldfb_In_BinImag,
@@ -2134,7 +2155,13 @@ ivas_error ivas_renderMultiBinToSplitBinaural(
    {
        /*TD input*/
        /*if CLDFB handles have been allocated then assume valid multi binaural input in out[][] buffer and perform CLDFB analysis*/
        error = ivas_renderMultiTDBinToSplitBinaural( hSplitBin, headPositions, SplitRendBitRate, pBits, max_bands, out,
        error = ivas_renderMultiTDBinToSplitBinaural( hSplitBin,
#ifdef API_5MS
        headPosition,
#else
        headPositions,
#endif
        SplitRendBitRate, pBits, max_bands, out,
                                                      low_res_pre_rend_rot, pcm_out );
        pop_wmops();
        return error;
@@ -2153,7 +2180,11 @@ ivas_error ivas_renderMultiBinToSplitBinaural(
        actual_md_bits = pBits->bits_written;
        ivas_rend_CldfbSplitPreRendProcess(
            hSplitBin->hBinHrSplitPreRend,
#ifdef API_5MS
            headPosition,
#else
            headPositions,
#endif
            &hSplitBin->multiBinPoseData,
            Cldfb_In_BinReal,
            Cldfb_In_BinImag,
+2 −9
Original line number Diff line number Diff line
@@ -314,24 +314,17 @@ void ivas_split_rend_bitstream_write_int32( ivas_split_rend_bits_t *pBits, int32
    return;
}

#ifndef API_5MS
IVAS_QUATERNION ivas_split_rend_get_sf_rot_data(
#ifdef API_5MS
    const IVAS_QUATERNION headPositions[1],
#else
    const IVAS_QUATERNION headPositions[RENDERER_HEAD_POSITIONS_PER_FRAME],
#endif
    int16_t subframe_idx )
{
    int16_t idx;

#ifdef API_5MS
    /* TODO(splitrend): we no longer use subframes. Needs refactoring */
    idx = 0 * subframe_idx; /* tmp change */
#else
    idx = ( subframe_idx * RENDERER_HEAD_POSITIONS_PER_FRAME ) / MAX_PARAM_SPATIAL_SUBFRAMES;
#endif
    return headPositions[idx];
}
#endif


#ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG
Loading