"L. Spiro Engine"
Public Member Functions | Protected Attributes

lss::CWaveStreamingSoundSourceStreamer Class Reference

A way to stream audio data from .wav files. More...

#include <LSSWaveStreamingSoundSourceStreamer.h>

Inheritance diagram for lss::CWaveStreamingSoundSourceStreamer:
lss::IStreamingSoundSourceStreamer

List of all members.

Public Member Functions

LSE_CALLCTOR CWaveStreamingSoundSourceStreamer (const LSCHAR *_pcFile, CAllocator *_paAllocator)
virtual LSBOOL LSE_CALL GetData (LSUINT64 _ui64From, LSUINT64 &_ui64Length, LSUINT8 *&_pui8Data, CAllocator *_paAllocator) const
virtual LSUINT32 LSE_CALL GetType () const
virtual const LSCHAR *LSE_CALL GetName () const
virtual LSUINT32 LSE_CALL GetFrequency () const
virtual LSUINT32 LSE_CALL GetBits () const
virtual LSUINT32 LSE_CALL GetChannels () const
virtual LSUINT64 LSE_CALL GetAudioLength () const

Protected Attributes

LSCHAR * m_pcPath
CAllocator * m_paAllocator
CFileMap m_fmMap
CWaveLoader::LSE_WAVE_FILE_INFO m_wfiInfo
LSUINT64 m_ui64SoundTime

Detailed Description

A way to stream audio data from .wav files.

Class CWaveStreamingSoundSourceStreamer Description: Uses the IStreamingSoundSourceStreamer interface to provide a way to stream audio data from a wave file into a CStreamingSoundSource object.


Member Function Documentation

virtual LSUINT64 LSE_CALL lss::CWaveStreamingSoundSourceStreamer::GetAudioLength ( ) const [virtual]

Get the length of the data in microseconds.

Returns:
Returns the length, in microseconds, of the audio provided by this class.

Implements lss::IStreamingSoundSourceStreamer.

virtual LSUINT32 LSE_CALL lss::CWaveStreamingSoundSourceStreamer::GetBits ( ) const [virtual]

Get the number of bits per channel of the data.

Returns:
Returns the number of bits per channel of the data provided by this class.

Implements lss::IStreamingSoundSourceStreamer.

virtual LSUINT32 LSE_CALL lss::CWaveStreamingSoundSourceStreamer::GetChannels ( ) const [virtual]

Get the number of channels of the data.

Returns:
Returns the number of channels of the data provided by this class.

Implements lss::IStreamingSoundSourceStreamer.

virtual LSBOOL LSE_CALL lss::CWaveStreamingSoundSourceStreamer::GetData ( LSUINT64  _ui64From,
LSUINT64 &  _ui64Length,
LSUINT8 *&  _pui8Data,
CAllocator *  _paAllocator 
) const [virtual]

Retrieve sound data for use by the CStreamingSoundSource class.

Parameters:
_ui64FromThe offset within the data source to get the data, in microseconds.
_ui64LengthThe length of the data to get, in microseconds. If the function succeeds, this holds the returned length of the data in bytes.
_pui8DataThe returned data.
_paAllocatorThe allocator to be used to allocate the data to which _pui8Data will point on a successful return.
Returns:
Returns true if successful, false otherwise.

Implements lss::IStreamingSoundSourceStreamer.

virtual LSUINT32 LSE_CALL lss::CWaveStreamingSoundSourceStreamer::GetFrequency ( ) const [virtual]

Get the frequency of the data.

Returns:
Returns the frequency of the data provided by this class.

Implements lss::IStreamingSoundSourceStreamer.

virtual const LSCHAR* LSE_CALL lss::CWaveStreamingSoundSourceStreamer::GetName ( ) const [virtual]

Get the name of the streamer. Here it is the file path.

Returns:
Returns a constant LSCHAR * to the name of the streamer.

Implements lss::IStreamingSoundSourceStreamer.

virtual LSUINT32 LSE_CALL lss::CWaveStreamingSoundSourceStreamer::GetType ( ) const [virtual]

Get the type of this streamer. Returns LSS_ST_WAVEFILE along with the parent type.

Returns:
Returns the bitmask representing the type of streamer this instance is.

Implements lss::IStreamingSoundSourceStreamer.


Member Data Documentation

The file map we use to get data from the file.

The allocator we use.

The path to this wave file in UTF-8 format. This also serves as the name of the object.

Length of the sound in microseconds.

The wave file information.


The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator