Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The Juce library was originally created to build audio processing applications, and thus it includes well-developed classes for manipulating audio data. As you'll see in the Juce forums, most of the people using Juce are building audio apps and plugins. Why does this matter for the GUI? As it turns out, the steps involved in acquiring, processing, and storing audio data are profoundly similar to those required for electrophysiological signals. Using Juce's built-in audio classes with very little modification has made it surprisingly easy to build a sophisticated processing pipeline for neural data without worrying about the nitty-gritty details of buffering, message passing, and threading. Therefore, many classes used in this application have "Audio" or "Midi" in their name. Neural data processors are derived from the Juce AudioProcessor class, continuous signals are stored in AudioSampleBuffers, and spike events are sent in MidiBuffers. At some point in the future, it may be prudent to build a custom backend for data handling, but for now, Juce's audio classes have made the development process much faster without any noticeable detriment to performance.

Key classes

Here are some Juce classes that are used extensively throughout the GUI. You should learn to love them:

  • AudioSampleBuffer - used to shuttle continuous data through the ProcessorGraph. Holds an array of floats of size channels x samples.
  • MidiBuffer - used to shuttle event data through the ProcessorGraph. Holds discrete events with a timestamp and several bytes of data. In the Juce source code in this repository, the MidiBuffer class has been modified so that each event can hold an arbitrary number of bytes. This is so things like spike events can be sent from processor to processor through the MidiBuffer.
  • Component - almost everything the user can interact with is a component. Components hold other components as children, which inform their parents when they receive a user input, such as a click.
  • Graphics - used to draw within Components

...

  • .

Changes to the Juce source code

...