mirror of
https://github.com/PrimeDecomp/prime.git
synced 2025-12-16 03:37:00 +00:00
VI (Thanks HeartPiece) and CStaticAudio work
Former-commit-id: 4babadb501a53ed61876f37a6a60fba76de55e02
This commit is contained in:
43
include/Kyoto/Audio/CStaticAudioPlayer.hpp
Normal file
43
include/Kyoto/Audio/CStaticAudioPlayer.hpp
Normal file
@@ -0,0 +1,43 @@
|
||||
#ifndef _CSTATICAUDIOPLAYER
|
||||
#define _CSTATICAUDIOPLAYER
|
||||
|
||||
#include <Kyoto/Audio/g721.h>
|
||||
#include <rstl/auto_ptr.hpp>
|
||||
#include <rstl/string.hpp>
|
||||
#include <rstl/vector.hpp>
|
||||
|
||||
class CDvdRequest;
|
||||
typedef void (*FAudioCallback)();
|
||||
|
||||
class CStaticAudioPlayer {
|
||||
public:
|
||||
CStaticAudioPlayer(const rstl::string& filepath, const int w1, const int w2);
|
||||
~CStaticAudioPlayer();
|
||||
|
||||
const bool IsReady() const;
|
||||
void StartMixOut();
|
||||
void StopMixOut();
|
||||
|
||||
static void MixCallback();
|
||||
void DoMix();
|
||||
static void RunDMACallback(FAudioCallback);
|
||||
static void CancelDMACallback(FAudioCallback);
|
||||
void Decode(ushort* bufIn, ushort* bufOut, uint numSamples);
|
||||
private:
|
||||
rstl::string x0_filepath;
|
||||
int x10_rsfRem;
|
||||
int x14_rsfLength;
|
||||
int x18_curSamp;
|
||||
int x1c_loopStartSamp;
|
||||
int x20_loopEndSamp;
|
||||
int x24_curBuf;
|
||||
rstl::auto_ptr< uchar > x28_dmaLeft;
|
||||
rstl::auto_ptr< uchar > x30_dmaRight;
|
||||
rstl::vector< rstl::auto_ptr< CDvdRequest > > x38_dvdRequests;
|
||||
rstl::vector< rstl::auto_ptr< uchar > > x48_buffers;
|
||||
g72x_state x58_leftState;
|
||||
g72x_state x8c_rightState;
|
||||
ushort xc0_volume;
|
||||
};
|
||||
|
||||
#endif // _CSTATICAUDIOPLAYER
|
||||
Reference in New Issue
Block a user