Changeset 92439 in vbox for trunk/src/VBox/ValidationKit/utils/audio/vkatCmdSelfTest.cpp
- Timestamp:
- Nov 15, 2021 6:56:32 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/utils/audio/vkatCmdSelfTest.cpp
r92051 r92439 69 69 /** Common tag for guest and host side. */ 70 70 char szTag[AUDIOTEST_TAG_MAX]; 71 /** Whether to use DrvAudio in the driver stack or not. */ 72 bool fWithDrvAudio; 71 /** The driver stack in use. */ 73 72 AUDIOTESTDRVSTACK DrvStack; 74 73 /** Audio driver to use. … … 332 331 { "--backend", 'b', RTGETOPT_REQ_STRING }, 333 332 { "--with-drv-audio", 'd', RTGETOPT_REQ_NOTHING }, 333 { "--with-mixer", 'm', RTGETOPT_REQ_NOTHING }, 334 334 { "--exclude", 'e', RTGETOPT_REQ_UINT32 }, 335 335 { "--include", 'i', RTGETOPT_REQ_UINT32 } … … 346 346 case 'e': return "Exclude the given test id from the list"; 347 347 case 'i': return "Include the given test id in the list"; 348 case 'm': return "Use the internal mixing engine explicitly"; 348 349 default: return NULL; 349 350 } … … 359 360 { 360 361 RT_ZERO(g_Ctx); 362 363 audioTestEnvInit(&g_Ctx.Guest.TstEnv); 364 audioTestEnvInit(&g_Ctx.Host.TstEnv); 365 366 AUDIOTESTIOOPTS IoOpts; 367 audioTestIoOptsInitDefaults(&IoOpts); 361 368 362 369 /* Argument processing loop: */ … … 379 386 380 387 case 'd': 381 g_Ctx.fWithDrvAudio = true;388 IoOpts.fWithDrvAudio = true; 382 389 break; 383 390 … … 394 401 break; 395 402 403 case 'm': 404 IoOpts.fWithMixer = true; 405 break; 406 396 407 AUDIO_TEST_COMMON_OPTION_CASES(ValueUnion); 397 408 … … 400 411 } 401 412 } 413 414 /* For simplicity both test environments, guest and host, will have the same I/O options. 415 ** @todo Make this indepedent by a prefix, "--[guest|host]-<option>" -> e.g. "--guest-with-drv-audio". */ 416 memcpy(&g_Ctx.Guest.TstEnv.IoOpts, &IoOpts, sizeof(AUDIOTESTIOOPTS)); 417 memcpy(&g_Ctx.Host.TstEnv.IoOpts, &IoOpts, sizeof(AUDIOTESTIOOPTS)); 402 418 403 419 rc = AudioTestDriverStackPerformSelftest(); … … 419 435 */ 420 436 rc = audioTestDriverStackInitEx(&g_Ctx.DrvStack, g_Ctx.pDrvReg, 421 true /* fEnabledIn */, true /* fEnabledOut */, g_Ctx. fWithDrvAudio);437 true /* fEnabledIn */, true /* fEnabledOut */, g_Ctx.Host.TstEnv.IoOpts.fWithDrvAudio); 422 438 if (RT_FAILURE(rc)) 423 439 return RTMsgErrorExit(RTEXITCODE_SYNTAX, "Unable to init driver stack: %Rrc\n", rc);
Note:
See TracChangeset
for help on using the changeset viewer.