Gnash
0.8.11dev
|
Instance of a defined sound (LiveSoundData) More...
#include <LiveSound.h>
Protected Member Functions | |
LiveSound (media::MediaHandler &mh, const media::SoundInfo &info, size_t inPoint) | |
Create an embedded sound instance. More... | |
const std::int16_t * | getDecodedData (unsigned long int pos) const |
virtual bool | moreData ()=0 |
Called when more decoded sound data is required. More... | |
virtual bool | eof () const =0 |
True if there is no more data ever. More... | |
void | restart () |
Start from the beginning again. More... | |
unsigned int | samplesFetched () const |
How many samples have been fetched since the beginning. More... | |
size_t | playbackPosition () const |
media::AudioDecoder & | decoder () const |
void | appendDecodedData (std::uint8_t *data, unsigned int size) |
unsigned int | decodedSamplesAhead () const |
Additional Inherited Members | |
![]() | |
virtual | ~InputStream () |
Instance of a defined sound (LiveSoundData)
This class contains a pointer to the LiveSoundData used for playing and a SimpleBuffer to use when decoding is needed.
|
protected |
Create an embedded sound instance.
mh | The MediaHandler to use for on-demand decoding |
inPoint | Offset in output samples this instance should start playing from. These are post-resampling samples (44100 for one second of samples). |
info | The media::SoundInfo for this sound. |
References gnash::media::CODEC_TYPE_FLASH, gnash::media::MediaHandler::createAudioDecoder(), data, decodedSamplesAhead(), getDecodedData(), gnash::media::SoundInfo::getFormat(), gnash::media::SoundInfo::getSampleRate(), gnash::media::SoundInfo::is16bit(), gnash::media::SoundInfo::isStereo(), and moreData().
|
inlineprotected |
References data.
Referenced by gnash::sound::EmbedSoundInst::EmbedSoundInst(), and gnash::sound::StreamingSound::StreamingSound().
|
inlineprotected |
Return number of already-decoded samples available from playback position on
Referenced by gnash::sound::StreamingSound::eof(), gnash::sound::EmbedSoundInst::eof(), and LiveSound().
|
inlineprotected |
|
protectedpure virtual |
True if there is no more data ever.
The InputStream will be disconnected when this is true.
Implements gnash::sound::InputStream.
Implemented in gnash::sound::EmbedSoundInst, and gnash::sound::StreamingSound.
|
inlineprotected |
Referenced by LiveSound().
|
protectedpure virtual |
Called when more decoded sound data is required.
This will be called whenever no more decoded data is available but decoding is not complete.
Referenced by LiveSound().
|
inlineprotected |
Referenced by gnash::sound::EmbedSoundInst::EmbedSoundInst().
|
inlineprotected |
Start from the beginning again.
Referenced by gnash::sound::EmbedSoundInst::EmbedSoundInst().
|
inlineprotectedvirtual |
How many samples have been fetched since the beginning.
Note that this is reset on each loop.
Implements gnash::sound::InputStream.