Files
kraken/kraken/KRAudioBuffer.h
Kearwood Gilbert 4d85c2e3be CMake autodetecting boost.
Added KRDataBlock to CMakeLists
2017-10-30 20:58:14 -07:00

43 lines
908 B
C++
Executable File

//
// KRAudioBuffer.h
// KREngine
//
// Created by Kearwood Gilbert on 2013-01-04.
// Copyright (c) 2013 Kearwood Software. All rights reserved.
//
#ifndef KRAUDIO_BUFFER_H
#define KRAUDIO_BUFFER_H
#include "KREngine-common.h"
#include "KRDataBlock.h"
class KRAudioManager;
class KRAudioSample;
class KRAudioBuffer
{
public:
KRAudioBuffer(KRAudioManager *manager, KRAudioSample *sound, int index, int frameCount, int frameRate, int bytesPerFrame, void (*fn_populate)(KRAudioSample *, int, void *));
~KRAudioBuffer();
int getFrameCount();
int getFrameRate();
signed short *getFrameData();
KRAudioSample *getAudioSample();
int getIndex();
private:
KRAudioManager *m_pSoundManager;
int m_index;
int m_frameCount;
int m_frameRate;
int m_bytesPerFrame;
KRDataBlock *m_pData;
KRAudioSample *m_audioSample;
};
#endif /* defined(KRAUDIO_BUFFER_H) */