Skip to content

TomGousseau/VoiceLimitar

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

VoiceLimitar

Audio Enhancer with Anti-Troll Protection - Prevents ear damage from trolls blasting loud sounds while enhancing normal audio quality.

Features

  • Hard Limiter - Caps max volume at 80% (configurable)
  • Soft Compression - Smoothly reduces loud sounds before hitting the limit
  • Bass/Treble Enhancement - Optional audio improvement
  • Anti-Troll Mode - Enabled by default, blocks sudden loud blasts

Usage

#include "audio_enhancer.h"

AudioEnhancer enhancer;
enhancer_init(&enhancer, 44100);  // 44.1kHz sample rate

// Configure protection
enhancer_set_max_volume(&enhancer, 0.8f);  // 80% max
enhancer_enable_anti_troll(&enhancer, true);

// Process audio
enhancer_process_buffer(&enhancer, audio_buffer, num_samples);

Building

# Linux/Mac
gcc -Wall -O2 -o audio_demo main.c audio_enhancer.c -lm

# Windows (MinGW)
gcc -Wall -O2 -o audio_demo.exe main.c audio_enhancer.c -lm

API

Function Description
enhancer_init() Initialize with safe defaults
enhancer_process() Process single sample
enhancer_process_buffer() Process mono buffer
enhancer_process_stereo() Process stereo buffers
enhancer_set_max_volume() Set maximum volume (0.1-1.0)
enhancer_set_bass() Set bass boost (0.0-2.0)
enhancer_set_treble() Set treble boost (0.0-2.0)
enhancer_enable_anti_troll() Enable/disable protection

License

MIT

About

why not

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors