Skip to content

antisedative/soundControl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sound Control on Key Press

This Python script enables you to control the sound (mute/unmute) of a specific program by pressing certain keys. It can be handy, for example, when you need to quickly mute a program without switching to it.

How it Works

The script listens for specific key presses using the pynput library. When a predefined key combination is detected, it mutes or unmutes the sound of the specified program using the Windows Core Audio API.

< Current Functionality >

  • The application allows users to select the target program from a dropdown menu.
  • Users can then assign custom hotkeys for muting and unmuting the selected program.
  • After configuring the hotkeys, users can control the sound (mute/unmute) of the selected program by pressing the assigned keys.

Installation

  1. Clone this repository:

    git clone https://github.com/antisedativ/soundControl.git
  2. Install the required dependencies:

    pip install -r requirements.txt

Usage

  1. Open the main.py file and modify the PROGRAM variable to specify the name of the program whose sound you want to control.

  2. Run the script:

    python main.py
  3. Press the predefined key combination (default: AltGr + Ctrl) to mute/unmute the sound of the specified program.

OR

  1. Run the script:
    pyinstaller --onefile --noconsole --name "Sound Control" main.py
    

Requirements

  • Python 3.x
  • pynput
  • tkinter
  • PyCaw

Contributing

Contributions are welcome! If you find a bug or have a suggestion for improvement, feel free to open an issue or create a pull request.

< Possible Improvements >

  • Volume Adjustment Functionality: Implement features to adjust the volume of the target application, allowing users to increase or decrease the volume as needed.
  • Enhanced Visual Appearance: Improve the aesthetics and user interface design to make the application more visually appealing and user-friendly.

About

Sound Control on Key Press

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages