Skip to content

PayalLakra/AudioVisualization

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 

Repository files navigation

AudioVisualizer:: AudioVisualizer is a Python application that allows users to visualize live audio input or playback of audio files. It features a graphical user interface (GUI) built with PyQt5 and displays audio waveforms in real-time using PyQtGraph.

Features

  • Live Audio Visualization: View real-time audio waveforms from a microphone or other audio input devices.
  • File Playback: Load and visualize audio from WAV files.
  • Recording: Record live audio and save it as a WAV file.
  • Adjustable Speed and Buffer Size: Customize visualization speed and buffer size.
  • Real-Time Sample Rate Display: Display the current or loaded sample rate.

Requirements

  • Python 3.x
  • PyQt5
  • PyQtGraph
  • NumPy
  • PyAudio
  • SciPy

Installation

  1. Clone the repository:

    git clone https://github.com/PayalLakra/AudioVisualizer.git
    cd AudioVisualizer
  2. Create a virtual environment (optional but recommended):

    python -m venv venv
    source venv/bin/activate  # On Windows use `venv\Scripts\activate`
  3. Install the required packages:

    pip install -r requirements.txt

Usage

  1. Run the application:

    python main.py
  2. GUI Controls:

    • Start: Begin visualizing live audio input.
    • Stop: Stop the audio input visualization.
    • Record: Toggle recording of live audio. Save the recording as a WAV file when stopped.
    • Load File: Open a WAV file and visualize its waveform.
    • Speed: Select between "Fast" and "Slow" update rates for the plot.
    • Buffer Size: Choose the buffer size for the x-axis range of the plot.

Code Overview

  • AudioVisualizer Class: Main class for the GUI application, handling audio input, visualization, and recording.
  • start_recording Method: Initializes audio stream and starts the timer for visualization.
  • stop_recording Method: Stops the audio stream and timer.
  • update_plot Method: Updates the plot with new audio data or file data.
  • toggle_recording Method: Starts or stops recording audio based on the current state.
  • load_file Method: Loads an audio file and visualizes its waveform.
  • update_timer_interval Method: Adjusts the timer interval based on selected speed.
  • update_plot_range Method: Updates the plot range based on selected buffer size.

##Screenshots Screenshot 2024-08-13 111612 Screenshot (266)

Audio.Visualizer.2024-08-13.13-33-00.mp4

Credits

Support and Guidance: Special thanks to http://upsidedownlabs.tech/ for their continuous support and guidance.

About

An Application to visualize Audio-Input.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published