Changeset 54974 in vbox
- Timestamp:
- Mar 26, 2015 7:10:45 PM (10 years ago)
- File:
-
- 1 edited
-
trunk/src/VBox/Devices/Audio/DrvAudio.cpp (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DrvAudio.cpp
r54969 r54974 619 619 * Try figuring out which audio stream configuration this backend 620 620 * should use. If fixed output is enabled the backend will be tied 621 * to a fixed rate in (Hz), regardless of what the backend could do else. 621 * to a fixed rate (in Hz, among other parameters), regardless of 622 * what the backend could do else. 622 623 */ 623 624 PPDMAUDIOSTREAMCFG pBackendCfg; … … 679 680 AssertPtrReturn(pszName, VERR_INVALID_POINTER); 680 681 681 PPDMAUDIOSTREAMCFG pThisCfg; 682 /* 683 * Try figuring out which audio stream configuration this backend 684 * should use for the audio input data. If fixed input is enabled 685 * the backend will be tied to a fixed rate (in Hz, among other parameters), 686 * regardless of what the backend initially wanted to use. 687 */ 688 PPDMAUDIOSTREAMCFG pBackendCfg; 682 689 if (conf.fixed_in.enabled) 683 { 684 pThisCfg = &conf.fixed_in.settings; 685 LogFlowFunc(("Using fixed audio settings\n")); 686 } 690 pBackendCfg = &conf.fixed_in.settings; 687 691 else 688 pThisCfg = pCfg; 689 AssertPtrReturn(pThisCfg, VERR_INVALID_POINTER); 692 pBackendCfg = pCfg; 693 694 AssertPtrReturn(pBackendCfg, VERR_INVALID_POINTER); 695 696 LogFlowFunc(("Using fixed audio input settings: %RTbool\n", 697 RT_BOOL(conf.fixed_in.enabled))); 690 698 691 699 PPDMAUDIOGSTSTRMIN pGstStrmIn = (PPDMAUDIOGSTSTRMIN)RTMemAllocZ(sizeof(PDMAUDIOGSTSTRMIN)); … … 693 701 return VERR_NO_MEMORY; 694 702 695 703 /* 704 * The host stream always will get the backend audio stream configuration. 705 */ 696 706 PPDMAUDIOHSTSTRMIN pHstStrmIn; 697 int rc = drvAudioHstInAdd(pThis, pszName, p ThisCfg, enmRecSource, &pHstStrmIn);707 int rc = drvAudioHstInAdd(pThis, pszName, pBackendCfg, enmRecSource, &pHstStrmIn); 698 708 if (RT_FAILURE(rc)) 699 709 { … … 704 714 } 705 715 706 rc = drvAudioGstInInit(pGstStrmIn, pHstStrmIn, pszName, pThisCfg); 716 /* 717 * The guest stream always will get the audio stream configuration told 718 * by the device emulation (which in turn was/could be set by the guest OS). 719 */ 720 rc = drvAudioGstInInit(pGstStrmIn, pHstStrmIn, pszName, pCfg); 707 721 if (RT_SUCCESS(rc)) 708 722 { … … 744 758 return VERR_NO_MEMORY; 745 759 746 rc = audioMixBufInit(&pGstStrmIn->MixBuf, pszTemp, &p HstStrmIn->Props,760 rc = audioMixBufInit(&pGstStrmIn->MixBuf, pszTemp, &pGstStrmIn->Props, 747 761 audioMixBufSize(&pHstStrmIn->MixBuf)); 748 762 if (RT_SUCCESS(rc))
Note:
See TracChangeset
for help on using the changeset viewer.

