VirtualBox

Changeset 73640 in vbox


Ignore:
Timestamp:
Aug 13, 2018 4:54:40 PM (6 years ago)
Author:
vboxsync
Message:

Audio/DrvAudio: Logging.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Audio/DrvAudio.cpp

    r73611 r73640  
    567567    /* Let the user know if the backend changed some of the tweakable values. */
    568568    if (CfgHostAcq.Backend.cfBufferSize != pCfgHost->Backend.cfBufferSize)
    569         LogRel2(("Audio: Backend changed buffer size from (%RU64ms, %RU32 frames) to (%RU64ms, %RU32 frames) frames\n",
     569        LogRel2(("Audio: Backend changed buffer size from %RU64ms (%RU32 frames) to %RU64ms (%RU32 frames)\n",
    570570                 DrvAudioHlpFramesToMilli(pCfgHost->Backend.cfBufferSize, &pCfgHost->Props), pCfgHost->Backend.cfBufferSize,
    571571                 DrvAudioHlpFramesToMilli(CfgHostAcq.Backend.cfBufferSize, &CfgHostAcq.Props), CfgHostAcq.Backend.cfBufferSize));
    572572
    573573    if (CfgHostAcq.Backend.cfPeriod != pCfgHost->Backend.cfPeriod)
    574         LogRel2(("Audio: Backend changed period size from (%RU64ms, %RU32 frames) to (%RU64ms, %RU32 frames) frames\n",
     574        LogRel2(("Audio: Backend changed period size from %RU64ms (%RU32 frames) to %RU64ms (%RU32 frames)\n",
    575575                 DrvAudioHlpFramesToMilli(pCfgHost->Backend.cfPeriod, &pCfgHost->Props), pCfgHost->Backend.cfPeriod,
    576576                 DrvAudioHlpFramesToMilli(CfgHostAcq.Backend.cfPeriod, &CfgHostAcq.Props), CfgHostAcq.Backend.cfPeriod));
    577577
    578578    if (CfgHostAcq.Backend.cfPreBuf != pCfgHost->Backend.cfPreBuf)
    579         LogRel2(("Audio: Backend changed pre-buffering size from (%RU64ms, %RU32 frames) to (%RU64ms, %RU32 frames) frames\n",
     579        LogRel2(("Audio: Backend changed pre-buffering size from %RU64ms (%RU32 frames) to %RU64ms (%RU32 frames)\n",
    580580                 DrvAudioHlpFramesToMilli(pCfgHost->Backend.cfPreBuf, &pCfgHost->Props), pCfgHost->Backend.cfPreBuf,
    581581                 DrvAudioHlpFramesToMilli(CfgHostAcq.Backend.cfPreBuf, &CfgHostAcq.Props), CfgHostAcq.Backend.cfPreBuf));
     
    639639
    640640    if (pCfgGuest->Device.uSchedulingHintMs)
    641         LogRel2(("Audio: Stream '%s' got a scheduling hint of %RU32ms\n", pStream->szName, pCfgGuest->Device.uSchedulingHintMs));
     641        LogRel2(("Audio: Stream '%s' got a scheduling hint of %RU32ms (%RU32 bytes)\n",
     642                 pStream->szName, pCfgGuest->Device.uSchedulingHintMs,
     643                 DrvAudioHlpMilliToBytes(pCfgGuest->Device.uSchedulingHintMs, &pCfgGuest->Props)));
    642644
    643645    /* Destroy any former mixing buffer. */
     
    13951397#ifdef LOG_ENABLED
    13961398    char *pszStreamSts = dbgAudioStreamStatusToStr(stsStream);
    1397     Log3Func(("[%s] Buffer: Start fStatus=%s\n", pStream->szName, pszStreamSts));
     1399    Log3Func(("[%s] Start fStatus=%s\n", pStream->szName, pszStreamSts));
    13981400    RTStrFree(pszStreamSts);
    13991401#endif /* LOG_ENABLED */
     
    14201422        pStream->tsLastPlayedCapturedNs = RTTimeNanoTS();
    14211423
    1422         Log3Func(("[%s] Buffer: Last played %RU64ns (%RU64ms), filled with %RU64ms (%RU8%%) total, "
     1424        Log3Func(("[%s] Last played %RU64ns (%RU64ms), filled with %RU64ms (%RU8%%) total, "
    14231425                  "(cfLive=%RU32, fThresholdReached=%RTbool)\n",
    14241426                  pStream->szName, tsDeltaPlayedCapturedNs, tsDeltaPlayedCapturedNs / RT_NS_1MS_64,
     
    14721474            }
    14731475
    1474             Log3Func(("[%s] Buffer: fJustStarted=%RTbool, cfLive=%RU32, cfToPlay=%RU32\n",
     1476            Log3Func(("[%s] fJustStarted=%RTbool, cfLive=%RU32, cfToPlay=%RU32\n",
    14751477                      pStream->szName, fJustStarted, cfLive, cfToPlay));
    14761478
     
    14831485                {
    14841486                    pStream->fThresholdReached = false;
    1485                     Log3Func(("[%s] Buffer: Underrun (cfLive=%RU32, cfToPlay=%RU32)\n", pStream->szName, cfLive, cfToPlay));
     1487                    Log3Func(("[%s] Warning: Buffer underrun (cfLive=%RU32, cfToPlay=%RU32)\n", pStream->szName, cfLive, cfToPlay));
    14861488                    LogRel2(("Audio: Stream '%s' buffer underrun (total %RU8%%, which is %RU8%% of a period), buffering ...\n",
    14871489                             pStream->szName, uLivePercent, (100 * cfLive) / pStream->Host.Cfg.Backend.cfPeriod));
     
    14981500            if (!fJustStarted)
    14991501                pStream->Out.Dbg.cbJitterWrittenPlayed -= AUDIOMIXBUF_F2B(&pStream->Host.MixBuf, cfToPlay);
    1500             Log3Func(("[%s] Buffer: Playing %RU32 frames (%RU64ms), now filled with %RU64ms -- %RU8%% (cbJitterWrittenPlayed=%RI64)\n",
     1502            Log3Func(("[%s] Playing %RU32 frames (%RU64ms), now filled with %RU64ms -- %RU8%% (cbJitterWrittenPlayed=%RI64)\n",
    15011503                      pStream->szName, cfToPlay, DrvAudioHlpFramesToMilli(cfToPlay, &pStream->Host.Cfg.Props),
    15021504                      DrvAudioHlpFramesToMilli(AudioMixBufUsed(&pStream->Host.MixBuf), &pStream->Host.Cfg.Props),
     
    15381540    uint32_t cfLive = AudioMixBufLive(&pStream->Host.MixBuf);
    15391541    pszStreamSts  = dbgAudioStreamStatusToStr(stsStream);
    1540     Log3Func(("[%s] Buffer: End fStatus=%s, cfLive=%RU32, cfPlayedTotal=%RU32, rc=%Rrc\n",
     1542    Log3Func(("[%s] End fStatus=%s, cfLive=%RU32, cfPlayedTotal=%RU32, rc=%Rrc\n",
    15411543              pStream->szName, pszStreamSts, cfLive, cfPlayedTotal, rc));
    15421544    RTStrFree(pszStreamSts);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette