gramods
Loading...
Searching...
No Matches
SoundBurstDetector.hh
1
2#ifndef GRAMODS_SOUND_SOUNDBURSTDETECTOR
3#define GRAMODS_SOUND_SOUNDBURSTDETECTOR
4
5#include <gmSound/SoundDetector.hh>
6
7namespace gramods {
8namespace gmSound {
9
14
15public:
16
19
26 void setThreshold(float r);
27
35 void setCooldown(float t);
36
44 std::vector<std::vector<float>> detectSound() override;
45
46 GM_OFI_DECLARE;
47
48private:
49 struct Impl;
50 std::unique_ptr<Impl> _impl;
51};
52
53}}
54
55#endif
Sound detector search for samples over a specified threshold.
Definition SoundBurstDetector.hh:13
void setCooldown(float t)
Sets the cooldown time for a detection, i.e.
Definition SoundBurstDetector.cpp:34
std::vector< std::vector< float > > detectSound() override
Reads off new samples from the capture device, if such are available, then detect sound based over th...
Definition SoundBurstDetector.cpp:41
void setThreshold(float r)
Sets the threshold used for detecting a sound event in the range 0-1.
Definition SoundBurstDetector.cpp:27
The interface for an algorithm detecting sound in an audio stream.
Definition SoundDetector.hh:17
Gramods, short for Graphics Modules, is a collection of weakly inter dependent and useful APIs for Vi...
Definition config.hh:25
Definition SoundBurstDetector.cpp:14