Jump to content
Sign in to follow this  
Dethredic

Volume Control

Recommended Posts

Dethredic

This is probably out there, but who cares.

This will let you simply change the volume using simple hotkeys. Fell free to change them if you want.

By default:

ctrl+*Up_arrow_key* increases the volume

ctrl+*down_arrow_key* decreases the volume

ctrl+*left_arrow_key* mutes the volume

ctrl+*Up_arrow_key* changes the rate at which the volume is changed with the up and down arrow keys.

I will continue to work on this, and make it a bit more user friendly, and easily customizable and probably make a try menu.

I am also working on implementing the scroll wheel change the volume instead of the arrow keys.

Dim $counter = 0
Dim $speed = 2


HotKeySet("^{UP}", "v_up")
HotKeySet("^{DOWN}", "v_down")
HotKeySet("^{LEFT}", "mute")
HotKeySet("^{RIGHT}", "speed")

Func v_up()
    Do
        Send("{VOLUME_UP}")
        $counter += 1
    Until $counter = $speed
    $counter = 0

EndFunc ;==>v_up

Func v_down()
    Do
        Send("{VOLUME_DOWN}")
        $counter += 1
    Until $counter = $speed
    $counter = 0
EndFunc ;==>v_down

Func mute()
    Send("{VOLUME_MUTE}")
EndFunc ;==>mute

Func speed()
    $speed += 1
    If $speed = 4 Then
        $speed = 1
    EndIf
EndFunc ;==>speed


While 1
    Sleep(25)
WEnd
Edited by Dethredic

"Its not about the 30 inch 1080p display, or the SLI 8800 ultras, or the DDR3 memory. It's about when you turn on your PC, does it return the favor?"Math is like sex. Sure, it may give some practical results, but that is not why we do it

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×