#include <SoundRecorder.hpp>
Public Member Functions | |
virtual | ~SoundRecorder () |
Virtual destructor. | |
void | Start (unsigned int SampleRate=44100) |
Start the capture. | |
void | Stop () |
Stop the capture. | |
unsigned int | GetSampleRate () const |
Get the sample rate. | |
Static Public Member Functions | |
static bool | CanCapture () |
Tell if the system supports sound capture. | |
Protected Member Functions | |
SoundRecorder () | |
Default constructor. | |
Private Types | |
typedef void(* | FuncType )(void *) |
Private Member Functions | |
void | Launch () |
Create and run the thread. | |
void | Wait () |
Wait until the thread finishes. | |
void | Terminate () |
Terminate the thread Terminating a thread with this function is not safe, you should rather try to make the thread function terminate by itself. |
Definition at line 41 of file SoundRecorder.hpp.
sf::SoundRecorder::~SoundRecorder | ( | ) | [virtual] |
sf::SoundRecorder::SoundRecorder | ( | ) | [protected] |
bool sf::SoundRecorder::CanCapture | ( | ) | [static] |
Tell if the system supports sound capture.
If not, this class won't be usable
Definition at line 136 of file SoundRecorder.cpp.
unsigned int sf::SoundRecorder::GetSampleRate | ( | ) | const |
Get the sample rate.
Definition at line 126 of file SoundRecorder.cpp.
void sf::SoundRecorder::Start | ( | unsigned int | SampleRate = 44100 |
) |
Start the capture.
Warning : only one capture can happen at the same time
SampleRate | : Sound frequency (the more samples, the higher the quality) (44100 by default = CD quality) |
Definition at line 69 of file SoundRecorder.cpp.
void sf::SoundRecorder::Stop | ( | ) |