| 23 | bool parseVoc(SoundBuffer* voc); |
| 24 | |
| 25 | bool loadSoundFile(const char* name) |
| 26 | { |
| 27 | FilePath filePath; |
| 28 | if (!TFE_Paths::getFilePath(name, &filePath)) |
| 29 | { |
| 30 | return false; |
| 31 | } |
| 32 | |
| 33 | FileStream vocAsset; |
| 34 | if (!vocAsset.open(&filePath, Stream::MODE_READ)) |
| 35 | { |
| 36 | return false; |
| 37 | } |
| 38 | size_t size = vocAsset.getSize(); |
| 39 | s_buffer.resize(size + 1); |
| 40 | vocAsset.readBuffer(s_buffer.data(), (u32)size); |
| 41 | vocAsset.close(); |
| 42 | |
| 43 | return true; |
| 44 | } |
| 45 | |
| 46 | SoundBuffer* get(const char* name) |
| 47 | { |
no test coverage detected