Skip to content

MickeyJ/FFT-DFT-experiment

Repository files navigation

WAV Player & Frequency Analyzer

A experimental C# project for learning digital audio processing from the ground up.

What it does

  • Parses WAV files - Reads binary WAV format, handles chunks, extracts audio data
  • Plays audio - Direct Windows API audio output using WinMM.dll
  • Frequency analysis - DFT implementation to analyze audio spectrum
  • Real-time processing - Chunk-by-chunk analysis with parallel processing

Current Features

✅ Full WAV file parser (handles any chunk order)
✅ Raw audio playback via Windows APIs
✅ DFT-based frequency analysis
✅ Real-time spectrum analysis
✅ Parallel processing (analyze next chunk while current plays)
✅ Telephone frequency detection

Usage

Put a .wav file in the project directory and update the filename in Program.cs:

string filename = "your-audio-file.wav";

Run the project to see:

  • WAV file structure analysis
  • Audio playback with live frequency analysis
  • Peak frequency detection per chunk

Learning Goals

This is an experimental project to understand:

  • Binary file formats and parsing
  • Digital signal processing fundamentals
  • Windows audio APIs and P/Invoke
  • Real-time audio processing concepts
  • Frequency domain analysis (DFT/FFT)

Future Ideas

  • Implement FFT for better performance
  • Add audio effects (reverb, echo, distortion)
  • Real-time waveform visualization
  • Maybe build a VST plugin someday! 🎵

Requirements

  • Windows (uses WinMM.dll)
  • .NET Core/Framework
  • 16-bit PCM WAV files work best

Just a fun experiment in audio programming!

About

experimenting with frequency analysis, etc.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages