How to trigger event based on volume level

Discussion in 'Mac Programming' started by ericbreiter, Aug 23, 2012.

  1. ericbreiter macrumors member

    Joined:
    Jun 13, 2012
    #1
    I wish to write a simple application that triggers an event purely based on when the output volume level reaches a certain threshold.

    It does not matter if the application takes all outgoing sounds into account (browser, mp3 players, video players, etc.) or the sound of a specific application if that is even possible.

    Does anyone have any idea on how to go about this?
     
  2. Mark FX macrumors regular

    Mark FX

    Joined:
    Nov 18, 2011
    Location:
    West Sussex, UK
    #2
    You could write a stay open Applescript application to do this.

    Let me know if your interested in some Applescript code, and I'll post something for you.

    Regards mark
     
  3. kryten2 macrumors 6502a

    Joined:
    Mar 17, 2012
    Location:
    Belgium
    #3
    You can get/set volume with something like this :

    Code:
    get volume settings
    set volume output volume 50
     

Share This Page