diff --git a/apps/decoder.c b/apps/decoder.c index b46b6db31ca4a1ba6199484c88b56e3db7bda34d..117180f83807c8022129468dc1029eda0f558853 100644 --- a/apps/decoder.c +++ b/apps/decoder.c @@ -152,7 +152,9 @@ typedef struct #endif uint16_t acousticEnvironmentId; uint16_t directivityPatternId[IVAS_MAX_NUM_OBJECTS]; - +#ifdef API_5MS + bool framing_5ms; +#endif } DecArguments; @@ -950,6 +952,9 @@ static bool parseCmdlIVAS_dec( arg->delayCompensationEnabled = true; arg->voipMode = false; arg->complexityLevel = IVAS_DEC_COMPLEXITY_LEVEL_THREE; +#ifdef API_5MS + arg->framing_5ms = false; +#endif arg->enableHeadRotation = false; arg->headrotTrajFileName = NULL; @@ -1196,6 +1201,14 @@ static bool parseCmdlIVAS_dec( arg->inputFormat = IVAS_DEC_INPUT_FORMAT_MIME; i++; } +#ifdef API_5MS + else if ( strcmp( argv_to_upper, "-FR5" ) == 0 ) + { + arg->framing_5ms = true; + fprintf( stderr, "Warning: this is a placeholder for 5ms framing.\n" ); + i++; + } +#endif else if ( strcmp( argv_to_upper, "-T" ) == 0 ) { arg->enableHeadRotation = true; @@ -1529,6 +1542,9 @@ static void usage_dec( void ) #ifdef DEBUG_JBM_CMD_OPTION fprintf( stdout, "-VOIP_framesize : VoIP mode: acoustic frontend fetch frame size (must be multiples of 5!)\n" ); #endif +#endif +#ifdef API_5MS + fprintf( stdout, "-fr5 : option to perform rendering + head-tracking with 5ms frame size\n" ); #endif fprintf( stdout, "-fec_cfg_file : Optimal channel aware configuration computed by the JBM \n" ); fprintf( stdout, " as described in Section 6.3.1 of TS26.448. The output is \n" ); diff --git a/apps/renderer.c b/apps/renderer.c index 91de00004d9bf5a51549243c87e7606906d7b27b..0bc791bda8e4d94f11c241b63c8910c014520846 100644 --- a/apps/renderer.c +++ b/apps/renderer.c @@ -185,6 +185,9 @@ typedef struct bool lfeCustomRoutingEnabled; char inLfePanningMatrixFile[RENDERER_MAX_CLI_ARG_LENGTH]; float syncMdDelay; +#ifdef API_5MS + bool framing_5ms; +#endif uint16_t directivityPatternId[RENDERER_MAX_ISM_INPUTS]; uint16_t acousticEnvironmentId; } CmdlnArgs; @@ -215,6 +218,9 @@ typedef enum #endif CmdLnOptionId_referenceVectorFile, CmdLnOptionId_exteriorOrientationFile, +#ifdef API_5MS + CmdLnOptionId_framing5ms, +#endif CmdLnOptionId_syncMdDelay, CmdLnOptionId_directivityPatternId, CmdLnOptionId_acousticEnvironmentId @@ -357,6 +363,14 @@ static const CmdLnParser_Option cliOptions[] = { .matchShort = "exof", .description = "External orientation trajectory file for simulation of external orientations", }, +#ifdef API_5MS + { + .id = CmdLnOptionId_framing5ms, + .match = "framing_5ms", + .matchShort = "fr5", + .description = "Render audio with 5 ms framing.", + }, +#endif { .id = CmdLnOptionId_syncMdDelay, .match = "sync_md_delay", @@ -2507,7 +2521,9 @@ static CmdlnArgs defaultArgs( args.lfeCustomRoutingEnabled = false; clearString( args.inLfePanningMatrixFile ); - +#ifdef API_5MS + args.framing_5ms = false; +#endif args.syncMdDelay = 0; for ( int32_t i = 0; i < RENDERER_MAX_ISM_INPUTS; ++i ) @@ -2655,7 +2671,13 @@ static void parseOption( exit( -1 ); } break; - +#ifdef API_5MS + case CmdLnOptionId_framing5ms: + assert( numOptionValues == 0 ); + args->framing_5ms = true; + fprintf( stderr, "Warning: this is a placeholder for 5ms framing.\n" ); + break; +#endif case CmdLnOptionId_directivityPatternId: assert( numOptionValues <= RENDERER_MAX_ISM_INPUTS ); for ( int16_t i = 0; i < numOptionValues; ++i ) diff --git a/lib_com/options.h b/lib_com/options.h index d295cb628e1b86405030486599bee8b1ee4963fa..1864d5672d15d89f98cdf8e9cee6bcebf295c0a9 100755 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -177,6 +177,7 @@ #define FIX_LARGE_RENDERER_DELAY_COMP /* Fix renderer delay compensation with delays greater than 1 frame */ +#define API_5MS /*FhG, Dlb: add 5ms framing cmd line arg*/ /* ################## End BE DEVELOPMENT switches ######################### */