![]() |
Herausfinden ob Sound "gemuted" ist?
Hi!
Irgendwo hier hab ich einen Codeschnipsel gefunden um die Lautstärke zu steuern - wo weiß ich grade net mehr. Dabei ist auch eine Funktion, mit der man herausfinden kann, ob die Lautstärke "gemuted" ist:
Delphi-Quellcode:
Aber ich hab leider keine Ahnung was die Funktion übergeben haben will - kann mir jemand helfen?
function GetMasterMute(
Mixer: hMixerObj; var Control: TMixerControl): MMResult; // Returns True on success var Line: TMixerLine; Controls: TMixerLineControls; begin ZeroMemory(@Line, SizeOf(Line)); Line.cbStruct := SizeOf(Line); Line.dwComponentType := MIXERLINE_COMPONENTTYPE_DST_SPEAKERS; Result := mixerGetLineInfo(Mixer, @Line, MIXER_GETLINEINFOF_COMPONENTTYPE); if Result = MMSYSERR_NOERROR then begin ZeroMemory(@Controls, SizeOf(Controls)); Controls.cbStruct := SizeOf(Controls); Controls.dwLineID := Line.dwLineID; Controls.cControls := 1; Controls.dwControlType := MIXERCONTROL_CONTROLTYPE_MUTE; Controls.cbmxctrl := SizeOf(Control); Controls.pamxctrl := @Control; Result := mixerGetLineControls(Mixer, @Controls, MIXER_GETLINECONTROLSF_ONEBYTYPE); end; end; Danke schonmal! Lamy |
Re: Herausfinden ob Sound "gemuted" ist?
Der Aufruf geht so:
Delphi-Quellcode:
var
MasterMute: TMixerControl; Code: MMResult; begin Code := GetMasterMute(0, MasterMute); |
Alle Zeitangaben in WEZ +1. Es ist jetzt 07:37 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz