All Projects → ffAudio → Ff_meters

ffAudio / Ff_meters

Licence: bsd-3-clause
Plug and play component to display LED meters for JUCE audio buffers

Projects that are alternatives of or similar to Ff meters

Spectralizer
Audio visualizer plugin for obs-studio
Stars: ✭ 332 (+453.33%)
Mutual labels:  audio, visualisation
Airspy Fmradion
Software decoder for FM/AM broadcast radio with AirSpy R2 / Mini, Airspy HF+, and RTL-SDR
Stars: ✭ 59 (-1.67%)
Mutual labels:  audio
Musictheory
🎵 Music theory concepts in Go.
Stars: ✭ 53 (-11.67%)
Mutual labels:  audio
Toothyprogress
A polyline determinated ProgressBar written in Kotlin
Stars: ✭ 56 (-6.67%)
Mutual labels:  audio
Ctag Tbd
CTAG TBD >>to be determined<< an extendible open source Eurorack sound module
Stars: ✭ 54 (-10%)
Mutual labels:  audio
Bpm
Library and tool for dealing with beats per second detection
Stars: ✭ 57 (-5%)
Mutual labels:  audio
Audio player flutter
🎧 Apple Music / Tidal Audio Player for Flutter
Stars: ✭ 52 (-13.33%)
Mutual labels:  audio
Awesome Audio
A curated list of awesome audio technology resources for developers
Stars: ✭ 61 (+1.67%)
Mutual labels:  audio
Youtube In Background
YiB is an Android app, which extracts audio from YouTube videos and plays them in background.
Stars: ✭ 58 (-3.33%)
Mutual labels:  audio
Chime
🎵 Python sound notifications made easy
Stars: ✭ 56 (-6.67%)
Mutual labels:  audio
Wjplayer
Video.js bundle that supports HLS, VAST/VMAP, 360-degree videos, and more.
Stars: ✭ 55 (-8.33%)
Mutual labels:  audio
Squeeze Alexa
Squeezebox integration for Amazon Alexa
Stars: ✭ 54 (-10%)
Mutual labels:  audio
Slang
🎤 a simple audio programming language implemented in JS
Stars: ✭ 1,095 (+1725%)
Mutual labels:  audio
Psychosynth
GNU Psychosynth is a a synthesizer and modular audio framework inspired by the ideas of the Reactable.
Stars: ✭ 53 (-11.67%)
Mutual labels:  audio
Peep
Easy Sound Generator 🐥
Stars: ✭ 59 (-1.67%)
Mutual labels:  audio
Wetracker
A collaborative web based music creation tool based on the Tracker heritage.
Stars: ✭ 53 (-11.67%)
Mutual labels:  audio
Videojs Record
video.js plugin for recording audio/video/image files
Stars: ✭ 1,074 (+1690%)
Mutual labels:  audio
Play stdin.sh
A set of lightweight scripts to stream audio between two *nix machines. Perfect for use with a Raspberry Pi
Stars: ✭ 56 (-6.67%)
Mutual labels:  audio
React Mp3 Recorder
Microphone recorder for React that captures mp3 audio 🎵
Stars: ✭ 59 (-1.67%)
Mutual labels:  audio
Rb
A thread-safe fixed-size circular buffer written in safe Rust.
Stars: ✭ 59 (-1.67%)
Mutual labels:  audio

ff_meters

by Daniel Walz / Foleys Finest Audio Ltd. Published under the BSD License (3 clause)

The ff_meters provide an easy to use Component to display a level reading for an AudioBuffer. It is to be used in the audio framework JUCE (www.juce.com).

Find the API documentation here: https://ffaudio.github.io/ff_meters/

Usage

LevelMeter

To use it create a LevelMeterSource instance next to the AudioBuffer you want to display. To update the meter, call LevelMeterSource::measureBlock (buffer) in your processBlock or getNextAudioBuffer method.

On the Component use LevelMeter::setMeterSource to link to the LevelMeterSource instance. The number of channels will be updated automatically.

You can pull the drawing into your LookAndFeel by inheriting LevelMeter::LookAndFeelMethods and inlining the default implementation from LevelMeterLookAndFeel in ff_meters_LookAndFeelMethods.h into a public section of your class declaration. To setup the default colour scheme, call setupDefaultMeterColours() in your constructor.

Or you can use the LevelMeterLookAndFeel directly because it inherits from juce::LookAndFeel_V3 for your convenience. You can set it as default LookAndFeel, if you used the default, or set it only to the meters, if you don't want it to interfere.

All classes are in the namespace foleys to avoid collisions. You can either prefix each symbol, or import the namespace. N.B. for backward compatibility, FFAU is an alias for foleys.

// In your Editor
public:
    PluginEditor()
    {
        // adjust the colours to how you like them, e.g.
        lnf.setColour (foleys::LevelMeter::lmMeterGradientLowColour, juce::Colours::green);

        meter.setLookAndFeel (&lnf);
        meter.setMeterSource (&processor.getMeterSource());
        addAndMakeVisible (meter);
        // ...
    }
    ~PluginEditor()
    {
        meter.setLookAndFeel (nullptr);
    }

private:
    foleys::LevelMeterLookAndFeel lnf;
    foleys::LevelMeter meter { foleys::LevelMeter::Minimal }; // See foleys::LevelMeter::MeterFlags for options

// and in the processor:
public:
    foleys::LevelMeterSource& getMeterSource()
    {
        return meterSource;
    }

    void prepareToPlay (double sampleRate, int samplesPerBlockExpected) override
    {
        // this prepares the meterSource to measure all output blocks and average over 100ms to allow smooth movements
        meterSource.resize (getTotalNumOutputChannels(), sampleRate * 0.1 / samplesPerBlockExpected);
        // ...
    }
    void processBlock (AudioSampleBuffer& buffer, MidiBuffer&) override
    {
        meterSource.measureBlock (buffer);
        // ...
    }

private:
    foleys::LevelMeterSource meterSource;

OutlineBuffer

Another class is capable of reducing the samples going through into min and max blocks. This way you can see the outline of a signal running through. It can be used very similar:

// in your processor
private:
foleys::OutlineBuffer outline;

// in prepareToPlay
outline.setSize (getTotalNumInputChannels(), 1024);

// in processBlock
outline.pushBlock (buffer, buffer.getNumSamples());

// and in the editor's component:
const Rectangle<float> plotFrame (10.0f, 320.0f, 580f, 80f);
g.setColour (Colours::lightgreen);
g.fillRect (plotFrame);

Path plot;
processor.getChannelOutline (plot, plotFrame, 1000);
g.setColour (Colours::grey);
g.fillPath (plot);
g.setColour (Colours::black);
g.strokePath (plot, PathStrokeType (1.0f));

We hope it is of any use, let us know of any problems or improvements you may come up with...

Brighton, 2nd March 2017


Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].