RioEngine  0.1
My first attempt to create a 3D WYSIWYG Game Engine
irrklang::ISoundMixedOutputReceiver Class Referenceabstract

Interface to be implemented by the user, which recieves the mixed output when it it played by the sound engine. More...

#include <ik_ISoundMixedOutputReceiver.h>

Public Member Functions

virtual ~ISoundMixedOutputReceiver ()
 destructor More...
 
virtual void OnAudioDataReady (const void *data, int byteCount, int playbackrate)=0
 Called when a chunk of sound has been mixed and is about to be played. More...
 

Detailed Description

Interface to be implemented by the user, which recieves the mixed output when it it played by the sound engine.

This can be used to store the sound output as .wav file or for creating a Oscillograph or similar. Simply implement your own class derived from ISoundMixedOutputReceiver and use ISoundEngine::setMixedDataOutputReceiver to let the audio driver know about it.

Definition at line 20 of file ik_ISoundMixedOutputReceiver.h.

Constructor & Destructor Documentation

virtual irrklang::ISoundMixedOutputReceiver::~ISoundMixedOutputReceiver ( )
inlinevirtual

destructor

Definition at line 25 of file ik_ISoundMixedOutputReceiver.h.

Member Function Documentation

virtual void irrklang::ISoundMixedOutputReceiver::OnAudioDataReady ( const void *  data,
int  byteCount,
int  playbackrate 
)
pure virtual

Called when a chunk of sound has been mixed and is about to be played.

Note: This is called from the playing thread of the sound library, so you need to make everything you are doing in this method thread safe. Additionally, it would be a good idea to do nothing complicated in your implementation and return as fast as possible, otherwise sound output may be stuttering.

Parameters
datarepresenting the sound frames which just have been mixed. Sound data always consists of two interleaved sound channels at 16bit per frame.
byteCountAmount of bytes of the data
playbackrateThe playback rate at samples per second (usually something like 44000). This value will not change and always be the same for an instance of an ISoundEngine.

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