BTrack - A Real-Time Beat Tracker
 All Classes Files Functions Enumerations Pages
Public Member Functions | List of all members
OnsetDetectionFunction Class Reference

#include <OnsetDetectionFunction.h>

Public Member Functions

 OnsetDetectionFunction (int hopSize_, int frameSize_, int onsetDetectionFunctionType_, int windowType)
 
 ~OnsetDetectionFunction ()
 
void initialise (int hopSize_, int frameSize_, int onsetDetectionFunctionType_, int windowType)
 
double calculateOnsetDetectionFunctionSample (double *buffer)
 
void setOnsetDetectionFunctionType (int onsetDetectionFunctionType_)
 

Detailed Description

A class for calculating onset detection functions.

Constructor & Destructor Documentation

OnsetDetectionFunction::OnsetDetectionFunction ( int  hopSize_,
int  frameSize_,
int  onsetDetectionFunctionType_,
int  windowType 
)

Constructor

Parameters
hopSize_the hop size in audio samples
frameSize_the frame size in audio samples
onsetDetectionFunctionType_the type of onset detection function to use - (see OnsetDetectionFunctionType)
windowTypethe type of window to use (see WindowType)
OnsetDetectionFunction::~OnsetDetectionFunction ( )

Destructor

Member Function Documentation

double OnsetDetectionFunction::calculateOnsetDetectionFunctionSample ( double *  buffer)

Process input frame and calculate detection function sample

Parameters
buffera pointer to an array containing the audio samples to be processed
Returns
the onset detection function sample
void OnsetDetectionFunction::initialise ( int  hopSize_,
int  frameSize_,
int  onsetDetectionFunctionType_,
int  windowType 
)

Initialisation Function

Parameters
hopSize_the hop size in audio samples
frameSize_the frame size in audio samples
onsetDetectionFunctionType_the type of onset detection function to use - (see OnsetDetectionFunctionType)
windowTypethe type of window to use (see WindowType)
void OnsetDetectionFunction::setOnsetDetectionFunctionType ( int  onsetDetectionFunctionType_)

Set the detection function type

Parameters
onsetDetectionFunctionType_the type of onset detection function to use - (see OnsetDetectionFunctionType)

The documentation for this class was generated from the following files: