parent
f566649479
commit
49efaf3fbd
13
src/audio.cc
13
src/audio.cc
|
@ -9,17 +9,20 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
|
static bool _defaultCompressionFunc(char* filePath);
|
||||||
|
static int audioSoundDecoderReadHandler(int fileHandle, void* buf, unsigned int size);
|
||||||
|
|
||||||
// 0x5108BC
|
// 0x5108BC
|
||||||
AudioFileIsCompressedProc* _queryCompressedFunc = _defaultCompressionFunc;
|
static AudioFileIsCompressedProc* _queryCompressedFunc = _defaultCompressionFunc;
|
||||||
|
|
||||||
// 0x56CB00
|
// 0x56CB00
|
||||||
int gAudioListLength;
|
static int gAudioListLength;
|
||||||
|
|
||||||
// 0x56CB04
|
// 0x56CB04
|
||||||
AudioFile* gAudioList;
|
static AudioFile* gAudioList;
|
||||||
|
|
||||||
// 0x41A2B0
|
// 0x41A2B0
|
||||||
bool _defaultCompressionFunc(char* filePath)
|
static bool _defaultCompressionFunc(char* filePath)
|
||||||
{
|
{
|
||||||
char* pch = strrchr(filePath, '.');
|
char* pch = strrchr(filePath, '.');
|
||||||
if (pch != NULL) {
|
if (pch != NULL) {
|
||||||
|
@ -30,7 +33,7 @@ bool _defaultCompressionFunc(char* filePath)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 0x41A2D0
|
// 0x41A2D0
|
||||||
int audioSoundDecoderReadHandler(int fileHandle, void* buffer, unsigned int size)
|
static int audioSoundDecoderReadHandler(int fileHandle, void* buffer, unsigned int size)
|
||||||
{
|
{
|
||||||
return fileRead(buffer, 1, size, (File*)fileHandle);
|
return fileRead(buffer, 1, size, (File*)fileHandle);
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,13 +3,6 @@
|
||||||
|
|
||||||
#include "audio_file.h"
|
#include "audio_file.h"
|
||||||
|
|
||||||
extern AudioFileIsCompressedProc* _queryCompressedFunc;
|
|
||||||
|
|
||||||
extern int gAudioListLength;
|
|
||||||
extern AudioFile* gAudioList;
|
|
||||||
|
|
||||||
bool _defaultCompressionFunc(char* filePath);
|
|
||||||
int audioSoundDecoderReadHandler(int fileHandle, void* buf, unsigned int size);
|
|
||||||
int audioOpen(const char* fname, int mode, ...);
|
int audioOpen(const char* fname, int mode, ...);
|
||||||
int audioClose(int fileHandle);
|
int audioClose(int fileHandle);
|
||||||
int audioRead(int fileHandle, void* buffer, unsigned int size);
|
int audioRead(int fileHandle, void* buffer, unsigned int size);
|
||||||
|
|
Loading…
Reference in New Issue