Changeset 90047 in vbox
- Timestamp:
- Jul 6, 2021 9:05:41 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/AudioTest.cpp
r90046 r90047 1743 1743 * @returns VBox status code. 1744 1744 * @returns Error if the verification failed and test verification job has fKeepGoing not set. 1745 * @param pVer ifyVerification job to verify value for.1745 * @param pVerJob Verification job to verify value for. 1746 1746 * @param phObjA Object handle A to verify value for. 1747 1747 * @param phObjB Object handle B to verify value for. … … 1751 1751 * @param ... Variable aruments for error format string. 1752 1752 */ 1753 static int audioTestVerifyValue(PAUDIOTESTVERIFYJOB pVer ify,1753 static int audioTestVerifyValue(PAUDIOTESTVERIFYJOB pVerJob, 1754 1754 PAUDIOTESTOBJINT phObjA, PAUDIOTESTOBJINT phObjB, const char *pszKey, const char *pszVal, const char *pszErrFmt, ...) 1755 1755 { … … 1778 1778 if (RT_FAILURE(rc)) 1779 1779 { 1780 int rc2 = audioTestErrorDescAddV(pVer ify->pErr, pVerify->idxTest, rc, pszErrFmt, va);1780 int rc2 = audioTestErrorDescAddV(pVerJob->pErr, pVerJob->idxTest, rc, pszErrFmt, va); 1781 1781 AssertRC(rc2); 1782 1782 } … … 1784 1784 va_end(va); 1785 1785 1786 return pVer ify->fKeepGoing ? VINF_SUCCESS : rc;1786 return pVerJob->fKeepGoing ? VINF_SUCCESS : rc; 1787 1787 } 1788 1788 … … 2144 2144 * @returns Error if the verification failed and test verification job has fKeepGoing not set. 2145 2145 * @retval VERR_ 2146 * @param pVer ifyVerification job to verify test tone for.2146 * @param pVerJob Verification job to verify test tone for. 2147 2147 * @param phTestA Test handle of test tone A to verify tone B with. 2148 2148 * @param phTestB Test handle of test tone B to verify tone A with.* 2149 2149 */ 2150 static int audioTestVerifyTestTone(PAUDIOTESTVERIFYJOB pVer ify, PAUDIOTESTOBJINT phTestA, PAUDIOTESTOBJINT phTestB)2150 static int audioTestVerifyTestTone(PAUDIOTESTVERIFYJOB pVerJob, PAUDIOTESTOBJINT phTestA, PAUDIOTESTOBJINT phTestB) 2151 2151 { 2152 2152 int rc; … … 2156 2156 * More important items have precedence. 2157 2157 */ 2158 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "error_rc", "0", "Test was reported as failed");2159 CHECK_RC_MAYBE_RET(rc, pVer ify);2160 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "obj_count", NULL, "Object counts don't match");2161 CHECK_RC_MAYBE_RET(rc, pVer ify);2162 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_freq_hz", NULL, "Tone frequency doesn't match");2163 CHECK_RC_MAYBE_RET(rc, pVer ify);2164 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_prequel_ms", NULL, "Tone prequel (ms) doesn't match");2165 CHECK_RC_MAYBE_RET(rc, pVer ify);2166 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_duration_ms", NULL, "Tone duration (ms) doesn't match");2167 CHECK_RC_MAYBE_RET(rc, pVer ify);2168 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_sequel_ms", NULL, "Tone sequel (ms) doesn't match");2169 CHECK_RC_MAYBE_RET(rc, pVer ify);2170 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_volume_percent", NULL, "Tone volume (percent) doesn't match");2171 CHECK_RC_MAYBE_RET(rc, pVer ify);2172 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_pcm_hz", NULL, "Tone PCM Hz doesn't match");2173 CHECK_RC_MAYBE_RET(rc, pVer ify);2174 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_pcm_channels", NULL, "Tone PCM channels don't match");2175 CHECK_RC_MAYBE_RET(rc, pVer ify);2176 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_pcm_bits", NULL, "Tone PCM bits don't match");2177 CHECK_RC_MAYBE_RET(rc, pVer ify);2178 rc = audioTestVerifyValue(pVer ify, phTestA, phTestB, "tone_pcm_is_signed", NULL, "Tone PCM signed bit doesn't match");2179 CHECK_RC_MAYBE_RET(rc, pVer ify);2180 2181 rc = audioTestObjGetTonePcmProps(phTestA, &pVer ify->PCMProps);2182 CHECK_RC_MAYBE_RET(rc, pVer ify);2158 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "error_rc", "0", "Test was reported as failed"); 2159 CHECK_RC_MAYBE_RET(rc, pVerJob); 2160 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "obj_count", NULL, "Object counts don't match"); 2161 CHECK_RC_MAYBE_RET(rc, pVerJob); 2162 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_freq_hz", NULL, "Tone frequency doesn't match"); 2163 CHECK_RC_MAYBE_RET(rc, pVerJob); 2164 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_prequel_ms", NULL, "Tone prequel (ms) doesn't match"); 2165 CHECK_RC_MAYBE_RET(rc, pVerJob); 2166 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_duration_ms", NULL, "Tone duration (ms) doesn't match"); 2167 CHECK_RC_MAYBE_RET(rc, pVerJob); 2168 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_sequel_ms", NULL, "Tone sequel (ms) doesn't match"); 2169 CHECK_RC_MAYBE_RET(rc, pVerJob); 2170 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_volume_percent", NULL, "Tone volume (percent) doesn't match"); 2171 CHECK_RC_MAYBE_RET(rc, pVerJob); 2172 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_pcm_hz", NULL, "Tone PCM Hz doesn't match"); 2173 CHECK_RC_MAYBE_RET(rc, pVerJob); 2174 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_pcm_channels", NULL, "Tone PCM channels don't match"); 2175 CHECK_RC_MAYBE_RET(rc, pVerJob); 2176 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_pcm_bits", NULL, "Tone PCM bits don't match"); 2177 CHECK_RC_MAYBE_RET(rc, pVerJob); 2178 rc = audioTestVerifyValue(pVerJob, phTestA, phTestB, "tone_pcm_is_signed", NULL, "Tone PCM signed bit doesn't match"); 2179 CHECK_RC_MAYBE_RET(rc, pVerJob); 2180 2181 rc = audioTestObjGetTonePcmProps(phTestA, &pVerJob->PCMProps); 2182 CHECK_RC_MAYBE_RET(rc, pVerJob); 2183 2183 2184 2184 /* 2185 2185 * Now the fun stuff, PCM data analysis. 2186 2186 */ 2187 rc = audioTestVerifyTestToneData(pVer ify, phTestA, phTestB);2187 rc = audioTestVerifyTestToneData(pVerJob, phTestA, phTestB); 2188 2188 if (RT_FAILURE(rc)) 2189 2189 { 2190 int rc2 = audioTestErrorDescAddError(pVer ify->pErr, pVerify->idxTest, "Verififcation of test tone data failed\n");2190 int rc2 = audioTestErrorDescAddError(pVerJob->pErr, pVerJob->idxTest, "Verififcation of test tone data failed\n"); 2191 2191 AssertRC(rc2); 2192 2192 }
Note:
See TracChangeset
for help on using the changeset viewer.