16#ifndef AEONGAMES_OGGSOUND_H
17#define AEONGAMES_OGGSOUND_H
20#include "aeongames/Sound.hpp"
21#include "vorbis/vorbisfile.h"
30 bool DecodeOGG (
Sound& aSound,
size_t aBufferSize,
const void* aBuffer );
37 OggSound (
const std::string & aFileName );
43 static
size_t Read (
void *ptr,
size_t size,
size_t nmemb,
void *datasource );
44 static
int Seek (
void *datasource, ogg_int64_t offset,
int whence );
45 static
int Close (
void *datasource );
46 static
long Tell (
void *datasource );
47 static const ov_callbacks Callbacks;
50 std::vector<uint8_t> mData;
OggSound(const std::string &aFileName)
Constructs an OggSound by loading from the specified file.
~OggSound() final
Destructor.
Abstract base class representing a decoded sound resource.
<- This is here just for the literals
bool DecodeOGG(Sound &aSound, size_t aBufferSize, const void *aBuffer)
Decodes OGG Vorbis audio data from a memory buffer into a Sound.