#include <SFML/Config.h>
#include <SFML/Audio/SoundBuffer.h>
Go to the source code of this file.
Typedefs | |
typedef sfSoundRecorder | sfSoundRecorder |
sfSoundRecorder is an interface for capturing sound data | |
Functions | |
CSFML_API sfSoundRecorder * | sfSoundRecorder_Create (sfBool(*Callback)(const sfInt16 *, size_t, void *), void *UserData) |
Construct a new sound recorder with a callback function for processing captured samples. | |
CSFML_API void | sfSoundRecorder_Destroy (sfSoundRecorder *SoundRecorder) |
Destroy an existing sound recorder. | |
CSFML_API void | sfSoundRecorder_Start (sfSoundRecorder *SoundRecorder, unsigned int SampleRate) |
Start the capture. | |
CSFML_API void | sfSoundRecorder_Stop (sfSoundRecorder *SoundRecorder) |
Stop the capture. | |
CSFML_API unsigned int | sfSoundRecorder_GetSampleRate (sfSoundRecorder *SoundRecorder) |
Get the sample rate of a sound recorder. | |
CSFML_API sfBool | sfSoundRecorder_CanCapture () |
Tell if the system supports sound capture. |
typedef struct sfSoundRecorder sfSoundRecorder |
sfSoundRecorder is an interface for capturing sound data
Definition at line 38 of file SoundRecorder.h.
CSFML_API sfBool sfSoundRecorder_CanCapture | ( | ) |
Tell if the system supports sound capture.
If not, this class won't be usable
CSFML_API sfSoundRecorder* sfSoundRecorder_Create | ( | sfBool(*)(const sfInt16 *, size_t, void *) | Callback, | |
void * | UserData | |||
) |
Construct a new sound recorder with a callback function for processing captured samples.
Callback | : Callback function for processing captured samples | |
UserData | : Data to pass to the callback function (can be NULL) |
CSFML_API void sfSoundRecorder_Destroy | ( | sfSoundRecorder * | SoundRecorder | ) |
Destroy an existing sound recorder.
SoundRecorder | : Sound recorder to delete |
CSFML_API unsigned int sfSoundRecorder_GetSampleRate | ( | sfSoundRecorder * | SoundRecorder | ) |
Get the sample rate of a sound recorder.
SoundRecorder | : Sound recorder to get sample rate from |
CSFML_API void sfSoundRecorder_Start | ( | sfSoundRecorder * | SoundRecorder, | |
unsigned int | SampleRate | |||
) |
Start the capture.
Warning : only one capture can happen at the same time
SoundRecorder | : Sound recorder to start | |
SampleRate | : Sound frequency (the more samples, the higher the quality) |
CSFML_API void sfSoundRecorder_Stop | ( | sfSoundRecorder * | SoundRecorder | ) |
Stop the capture.
SoundRecorder | : Sound recorder to stop |