Changeset 61417 in vbox for trunk/src/VBox/Devices/Audio
- Timestamp:
- Jun 2, 2016 4:16:21 PM (9 years ago)
- svn:sync-xref-src-repo-rev:
- 107734
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevIchHda.cpp
r61386 r61417 1751 1751 } 1752 1752 1753 static int hdaStreamSetActive(PHDASTATE pThis, PHDASTREAM pStream, bool fActive)1753 static bool hdaStreamIsActive(PHDASTATE pThis, PHDASTREAM pStream) 1754 1754 { 1755 1755 AssertPtrReturn(pThis, VERR_INVALID_POINTER); 1756 1756 AssertPtrReturn(pStream, VERR_INVALID_POINTER); 1757 1757 1758 bool fActive = false; 1759 1760 AssertPtr(pStream->pMixSink); 1761 if (pStream->pMixSink->pMixSink) 1762 fActive = AudioMixerSinkHasData(pStream->pMixSink->pMixSink); 1763 1764 LogFlowFunc(("SD=%RU8, fActive=%RTbool\n", pStream->u8SD, fActive)); 1765 return fActive; 1766 } 1767 1768 static int hdaStreamSetActive(PHDASTATE pThis, PHDASTREAM pStream, bool fActive) 1769 { 1770 AssertPtrReturn(pThis, VERR_INVALID_POINTER); 1771 AssertPtrReturn(pStream, VERR_INVALID_POINTER); 1772 1773 if (!pStream->pMixSink) /* No mixer sink assigned? Bail out early. */ 1774 { 1775 LogFlowFunc(("u8Strm=%RU8 has no mixer sink assigned\n", pStream->u8SD)); 1776 return VINF_SUCCESS; 1777 } 1778 1758 1779 AUDMIXSINKCMD enmCmd = fActive 1759 1780 ? AUDMIXSINKCMD_ENABLE : AUDMIXSINKCMD_DISABLE; 1760 1781 1761 1782 /* First, enable or disable the stream's sink, if any. */ 1762 AssertPtr(pStream->pMixSink);1763 1783 if (pStream->pMixSink->pMixSink) 1764 1784 AudioMixerSinkCtl(pStream->pMixSink->pMixSink, enmCmd); … … 1783 1803 1784 1804 LogFlowFunc(("u8Strm=%RU8, fActive=%RTbool, cStreamsActive=%RU8\n", pStream->u8SD, fActive, pThis->cStreamsActive)); 1785 1786 1805 return VINF_SUCCESS; 1787 1806 } … … 3943 3962 Assert(uSD < HDA_MAX_STREAMS); 3944 3963 3945 PHDASTREAM pStream = hdaStreamFromSD(pThis, pSink->uSD);3964 PHDASTREAM pStream = hdaStreamFromSD(pThis, uSD); 3946 3965 if (pStream) 3947 3966 {
Note:
See TracChangeset
for help on using the changeset viewer.