Changeset 91071 in vbox
- Timestamp:
- Sep 1, 2021 5:12:41 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DrvHostAudioValidationKit.cpp
r91068 r91071 125 125 /** Total number of bytes recorded since driver construction. */ 126 126 uint64_t cbRecordedTotal; 127 /** Total number of bytes silence was played in a consequtive block so far. 128 * Will be reset once audible data is being played (again). */ 129 uint64_t cbPlayedSilence; 130 /** Total number of bytes audio (audible or not) was played while no active 131 * audio test was registered / available. */ 132 uint64_t cbPlayedNoTest; 127 133 /** Temporary path to use. */ 128 134 char szPathTemp[RTPATH_MAX]; … … 842 848 if (pTst == NULL) /* Empty list? */ 843 849 { 844 #ifdef DEBUG_andy 845 if (!fIsSilence) 846 #endif 847 LogRel(("ValKit: Warning: Guest is playing back audio (%s, %RU32 bytes, %RU64ms) when no playback test is active\n", 848 fIsSilence ? "silence" : "audible", cbBuf, PDMAudioPropsBytesToMilli(&pStream->pStream->Cfg.Props, cbBuf))); 850 pThis->cbPlayedNoTest += cbBuf; 849 851 850 852 *pcbWritten = cbBuf; … … 852 854 } 853 855 854 #ifndef DEBUG_andy 856 if (pThis->cbPlayedNoTest) 857 { 858 LogRel(("ValKit: Warning: Guest was playing back audio (%s, %RU32 bytes, %RU64ms) when no playback test is active\n", 859 pThis->cbPlayedNoTest, PDMAudioPropsBytesToMilli(&pStream->pStream->Cfg.Props, pThis->cbPlayedNoTest))); 860 pThis->cbPlayedNoTest = 0; 861 } 862 855 863 if (fIsSilence) 856 LogRel2(("ValKit: Guest is playing back %RU32 bytes (%RU64ms) silence\n", 857 cbBuf, PDMAudioPropsBytesToMilli(&pStream->pStream->Cfg.Props, cbBuf))); 858 #endif 859 860 const bool fHandleSilence = false; /** @todo Skip blocks of entire silence for now. */ 864 { 865 pThis->cbPlayedSilence += cbBuf; 866 } 867 else /* Audible data */ 868 { 869 if (pThis->cbPlayedSilence) 870 LogRel(("ValKit: Guest was playing back %RU32 bytes (%RU64ms) of silence\n", 871 pThis->cbPlayedSilence, PDMAudioPropsBytesToMilli(&pStream->pStream->Cfg.Props, pThis->cbPlayedSilence))); 872 pThis->cbPlayedSilence = 0; 873 } 874 875 const bool fHandleSilence = true; 861 876 862 877 if (pTst->pEntry == NULL) /* Test not started yet? */ … … 1120 1135 pThis->cbPlayedTotal = 0; 1121 1136 pThis->cbRecordedTotal = 0; 1137 pThis->cbPlayedSilence = 0; 1138 pThis->cbPlayedNoTest = 0; 1122 1139 1123 1140 pThis->fTestSetEnd = false;
Note:
See TracChangeset
for help on using the changeset viewer.

