Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function GetLineState(device as DeviceControl, dwControlID as DWORD) as DWORD
- with device
- Dim as MIXERCONTROLDETAILS mxcd
- mxcd.dwControlID = dwControlID ' control ID
- mxcd.cChannels = 1 ' Apply volume uniformly to all channels
- mxcd.cMultipleItems = 0 ' Only setting one value
- ' Control status returned in this struct
- Dim as MIXERCONTROLDETAILS_UNSIGNED details
- mxcd.paDetails = @details
- mxcd.cbDetails = sizeof(details)
- mxcd.cbStruct = sizeof(MIXERCONTROLDETAILS)
- '|| Crash ||
- 'vv Here vv
- var result = mixerGetControlDetails(cast(HMIXEROBJ, .hMixer), @mxcd, MIXER_SETCONTROLDETAILSF_VALUE)
- if (result <> MMSYSERR_NOERROR) then
- print "Error #"; result; " getting line info for "; .szName
- end if
- return details.dwValue ' Return line control value
- end with
- end function
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement