Changeset 87438 in vbox
- Timestamp:
- Jan 26, 2021 5:10:09 PM (4 years ago)
- Location:
- trunk/src/VBox/Devices/Audio
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DrvAudio.h
r87436 r87438 195 195 uint32_t DrvAudioHlpCalcBitrate(uint8_t cBits, uint32_t uHz, uint8_t cChannels); 196 196 uint32_t DrvAudioHlpCalcBitrate(const PPDMAUDIOPCMPROPS pProps); 197 uint32_t DrvAudioHlpBytesAlign( size_t cbSize, const PPDMAUDIOPCMPROPS pProps);198 bool DrvAudioHlpBytesIsAligned( size_t cbSize, const PPDMAUDIOPCMPROPS pProps);197 uint32_t DrvAudioHlpBytesAlign(uint32_t cbSize, const PPDMAUDIOPCMPROPS pProps); 198 bool DrvAudioHlpBytesIsAligned(uint32_t cbSize, const PPDMAUDIOPCMPROPS pProps); 199 199 uint32_t DrvAudioHlpBytesToFrames(uint32_t cbBytes, const PPDMAUDIOPCMPROPS pProps); 200 200 uint64_t DrvAudioHlpBytesToMilli(uint32_t cbBytes, const PPDMAUDIOPCMPROPS pProps); -
trunk/src/VBox/Devices/Audio/DrvAudioCommon.cpp
r87436 r87438 1181 1181 * @param pProps PCM properties to align size to. 1182 1182 */ 1183 uint32_t DrvAudioHlpBytesAlign( size_t cbSize, const PPDMAUDIOPCMPROPS pProps)1183 uint32_t DrvAudioHlpBytesAlign(uint32_t cbSize, const PPDMAUDIOPCMPROPS pProps) 1184 1184 { 1185 1185 AssertPtrReturn(pProps, 0); … … 1198 1198 * @param pProps PCM properties to use for checking the alignment. 1199 1199 */ 1200 bool DrvAudioHlpBytesIsAligned( size_t cbSize, const PPDMAUDIOPCMPROPS pProps)1200 bool DrvAudioHlpBytesIsAligned(uint32_t cbSize, const PPDMAUDIOPCMPROPS pProps) 1201 1201 { 1202 1202 AssertPtrReturn(pProps, 0); -
trunk/src/VBox/Devices/Audio/HDAStream.cpp
r87436 r87438 361 361 } 362 362 363 const size_t cbCircBufDefault = DrvAudioHlpMilliToBytes(RT_MS_1SEC, &pCfg->Props);364 365 size_t cbCircBuf = DrvAudioHlpMilliToBytes( hdaGetDirFromSD(uSD) == PDMAUDIODIR_IN366 ? pThis->cbCircBufInMs : pThis->cbCircBufOutMs, &pCfg->Props);363 const uint32_t cbCircBufDefault = DrvAudioHlpMilliToBytes(RT_MS_1SEC, &pCfg->Props); 364 365 uint32_t cbCircBuf = DrvAudioHlpMilliToBytes( hdaGetDirFromSD(uSD) == PDMAUDIODIR_IN 366 ? pThis->cbCircBufInMs : pThis->cbCircBufOutMs, &pCfg->Props); 367 367 368 368 ASSERT_GUEST_LOGREL_MSG_STMT(cbCircBuf, … … 374 374 375 375 if (cbCircBuf != cbCircBufDefault) 376 LogRel2(("HDA: Stream #%RU8 is using a custom ring buffer size of %RU64ms (% zubytes)\n",376 LogRel2(("HDA: Stream #%RU8 is using a custom ring buffer size of %RU64ms (%RU32 bytes)\n", 377 377 uSD, DrvAudioHlpBytesToMilli(cbCircBuf, &pCfg->Props), cbCircBuf)); 378 378
Note:
See TracChangeset
for help on using the changeset viewer.