wiredbits Posted February 11, 2006 Posted February 11, 2006 hi I needed a routine that would select input line and after searching I found the mixer device API calls which suited my needs,. for fun I also did a set volume routine. Most of the info came from :http://www.borg.com/~jglatt/tech/mixer.htm and of course http://msdn.microsoft.com/library/default....troldetails.asp Since I have two sound cards im my system I wrote the routines to handle mulitible mixer devices. You will need the latest betta to run and both routines need the include file. MXSelectInputSrc_include.au3MXSelectInputSrc.au3MXVolume.au3
GaryFrost Posted February 12, 2006 Posted February 12, 2006 Good job SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
wiredbits Posted February 12, 2006 Author Posted February 12, 2006 Good job Thanks It was fun and gives me a starting place in case i want to use more than just two controls, plus i like watching the mixer change while i play with its widgets... Code could be cleaned up, I need to write a routine that grabs defines in a .h file and converts them to Autoit format. Would make life easier for me, hmmm maybe then go back and scan autoit code and make another file with only defines used.Jim
n9mfk9 Posted October 30, 2006 Posted October 30, 2006 hi I needed a routine that would select input line and after searching I found the mixer device API calls which suited my needs,. for fun I also did a set volume routine. Most of the info came from : http://www.borg.com/~jglatt/tech/mixer.htm and of course http://msdn.microsoft.com/library/default....troldetails.asp Since I have two sound cards im my system I wrote the routines to handle mulitible mixer devices. You will need the latest betta to run and both routines need the include file. MXSelectInputSrc_include.au3 MXSelectInputSrc.au3 MXVolume.au3Hi Jim do you have the code for a line in slider thanks beau
GaryFrost Posted November 7, 2006 Posted November 7, 2006 Thought this was worth putting here being 99% of the code is wiredbitshttp://www.autoitscript.com/fileman/users/gafrost/projects/Mixer/Mixer.au3#include <Mixer.au3> _SetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_SPEAKERS, 75) ConsoleWrite("DST" & @LF) ConsoleWrite("Digital: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_DIGITAL) & @LF) ConsoleWrite("Line: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_LINE) & @LF) ConsoleWrite("Monitor: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_MONITOR) & @LF) ConsoleWrite("Speakers: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_SPEAKERS) & @LF) ConsoleWrite("HeadPhones: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_HEADPHONES) & @LF) ConsoleWrite("Phone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_TELEPHONE) & @LF) ConsoleWrite("WaveIn: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_WAVEIN) & @LF) ConsoleWrite("VoiceIn: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_VOICEIN) & @LF) ConsoleWrite(@LF & "SRC" & @LF) ConsoleWrite("Digital: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_DIGITAL) & @LF) ConsoleWrite("Line: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_LINE) & @LF) ConsoleWrite("Microphone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE) & @LF) ConsoleWrite("Synthesizer: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_SYNTHESIZER) & @LF) ConsoleWrite("CompactDisc: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_COMPACTDISC) & @LF) ConsoleWrite("Phone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_TELEPHONE) & @LF) ConsoleWrite("PcSpeaker: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_PCSPEAKER) & @LF) ConsoleWrite("WaveOut: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_WAVEOUT) & @LF) ConsoleWrite("Aux: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_AUXILIARY) & @LF) ConsoleWrite("Analog: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_ANALOG) & @LF) SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
Thatsgreat2345 Posted November 8, 2006 Posted November 8, 2006 wow finally someone that doesn't post spam when they have a low post account you have made my day, will try the script later sounds cool though
GaryFrost Posted November 8, 2006 Posted November 8, 2006 wow finally someone that doesn't post spam when they have a low post account you have made my day, will try the script later sounds cool though I'm going to guess your talking about wiredbits who post this several months ago. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
Thatsgreat2345 Posted November 8, 2006 Posted November 8, 2006 I'm going to guess your talking about wiredbits who post this several months ago. woops didnt see how far back that was ahahah nvm old noob that doesnt come to the forums anymore
n9mfk9 Posted November 9, 2006 Posted November 9, 2006 iHi gafrost i have saved your code an can not get it to run do yoy have it in a zip file thanks Thought this was worth putting here being 99% of the code is wiredbits http://www.autoitscript.com/fileman/users/gafrost/projects/Mixer/Mixer.au3 #include <Mixer.au3> _SetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_SPEAKERS, 75) ConsoleWrite("DST" & @LF) ConsoleWrite("Digital: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_DIGITAL) & @LF) ConsoleWrite("Line: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_LINE) & @LF) ConsoleWrite("Monitor: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_MONITOR) & @LF) ConsoleWrite("Speakers: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_SPEAKERS) & @LF) ConsoleWrite("HeadPhones: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_HEADPHONES) & @LF) ConsoleWrite("Phone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_TELEPHONE) & @LF) ConsoleWrite("WaveIn: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_WAVEIN) & @LF) ConsoleWrite("VoiceIn: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_VOICEIN) & @LF) ConsoleWrite(@LF & "SRC" & @LF) ConsoleWrite("Digital: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_DIGITAL) & @LF) ConsoleWrite("Line: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_LINE) & @LF) ConsoleWrite("Microphone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE) & @LF) ConsoleWrite("Synthesizer: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_SYNTHESIZER) & @LF) ConsoleWrite("CompactDisc: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_COMPACTDISC) & @LF) ConsoleWrite("Phone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_TELEPHONE) & @LF) ConsoleWrite("PcSpeaker: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_PCSPEAKER) & @LF) ConsoleWrite("WaveOut: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_WAVEOUT) & @LF) ConsoleWrite("Aux: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_AUXILIARY) & @LF) ConsoleWrite("Analog: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_ANALOG) & @LF)
GaryFrost Posted November 9, 2006 Posted November 9, 2006 iHi gafrost i have saved your code an can not get it to run do yoy have it in a zip file thanksNo, no need to complicate a simple au3 file by zipping it.Just save the Mixer.au3 to a folder.Create another au3 file in that folder and copy/paste the code above and run. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
n9mfk9 Posted November 9, 2006 Posted November 9, 2006 No, no need to complicate a simple au3 file by zipping it.Just save the Mixer.au3 to a folder.Create another au3 file in that folder and copy/paste the code above and run.ok I made two file one is mixer.au3the i put this in mixer1.au3#include <Mixer.au3>_SetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_SPEAKERS, 75)ConsoleWrite("DST" & @LF)ConsoleWrite("Digital: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_DIGITAL) & @LF)ConsoleWrite("Line: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_LINE) & @LF)ConsoleWrite("Monitor: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_MONITOR) & @LF)ConsoleWrite("Speakers: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_SPEAKERS) & @LF)ConsoleWrite("HeadPhones: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_HEADPHONES) & @LF)ConsoleWrite("Phone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_TELEPHONE) & @LF)ConsoleWrite("WaveIn: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_WAVEIN) & @LF)ConsoleWrite("VoiceIn: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_DST_VOICEIN) & @LF)ConsoleWrite(@LF & "SRC" & @LF)ConsoleWrite("Digital: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_DIGITAL) & @LF)ConsoleWrite("Line: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_LINE) & @LF)ConsoleWrite("Microphone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE) & @LF)ConsoleWrite("Synthesizer: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_SYNTHESIZER) & @LF)ConsoleWrite("CompactDisc: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_COMPACTDISC) & @LF)ConsoleWrite("Phone: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_TELEPHONE) & @LF)ConsoleWrite("PcSpeaker: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_PCSPEAKER) & @LF)ConsoleWrite("WaveOut: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_WAVEOUT) & @LF)ConsoleWrite("Aux: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_AUXILIARY) & @LF)ConsoleWrite("Analog: " & _GetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_ANALOG) & @LF) but when I click it it did nothing what verison did you use thanks beau
GaryFrost Posted November 9, 2006 Posted November 9, 2006 ok I made two file one is mixer.au3the i put this in mixer1.au3but when I click it it did nothing what verison did you use thanks beauI use release and/or beta both work.But to see the console writes you'll need to use and IDE like SciTE for AutoIt, look in my signature for link. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
Fossil Rock Posted November 9, 2006 Posted November 9, 2006 #include <Mixer.au3>Try changing this (if the file is in the same directory as the script). #include "Mixer.au3" Agreement is not necessary - thinking for one's self is!
GaryFrost Posted November 9, 2006 Posted November 9, 2006 Try changing this (if the file is in the same directory as the script). #include "Mixer.au3" doesn't matter which way it's put, but usually when I do non-standard udfs I use the quotes SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
Fossil Rock Posted November 9, 2006 Posted November 9, 2006 doesn't matter which way it's put, but usually when I do non-standard udfs I use the quotesI was under the impression that the "???.au3" looked in the directory where the script is located and the <???.au3> looked in the \include directory of where Autoit is installed. Agreement is not necessary - thinking for one's self is!
GaryFrost Posted November 9, 2006 Posted November 9, 2006 I was under the impression that the "???.au3" looked in the directory where the script is located and the <???.au3> looked in the \include directory of where Autoit is installed.try it and you'll see it works, I don't remember exactly what Valik stated about it, but I know it works either way. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
masvil Posted November 10, 2006 Posted November 10, 2006 Thought this was worth putting here being 99% of the code is wiredbitsWell done, it works good Any way to:- set recording volume of an input device;- select microphone as active input device (without using wiredbits GUI);?
GaryFrost Posted November 10, 2006 Posted November 10, 2006 Well done, it works good Any way to:- set recording volume of an input device;- select microphone as active input device (without using wiredbits GUI);?try exchanging the _Get's for _Set's SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
masvil Posted November 10, 2006 Posted November 10, 2006 (edited) try exchanging the _Get's for _Set'sYour _SetMixerVolume($MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE, $percent) affects playback output volume, not the input registration volume.Edited:As explained here: http://www.codeproject.com/audio/volctrl.a...2866#xx852866xxWhat I'm asking for can't be done.Edited:Volumeline does the job very good (thanx to Schindi for the nice find) Edited November 11, 2006 by masvil
Lakes Posted December 15, 2006 Posted December 15, 2006 (edited) Can we have some more simple examples on using yours/WiredBits Mixer UDF, Mr Frosty please? Like toggling between Mic and Stereo Mix in the record panel? many Thanks! Edited December 15, 2006 by Lakes 2015 - Still no flying cars, instead blankets with sleeves.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now