Image Component Library (ICL)
Public Member Functions | Private Attributes | List of all members
icl::cv::HeartrateDetector Class Reference

Heartrate Detector. More...

#include <HeartrateDetector.h>

Inheritance diagram for icl::cv::HeartrateDetector:
icl::utils::Uncopyable

Public Member Functions

 HeartrateDetector (int framerate=30, int historyDepth=512)
 Default constructor with given arguments. More...
 
void addImage (const core::Img8u &image)
 Add an image to the detector to use in the estimation. More...
 
float getHeartrate () const
 
qt::PlotWidget::SeriesBuffer getFrequencies () const
 returns a SeriesBuffer for visualization of the frequencies. More...
 
qt::PlotWidget::SeriesBuffer getAveragedFrequencies () const
 
qt::PlotWidget::SeriesBuffer getWindowBuffer () const
 
int getFramerate () const
 returns the framerate More...
 
int getHistoryDepth () const
 returns the history depth More...
 
virtual ~HeartrateDetector ()
 Destructor. More...
 

Private Attributes

Data * m_data
 internal data structure More...
 

Additional Inherited Members

- Protected Member Functions inherited from icl::utils::Uncopyable
 Uncopyable ()
 Empty base constructor. More...
 

Detailed Description

Heartrate Detector.

Implementation of a simple heartrate detector using video material of a face.

The algorithm takes images cropped to the same part of the face as an input and estimates the heartrate using a Fast Fourier Transformation over the average green value of the past few frames.

Parameters for the algorithm are:

Constructor & Destructor Documentation

◆ HeartrateDetector()

icl::cv::HeartrateDetector::HeartrateDetector ( int  framerate = 30,
int  historyDepth = 512 
)

Default constructor with given arguments.

◆ ~HeartrateDetector()

virtual icl::cv::HeartrateDetector::~HeartrateDetector ( )
virtual

Destructor.

Member Function Documentation

◆ addImage()

void icl::cv::HeartrateDetector::addImage ( const core::Img8u image)

Add an image to the detector to use in the estimation.

◆ getAveragedFrequencies()

qt::PlotWidget::SeriesBuffer icl::cv::HeartrateDetector::getAveragedFrequencies ( ) const

returns a SeriesBuffer for visualization of the averaged frequencies over the last second.

◆ getFramerate()

int icl::cv::HeartrateDetector::getFramerate ( ) const

returns the framerate

◆ getFrequencies()

qt::PlotWidget::SeriesBuffer icl::cv::HeartrateDetector::getFrequencies ( ) const

returns a SeriesBuffer for visualization of the frequencies.

◆ getHeartrate()

float icl::cv::HeartrateDetector::getHeartrate ( ) const

returns the current estimate for the heartrate. Will return 0 if no enough enough samples have been provided.

◆ getHistoryDepth()

int icl::cv::HeartrateDetector::getHistoryDepth ( ) const

returns the history depth

◆ getWindowBuffer()

qt::PlotWidget::SeriesBuffer icl::cv::HeartrateDetector::getWindowBuffer ( ) const

returns a buffer that marks the current window of frequencies that is considered for the estimation of the heartrate.

Member Data Documentation

◆ m_data

Data* icl::cv::HeartrateDetector::m_data
private

internal data structure

internal data pointer


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