mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-11-23 15:26:16 +00:00
Changed: #1030 Implement music streaming in OpenAL driver
This commit is contained in:
parent
7236c83bc4
commit
f4a2d07919
2 changed files with 6 additions and 4 deletions
|
@ -20,10 +20,11 @@
|
|||
|
||||
using namespace NLMISC;
|
||||
|
||||
namespace NLSOUND {
|
||||
namespace NLSOUND
|
||||
{
|
||||
|
||||
CBufferAL::CBufferAL(ALuint buffername) :
|
||||
IBuffer(), _BufferName(buffername), _SampleFormat(AL_INVALID), _Frequency(0),
|
||||
IBuffer(), _BufferName(buffername), _Name(NULL), _SampleFormat(AL_INVALID), _Frequency(0),
|
||||
_DataAligned(NULL), _DataPtr(NULL), _Capacity(0), _Size(0), _StorageMode(IBuffer::StorageAuto), _IsLoaded(false)
|
||||
{
|
||||
|
||||
|
@ -176,7 +177,7 @@ void CBufferAL::getFormat(TBufferFormat &format, uint8 &channels, uint8 &bitsPer
|
|||
case AL_FORMAT_MONO16: sampleFormat = Mono16; break;
|
||||
case AL_FORMAT_STEREO8: sampleFormat = Stereo8; break;
|
||||
case AL_FORMAT_STEREO16: sampleFormat = Stereo16; break;
|
||||
default: sampleFormat = (TSampleFormat)~0; nlstop;
|
||||
default: sampleFormat = SampleFormatUnknown;
|
||||
}
|
||||
sampleFormatToBufferFormat(sampleFormat, format, channels, bitsPerSample);
|
||||
frequency = _Frequency;
|
||||
|
|
|
@ -19,7 +19,8 @@
|
|||
|
||||
#include <nel/sound/driver/buffer.h>
|
||||
|
||||
namespace NLSOUND {
|
||||
namespace NLSOUND
|
||||
{
|
||||
|
||||
/**
|
||||
* OpenAL buffer
|
||||
|
|
Loading…
Reference in a new issue