AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Vista Audio Control Functions v2.0
Goto page Previous  1, 2, 3, 4
 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
FabianBengtsson



Joined: 14 Nov 2006
Posts: 14

PostPosted: Sat Jul 12, 2008 3:49 pm    Post subject: Reply with quote

I possible, in some way, to set the volume/mute a specified application with this script ?

For example if you want to set volume of foobar music player, could you do something like this?

Code:
VA_SetMasterVolume("10"," ","foobar2000 Application")

_________________
Don't capture me again!!
Back to top
View user's profile Send private message
Lexikos



Joined: 17 Oct 2006
Posts: 2699
Location: Australia, Qld

PostPosted: Sat Jul 12, 2008 11:12 pm    Post subject: Reply with quote

Quote:
I'm so stupid.. I Quoted the Integer i.e. "5" as the parameter, and should have just passed the integer

There must have been something else, because either way the value is stored as a string (the character "5") in the subunit_desc parameter of VA_GetMute. Your previous code works for me.
FabianBengtsson wrote:
I possible, in some way, to set the volume/mute a specified application with this script ?
No. I looked into it a while ago, and unfortunately it does not seem possible.
Back to top
View user's profile Send private message
thefant
Guest





PostPosted: Mon Jul 14, 2008 3:07 am    Post subject: Huh? Reply with quote

I feel somewhat unintelligent asking this, but...how exactly do I get this to work? I downloaded the Vista Audio Control Functions v2.0 in the .zip file...now what?
Back to top
Lexikos



Joined: 17 Oct 2006
Posts: 2699
Location: Australia, Qld

PostPosted: Mon Jul 14, 2008 8:03 am    Post subject: Reply with quote

Get COM.ahk if you haven't already. VA.ahk and COM.ahk should be placed in your function library.

In the auto-execute section of the script you will be using VA from, call COM_Init(). This initializes COM, which is used by VA. Find the function you want to call in the VA documentation, then simply call it.

I cannot be more specific without knowing what it is you want to do with VA.
Back to top
View user's profile Send private message
thefant
Guest





PostPosted: Mon Jul 14, 2008 4:02 pm    Post subject: Reply with quote

Where is the function library? And how do I "call"?

I just want to mute my MIDI. I went looking for solutions on how to do this about a week ago, and I eventually found this.
Back to top
Lexikos



Joined: 17 Oct 2006
Posts: 2699
Location: Australia, Qld

PostPosted: Mon Jul 14, 2008 9:59 pm    Post subject: Reply with quote

This is a function call:
Code:
function(parameter1, parameter2)

The function library is behind that blue thing we call a link. Wink

The script in the first post of this thread lists the available subunits. Unless there is a subunit "MIDI Mute" or similar, you'll need to use trial and error to determine which one it is. If they all have the same name, use numbering.
Code:
; In the auto-execute section (the top of the script):
COM_Init()

;...

VA_SetMute(true, "MIDI Mute")
; or
VA_SetMute(true, 1) ; 2, 3, etc.
It may help to have the properties of your playback device open as you run the script, to see if anything happens. (Usually Control Panel -> Sound -> Playback -> Speakers -> Properties -> Levels.)
Back to top
View user's profile Send private message
thefant
Guest





PostPosted: Tue Jul 15, 2008 4:37 am    Post subject: Reply with quote

And with that, I think I have it figured out. I don't have much experience with stuff like this, so thanks for your help!
Back to top
LPent



Joined: 10 May 2008
Posts: 6

PostPosted: Tue Sep 02, 2008 4:50 pm    Post subject: Reply with quote

I can only mute playback devices, not recording devices. Why is that? I really want to be able to mute my microphone input by means of a hotkey.
Back to top
View user's profile Send private message
GreenLevel
Guest





PostPosted: Sun Oct 05, 2008 4:27 pm    Post subject: Reply with quote

Hello! I know this is a Vista audio thread,.... but wondering if is it possible in some way, that will hopefully work in XP & Vista, output in a Tooltip the active peak value of the default audio device? Very Happy
Back to top
adamrgolf



Joined: 28 Dec 2006
Posts: 390

PostPosted: Sat Nov 08, 2008 1:40 pm    Post subject: Reply with quote

This is beautiful, thank you for your work on this.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions All times are GMT
Goto page Previous  1, 2, 3, 4
Page 4 of 4

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group